Fellow RSYNC users,

I recently decided to use 'rsync' to update a backup copy of my root 
partition rather than doing a 'dump', 'restore', and a massage of the
/etc/fstab file.   I've tried using a variation of the  "backup to a spare 
disk" example on the web page with bad results.  I found that using the
"L" option visually appears to work much better.  But I don't feel
comfortable with the error messages that come out when using the 
verbose mode.  I am running RSYNC version 2.4.6 on a BSDi 4.1 system 
for this example.

I've appended examples in sort of reverse order, since the backup root 
partition gets clobbered.  

And, I may of answered my own question by producing the examples.  The 
destination partition is being mounted on the source partition, which 
changes the /mnt directory.  Shouldn't the "x" option take care of this?  
I did try mounting /dev/sd1a on /usr/mnt and things did work as I intended.
This could be disasterous for others that may of assumed the same I did. 

So if you have any suggestion or that this is a new or known bug, please let 
me know.

--Mark
 
Mark Keppinger            Information Services - Network Engineering
Milne Computer Center         Internet: [EMAIL PROTECTED]
Oregon State University          Phone: (541) 737-4483
Corvallis, OR 97331-5202           FAX: (541) 737-4484           

=================Example that looks like it works but with errors===========
nnstat: {205} % df
Filesystem  1K-blocks     Used    Avail Capacity  Mounted on
/dev/sd0a       35671    18806    15081    55%    /
/dev/sd0h     4015596  1924545  1890271    50%    /usr
mfs:19          15855       52    15010     0%    /tmp
/dev/sd1a       35671    18806    15081    55%    /mnt
nnstat: {206} % /usr/local/bin/rsync -axvL --delete --exclude=etc/fstab // /mnt
building file list ... 
readlink mnt/var: No such file or directory
readlink mnt/sys: No such file or directory
readlink mnt/linux: No such file or directory
done
IO error encountered - skipping file deletion
./
stat linux : No such file or directory
mnt/
stat sys : No such file or directory
tmp/
usr/
stat var : No such file or directory
stat linux : No such file or directory
stat sys : No such file or directory
stat var : No such file or directory
wrote 21615 bytes  read 20 bytes  8654.00 bytes/sec
total size is 13243255  speedup is 612.12
nnstat: {207} % df
Filesystem  1K-blocks     Used    Avail Capacity  Mounted on
/dev/sd0a       35671    18806    15081    55%    /
/dev/sd0h     4015596  1925035  1889781    50%    /usr
mfs:19          15855        2    15060     0%    /tmp
/dev/sd1a       35671    18806    15081    55%    /mnt

==========================Example that doesn't work========================
nnstat: {208} % /usr/local/bin/rsync -ax --delete --exclude=etc/fstab // /mnt
nnstat: {209} % df
Filesystem  1K-blocks     Used    Avail Capacity  Mounted on
/dev/sd0a       35671    18806    15081    55%    /
/dev/sd0h     4015596  1925132  1889684    50%    /usr
mfs:19          15855        2    15060     0%    /tmp
/dev/sd1a       35671     9335    24552    28%    /mnt

==========================Rebuild backup of root with dump/restore==========
nnstat: {210} % ./build_alt /
/dev/rsd1a:     73728 sectors in 36 cylinders of 1 tracks, 2048 sectors
        36.0MB in 3 cyl groups (16 c/g, 16.00MB/g, 3008 i/g)
super-block backups (for fsck -b #) at:
 32, 32800, 65568,
  DUMP: Date of this level 0 dump: Wed Dec 13 12:41:52 2000
  DUMP: Date of last level 0 dump: the epoch
  DUMP: Dumping /dev/rsd0a (/) to standard output
  DUMP: mapping (Pass I) [regular files]
  DUMP: mapping (Pass II) [directories]
  DUMP: estimated 21342 tape blocks.
  DUMP: dumping (Pass III) [directories]
  DUMP: dumping (Pass IV) [regular files]
  DUMP: 21473 tape blocks
  DUMP: DUMP IS DONE
Filesystem  1K-blocks     Used    Avail Capacity  Mounted on
/dev/sd0a       35671    18806    15081    55%    /
/dev/sd0h     4015596  1925140  1889676    50%    /usr
mfs:19          15855        2    15060     0%    /tmp
/dev/sd1a       35671    18806    15081    55%    /mnt
Partition / built.
nnstat: {211} % /sbin/mount /dev/sd1a /mnt
nnstat: {212} % df
Filesystem  1K-blocks     Used    Avail Capacity  Mounted on
/dev/sd0a       35671    18806    15081    55%    /
/dev/sd0h     4015596  1925140  1889676    50%    /usr
mfs:19          15855        2    15060     0%    /tmp
/dev/sd1a       35671    18806    15081    55%    /mnt

=====================Failed with verbose set ================================
nnstat: {213} % /usr/local/bin/rsync -axv --delete --exclude=etc/fstab // /mnt
building file list ... done
deleting mnt/var
deleting directory mnt/usr
deleting directory mnt/tmp
deleting directory mnt/tftpboot
deleting mnt/sys
deleting mnt/shlib/libutil_s.4.1.0
deleting mnt/shlib/libutil_s.4.0.0
 . . .  <<most information removed to keep brief>>
deleting mnt/.sentinel/NETWORKING
deleting mnt/.sentinel/LAP
deleting mnt/.sentinel/HYLAFAX
deleting mnt/.sentinel/CORE_ROOT_CONFIG
deleting mnt/.sentinel/CORE_ROOT_BINARIES
deleting directory mnt/.sentinel
deleting mnt/.profile
deleting mnt/.base-4.1
./
mnt/
tmp/
usr/
wrote 24037 bytes  read 20 bytes  271.83 bytes/sec
total size is 9500539  speedup is 394.92
nnstat: {214} % df
Filesystem  1K-blocks     Used    Avail Capacity  Mounted on
/dev/sd0a       35671    18806    15081    55%    /
/dev/sd0h     4015596  1925149  1889667    50%    /usr
mfs:19          15855        2    15060     0%    /tmp
/dev/sd1a       35671     9335    24552    28%    /mnt

============================/ partition show symbolic links================
nnstat: {215} % ls -l /
total 1829
-rw-r--r--   1 root  wheel        0 Aug 29 12:01 .base-4.1
-rw-r--r--   1 root  wheel      104 Nov 16  1999 .profile
drwxr-xr-x   2 root  wheel      512 Aug 29 11:40 .sentinel
drwxr-xr-x   2 root  wheel      512 Nov 16  1999 a
drwxrwxr-x   2 root  wheel      512 Dec  9 11:41 altboot
drwxrwxr-x   2 root  wheel      512 Dec  9 11:43 altusr
dr-xr-xr-x   2 root  wheel      512 Nov 16  1999 amd
lrwxr-xr-x   1 root  wheel       18 Dec  9 11:43 backups -> /usr/local/backups
drwxr-xr-x   2 root  wheel     1024 Aug 29 11:34 bin
-r-xr-xr-x   1 root  wheel    69027 Aug 29 11:32 boot
-r-xr-xr-x   1 root  wheel  1754587 Aug 29 11:32 bsd
drwxr-xr-x   2 root  wheel      512 Nov 16  1999 cdrom
drwxr-xr-x   3 root  wheel    10752 Aug 29 11:32 dev
drwxr-xr-x  15 root  wheel     3072 Dec 12 13:12 etc
drwxrwxr-x   2 root  wheel      512 Nov 28  1999 lib
lrwxr-xr-x   1 root  wheel        9 Dec  9 11:43 linux -> usr/linux
drwxr-xr-x  20 root  wheel      512 Dec  9 11:43 mnt
drwxr-xr-x   3 root  wheel      512 Aug 30 09:10 root
drwxr-xr-x   2 root  wheel     1536 Aug 29 11:34 sbin
drwxr-xr-x   7 root  wheel      512 Nov 16  1999 sco
drwxr-xr-x   2 root  wheel     2048 Dec 12 13:11 shlib
lrwxr-xr-x   1 root  wheel       11 Dec  9 11:43 sys -> usr/src/sys
drwxr-xr-x   2 root  wheel      512 Nov 16  1999 tftpboot
drwxrwxrwt   3 root  wheel      512 Dec 13 12:42 tmp
drwxr-xr-x  24 root  wheel      512 Aug 30 09:22 usr
lrwxr-xr-x   1 root  wheel        7 Dec  9 11:43 var -> usr/var


Reply via email to