rsync giving directory by name, instead of contents
nathan r. hruby
nhruby at uga.edu
Wed Aug 2 21:25:36 GMT 2006
Hi all!
I've read the manual and google'ed aplenty, but sadly can't figure out
this particular issue. Perhaps someone can thwack me with the correct
cluestick?
I have a number of directories listed under one path in an rsyncd module.
I'd like to rsync the contents of some of the directories. Here's
essentially what the source filesystem looks like:
/home
/home/user1
/home/user1/public_html
/home/user2
/home/user2/public_html
And the path statement in rsyncd.conf on the source is "/home" with a
module name of home.
Sadly, while doing an rsync using rsyncd like this
rsync -avz server.edu::home/user1/public_html/ /dest/path/user1/www
I get
/dest/path/user1/www/public_html
which has the correct contents. So things are being copied, just with an
extra directory.
The man page states that having a "/" at the end of the source means "copy
the contents of this directory" which is the desired effect and works as
advertised in the manpage when using ssh transport (eg: rsync -e ssh
user at server.edu:/home/user1/public_html/)
So, am I doing something dumb, or does rsyncd just not honor the trailing
slash in source lines?
For those of you wondering why not just use ssh since it works, the answer
is that I have to do about 82k of these rsyncs and the source system is a
tad slow, so all of the extra connections and ssh startups add extra time
and load to the source system.
Why not just rsync /home and be done with it? Because I really only want
the public_html directories and I'm reshuffling the directory structure at
the same time too, so I need to do each user individually to ensure their
data lands in the correct place.
Thanks,
-n
--
-------------------------------------------
nathan hruby <nhruby at uga.edu>
uga enterprise information technology services
core services support
-------------------------------------------
"In 1972 a crack commando unit was sent to
prison by a military court for a crime they
didn't commit...."
More information about the rsync
mailing list