Why does one of there work and the other doesn't
tim.conway at philips.com
tim.conway at philips.com
Sat Dec 1 01:42:17 EST 2001
from "man rsync":
a trailing slash on the source changes this behavior to
transfer all files from the directory src/bar on the machine
foo into the /data/tmp/. A trailing / on a source name
means "copy the contents of this directory". Without a
trailing slash it means "copy the directory". This differ-
ence becomes particularly important when using the --delete
option.
Wonderful things, those manuals. Warning: in my experience, this gives
unpredictable results. it does NOT, in fact, always detect all the
content of the directory, and as a result, a --delete can have
catastrophic consequences. I have not had time to try to figure out why
this happens, but my few tests aren't even repeatable... if there are more
than maybe 10 entries in the directory, something is always left out, but
rarely the same thing twice. Needless to say, I never use that syntax.
"
>ls -a src
.dotfile
dir1
file2
dir3
file4
>ls -a dest
.dotfile
dir1
file2
dir3
file4
>rsync -a --delete --force src/ dest
>ls -a dest
>ls -a dest
.dotfile
dir1
file2
file4
>update resume
"
Tim Conway
tim.conway at philips.com
303.682.4917
Philips Semiconductor - Longmont TC
1880 Industrial Circle, Suite D
Longmont, CO 80501
Available via SameTime Connect within Philips, n9hmg on AIM
perl -e 'print pack(nnnnnnnnnnnn,
19061,29556,8289,28271,29800,25970,8304,25970,27680,26721,25451,25970),
".\n" '
"There are some who call me.... Tim?"
Ian Kettleborough <ian at idk.com>
Sent by: rsync-admin at lists.samba.org
11/29/2001 11:58 PM
To: rsync at lists.samba.org
cc: (bcc: Tim Conway/LMT/SC/PHILIPS)
Subject: Why does one of there work and the other doesn't
Classification:
I was planning to use rsync to backup to a second drive, but I ran out of
swap space. No problem, I will let rsync do it a few directories at a time
overnight when the computer usually sits idle except for incomming email.
I have 2 question:
1. How much memory does each file to be copied need. Obvisiouly I have too
many
files.
2. Why does this command work:
rsync -ax /usr/xx /backup/usr/
when:
rsync -ax /usr/xx/ /backup/usr/
refuses to create the directory xx in /backup/usr and
copies
the contents of the directory to /backup
Happens on both 2.4.7Pre4 and 2.5.0 just released.
Thanks
Ian
More information about the rsync
mailing list