Home Messages Index
[Date Prev][Date Next][Thread Prev][Thread Next]
Author IndexDate IndexThread Index

Re: rsync move?

  • Subject: Re: rsync move?
  • From: Unruh <unruh-spam@xxxxxxxxxxxxxx>
  • Date: 16 May 2006 14:33:09 GMT
  • Newsgroups: comp.os.linux.misc
  • Organization: ITServices, University of British Columbia
  • References: <pan.2006.> <44693070.9D1A7C43@yahoo.com> <pan.2006.> <7018458.Jh3aN40dRo@schestowitz.com>
  • User-agent: nn/6.6.4
  • Xref: news.mcc.ac.uk comp.os.linux.misc:621673
Roy Schestowitz <newsgroups@xxxxxxxxxxxxxxx> writes:

>__/ [ Captain Dondo ] on Tuesday 16 May 2006 03:18 \__

>> On Mon, 15 May 2006 21:52:48 -0400, CBFalconer wrote:
>>> Captain Dondo wrote:
>>>> Is there anything like an rsync move?
>>>> I want to safely move files across a network; once the receiving
>>>> end has verified that the copy has been received, I need for it to
>>>> be deleted on the source....
>>>> This needs to be automated, as the source computer has no user
>>>> interface at all....
>>> What defines 'safely'?  You might send the file, have the receiver
>>> compute an MD5sum on it and return that.  If that matches the
>>> locally computed MD5sum delete the source.
>> That's exactly the algorithm I had in mind...
>>> Write a script.
>> I'm lazy. :-)  Actually, I was hoping someone might have incorporated this
>> into an rsync-type app....  Space is limited on my source computer, so the
>> fewer discrete apps I have the better....
>> --Yan 

>rsync -r  /my-warez you@safe-haven:/my-treasure-spot; rm -rf /my-warez; echo
>'aye aye, sir!'

>Assumes rsync coughs out no errors in the process, so add a condition.

Precisely. You could do && instead of ; after the rsync command, but I
suspect he would want a bit more guarentee that the transfers really
happened than that. I think I would run rsync twice and the second time use
the md5 check (-I) on all files.
man rsync  option -I 

>Best wishes,

[Date Prev][Date Next][Thread Prev][Thread Next]
Author IndexDate IndexThread Index