You have at least 2 different base/ folders, best on different devices (because of backup reasons), and both should have identical modules in them.
For ease of use you have all your main modules in your base/ folder (that is, not only your 00[0123]-* modules, but all of the normally loaded modules)
If that is not the case for you, you have to at least have two files for each setup: one for base/ and one for either /modules or /optional
Or three if you use base/ and /modules and /optional
Then you would move into all these folders and create slightly different named files, e.g. files named like so:
Code: Select all
/tmp/sda1.md5sum_base
/tmp/sda1.md5sum_modules
/tmp/sda1.md5sum_optional
or when all three folders should hold the same amount of files on e.g. sda1 and on e.g. sdc1 and these should all be identical, you can also do this: (for sda1, adjust the path for your base accordingly)
Code: Select all
# cd /into/sda1/porteus/base
# md5sum *xzm >/tmp/sda1.md5sum
# cd ../modules
# md5sum *xzm >>/tmp/sda1.md5sum
# cd ../optional
# md5sum *xzm >>/tmp/sda1.md5sum
But this HOWTO assumes all your modules are simply in base/ and we therefore only create one md5sum checklist text file for each Porteus installation.
Let's say one is your main hard drive base/ and the other acts as backup on some external device, and you use some settings modules and some other programs like your main browser and/or yt-dlp that get updated on a regular basis.
Therefore you now want to check if both set of module files are identical.
1. let's assume one base/ folder is on sda1, the other on sdc1
2. therefore we name the resulting files in /tmp sda1.md5sum and sdc1.md5sum
3. let's furthermore assume the base/ on sda1 is also $PORTDIR/base/
4. the base in sdc1 is /mnt/sdc1/porteus/base/
5. make 1st. md5sum checklist text file:
Code: Select all
# cd $PORTDIR/base/
# md5sum *xzm >/tmp/sda1.md5sum
Code: Select all
# cd /mnt/sdc1/porteus/base/
# md5sum *xzm >/tmp/sdc1.md5sum
Code: Select all
# cd /tmp/
# diff sd[ac]1.md5sum
doing so lets you use the most recent files from the target partition without
any updating of dozens of base/ folders - you only have to update one single
symlink on the target partition that links to the actual module file) do this
to only compare the md5sum checksums and leave out the file names:
Code: Select all
# cd /tmp/
# cat sda1.md5sum| cut -c 1-34 >sda1.md5sum.cut
# cat sdc1.md5sum| cut -c 1-34 >sdc1.md5sum.cut
# diff sd[ac]1.md5sum.cut
If one or more md5sums differ, investigate and fix the issue.
10.In my case, the files sd[ac]1.md5sum differ because of different filenames
for some modules, but the md5sums compared via sd[ac]1.md5sum.cut are identical:
Code: Select all
root@rava:/tmp# ls -o *md5sum*
-rw-r--r-- 1 guest 1371 2023-11-20 09:41 sda1.md5sum
-rw-r--r-- 1 guest 700 2023-11-20 09:44 sda1.md5sum.cut
-rw-r--r-- 1 guest 1510 2023-11-20 09:41 sdc1.md5sum
-rw-r--r-- 1 guest 700 2023-11-20 09:45 sdc1.md5sum.cut
root@rava:/tmp# diff sd[ac]1.md5sum.cut
root@rava:/tmp#