Hello All!
I use rsync to make back ups of my boot partition and my /home directory as they are on different drives.
How ever I did a restore for the boot one to go to another drive a SSD
instead of a DASD.
This is the back up one :
-!- cat rsync-root.sh
#!/bin/bash
time rsync -avvuhh --stats --delete --exclude=/dev --exclude=/proc --exclude=/mnt --exclude=/run --exclude=/tmp --exclude=/home
--exclude=/media --exclude=/sys /
/home/vince/Music2/Backups/SSD-Mageia-v7-HDD > rsync-root.log
rsync-root.err
exit 0
-!-
( line starting time continues down to 'rsync-root.err' )
This is the restore :
-!- cat rsync-restore-root.sh
#!/bin/bash
time rsync -avvuhh --stats --delete --exclude=/dev --exclude=/proc --exclude=/mnt --exclude=/run --exclude=/tmp --exclude=/home
--exclude=/media --exclude=/sys
/home/vince/Music2/Backups/SSD-Mageia-v7-HDD "/mnt/disk1" > rsync-restore-root.log 2 > rsync-restore-root.err
exit 0
-!-
The back up goes from root / to
/home/vince/Music2/Backups/SSD-Mageia-v7-HDD
The restore goes from /home/vince/Music2/Backups/SSD-Mageia-v7-HDD to
/mnt/disk1 and also tried "/mnt/disk1" as in above.
But both end up producing report in rsync-restore-root.err (should be .log)
but with a directory in my home directlry as 2/disk1 and SSD-Mageia-v7-HDD
I am confused :(
Is rsync changing destination location because the original source is not
the same as the restore ? as I can find no reference to that it the info
help file (via man rsync or info rsync).
The SSD partition IS mounted as /mnt/disk1 : - -
df - abbreviated :
/dev/sdc4 83G 57M 78G 1% /mnt/disk2
/dev/sdc6 118G 61M 112G 1% /mnt/disk3
/dev/sdc3 88G 18G 66G 22% /mnt/disk1
Mounted by root : - -
ls -la /mnt
drwxr-xr-x 13 root root 4096 May 27 15:50 ./
drwxr-xr-x 22 root root 4096 May 26 22:53 ../
drwxr-xr-x 13 root root 4096 May 26 22:52 disk1/
drwxr-xr-x 3 root root 4096 May 26 18:44 disk2/
drwxr-xr-x 3 root root 4096 May 26 18:44 disk3/
and ls -la /mnt/disk1
drwxr-xr-x 13 root root 4096 May 26 22:52 ./
drwxr-xr-x 13 root root 4096 May 27 15:50 ../
lrwxrwxrwx 1 root root 7 Sep 24 2018 bin -> usr/bin/
drwxr-xr-x 5 root root 4096 May 25 15:24 boot/
drwxr-xr-x 2 root root 4096 Aug 30 2018 cgroup/
drwxr-xr-x 147 root root 12288 May 25 20:38 etc/
drwxr-xr-x 2 root root 4096 Sep 24 2018 initrd/
lrwxrwxrwx 1 root root 7 Sep 24 2018 lib -> usr/lib/
lrwxrwxrwx 1 root root 9 Sep 24 2018 lib64 -> usr/lib64/
drwx------ 2 root root 16384 Sep 22 2019 lost+found/
drwxr-xr-x 7 root root 4096 May 26 21:08 opt/
-rw-r--r-- 1 root root 0 May 1 04:42 .readahead_collect
drwxr-x--- 19 root root 4096 May 26 21:10 root/
lrwxrwxrwx 1 root root 8 Sep 24 2018 sbin -> usr/sbin/
drwxr-xr-x 2 root root 4096 Sep 24 2018 srv/
drwx------ 10 root root 4096 May 26 22:17 sys/
drwxr-xr-x 15 root root 4096 Nov 19 2019 usr/
drwxr-xr-x 18 root root 4096 May 25 20:38 var/
What on earth is rsync doing ?
I am trying to create an image of by DASD boot partition in the SSD so I
can switch to using it instead of the DASD by reconnecting the Sata cables around between the two and yes I suspect I will have to run the Mag
installer to fix up the /boot content and settings as they are different partitions with each drive.
Vincent
SEEN-BY: 250/1 3