Re: Synchronize file on HD and USB stick
According to kamaraju kusumanchi,
> Vincent Smeets wrote:
>
> >Hallo,
> >
> >is there some tool to synchronize files or directories between a hard
> >disk and a USB stick? I have some files on the hard disk of my home
> >computer. I have a copy of them on a USB stick so that I can use the
> >files at other places (at work) too. I need to keep those two copies
> >in sync, sometimes the USB file are changed, sometimes the HD files.
> >
> >On Windows I used a "Workmap" directory on the USB stick. It showed a
> >button in the explorer to synchronize the files and Windows checked
> >which one was the newest version. Now I have left Windows and switched
> >over to Debian, but I still have the files on the stick and HD that
> >need to be synchronized. Is there some tool in Debian for that?
> >
> >Thanks,
> >Vincent Smeets
> >
> >
> rsync -avzp source-address destination-address
> will make sure that the files in source are also there on destination.
> It is not exactly what you want but it does half the job.
-u will make sure that newer overwrites older, not vice
versa (warning- make sure clocks are right!- I don't do this
till I'm sure ntpd is running on the machines).
and by source-address and destination-address you of course
mean path-to-file-or-directory in this context (though of
course one of the other can also be prefixed user@host:
which implies ssh transport).
rsync won't sync deletions though- unison's probably better
if you want that.
Reply to: