On Tue, 16 Nov 2004 22:19:32 +0000, Darragh Bailey
<felix at compsoc.nuigalway.ie> wrote:
>> Trying to use rsync to update a local copy of a website from the one sitting on
> a server.
>> But in this case I need to be able to switch user after login in order to
> retreive the files fully
>> loging in remotely as the shared user will not work either.
>> I was looking at
> rsync -var --rsh="ssh -l user host su - new_user" :src_dir/* local_dir/
>> But rsync terminates the connection. Is it possible to do it this way, in which
> case could someone point out what I'm missing or do I have to resort to a script
> in order to be able to perform this?
A work-around might be for newuser to clone rsync
somewhere only accessible to user, chmod u+s, then
invoke rsync with --rsync_path=/path/to/setuid/bin/
A better solution would be to set the groups up
"properly" so user can r/w newuser's web files,
but I'm guessing you don't have that option!
I'm also assuming some of your web files are
scripts, so wget is not an option...
Kieran Tully, Software Developer and Tenor
Reply to Kieran.Tully AT acm.org
Maintained by the ILUG website team. The aim of Linux.ie is to
support and help commercial and private users of Linux in Ireland. You can
display ILUG news in your own webpages, read backend
information to find out how. Networking services kindly provided by HEAnet, server kindly donated by
Dell. Linux is a trademark of Linus Torvalds,
used with permission. No penguins were harmed in the production or maintenance
of this highly praised website. Looking for the
Indian Linux Users' Group? Try here. If you've read all this and aren't a lawyer: you should be!