Can scp be used to update a directory?

Jeff Vian jvian10 at charter.net
Sun Mar 19 02:38:50 UTC 2006


On Sat, 2006-03-18 at 18:01 +0000, Anne Wilson wrote:
> On Saturday 18 March 2006 17:34, Pedro Fernandes Macedo wrote:
> > Anne Wilson wrote:
> > > Really?  I had completely misunderstood, then.
> > >
> > > Any advice/caveats?  With a man page running to 34 pages it will take a
> > > bit of digesting ;-)
> > >
> > > Anne
> >
> > Here's a sample of what I use every day to sync my home directory to
> > another machine where ssh runs on port 8090, excluding the Cache of any
> > mozilla based browser (--exclude=Cache) , deleting any excluded files
> > that by accident may have been sent to the destination and files that
> > have been removed (--delete-excluded includes --delete) and copying the
> > contents of symlinks, instead of copying the links (--copy-links).
> > rsync -avz -e 'ssh -p 8090' /home/pmacedo/ my_other_machine:~/sync/
> > --delete-excluded --exclude=Cache --copy-links
> >
> > One caveat: you must be running rsync either from the source or the
> > destination machine, since rsync wont do remote to remote syncs using ssh.
> > That's usually what I use and I've never needed any other options
> > besides those to do any type of sync.
> >
> Hmm - I'm getting something badly wrong here:
> 
> [anne at david ~]$ rsync -auvz /home/anne/ ssh:anne at borg:/home/anne/  
> --exclude .* > ~/Desktop/rsynctest.txt
> 
The .* includes all hidden (.xxxx) files, the .. (parent) directory, and
the . (current) directory.  It may not have been what you wanted.

> gives
> 
> rsync: link_stat "/home/anne/ssh:anne at borg:/home/anne/." failed: No such file 
> or directory (2)
> 
> Then it goes on to try to access the other users' directories:
> 
> rsync: opendir "/home/anne/../gillian" failed: Permission denied (13)
> rsync: opendir "/home/anne/../lost+found" failed: Permission denied (13)
> rsync: opendir "/home/anne/../david" failed: Permission denied (13)
> ERROR: destination must be a directory when copying more than 1 file
> rsync error: errors selecting input/output files, dirs (code 3) at main.c(410)
> rsync: connection unexpectedly closed (8 bytes received so far) [sender]
> rsync error: error in rsync protocol data stream (code 12) at io.c(420)
> 
> (I'm deliberately leaving out the -r, for the moment.)
> 
> Anne
> -- 
> fedora-list mailing list
> fedora-list at redhat.com
> To unsubscribe: https://www.redhat.com/mailman/listinfo/fedora-list




More information about the fedora-list mailing list