spamhog
April 15th, 2017, 09:14 PM
I have 2 strictly related Xenial installs
- basic install on a 64G SSD, more advanced install with many manually installed apps on a 120G SSD
- the one in the bigger disk was a dd clone of the other
- plenty of free space on both
- identical partition schemes (except partition sizes), all in 1 partition with no swap
- IDENTICAL fstab, partition UID, disk UID
- even identical kernels as I keep both perfectly up to date
- EACH NORMALLY RUN INSIDE VIRTUALBOX VMs
- both work fine also on the two hardware machines where they are supposed to go
- identical root & user accounts
- only important difference is the hostname
- trivial user level config differences, i.e. wallpapers to make the 2 visually idientifiable
- no /home encryption yet
So I reckon the grub installations should be identical and interchangeable.
I went much further on the bigger HD in manually installing many special apps.
Now I want to bring the install on the smaller HD to mirror the other.
I think that just copying all the files from one onto the other (while neither is running) should be enough.
Something like this:
cp -a -x -P --remove-destination /mnt/big-ssd/* /mnt/small-ssd/
-a preserve all attributes
-x stay on one file system
-P no dereferencing
--remove-destination to overwrite without asking.
That should work without bothering to clone at the disk level, no need to make the larger partition smaller.
Before I set fire to the powder keg, does this look more or less reasonable?
Thank you for your wisdom!
- basic install on a 64G SSD, more advanced install with many manually installed apps on a 120G SSD
- the one in the bigger disk was a dd clone of the other
- plenty of free space on both
- identical partition schemes (except partition sizes), all in 1 partition with no swap
- IDENTICAL fstab, partition UID, disk UID
- even identical kernels as I keep both perfectly up to date
- EACH NORMALLY RUN INSIDE VIRTUALBOX VMs
- both work fine also on the two hardware machines where they are supposed to go
- identical root & user accounts
- only important difference is the hostname
- trivial user level config differences, i.e. wallpapers to make the 2 visually idientifiable
- no /home encryption yet
So I reckon the grub installations should be identical and interchangeable.
I went much further on the bigger HD in manually installing many special apps.
Now I want to bring the install on the smaller HD to mirror the other.
I think that just copying all the files from one onto the other (while neither is running) should be enough.
Something like this:
cp -a -x -P --remove-destination /mnt/big-ssd/* /mnt/small-ssd/
-a preserve all attributes
-x stay on one file system
-P no dereferencing
--remove-destination to overwrite without asking.
That should work without bothering to clone at the disk level, no need to make the larger partition smaller.
Before I set fire to the powder keg, does this look more or less reasonable?
Thank you for your wisdom!