Re: [PLUG] Rsync again

2018-10-06 Thread Larry Brigman
I would add checking of the return code (exit code) for the 'cd' commands. As it is now those could fail but something latter would have to detect the failure. On Sat, Oct 6, 2018, 5:28 PM John Jason Jordan wrote: > On Sat, 06 Oct 2018 13:08:21 -0700 > Tomas K dijo: > > >Simple if statement in

Re: [PLUG] Rsync again

2018-10-06 Thread John Jason Jordan
On Sat, 06 Oct 2018 13:08:21 -0700 Tomas K dijo: >Simple if statement in your backup script should take care of it. >You can do it number of ways - here is one - checking that there is any >content in the directory before starting rsync (in bash): > >#!/bin/bash

Re: [PLUG] Rsync again

2018-10-06 Thread Roderick Anderson
On 10/06/2018 02:50 PM, John Jason Jordan wrote: On Sat, 6 Oct 2018 12:23:04 -0700 Erik Lane dijo: That would be nice to be able to stop it in that way. I'm not a Linux guru, so I'd also like to hear if there's some way to do that. However, I just wanted to say that I always use -P as one

Re: [PLUG] Rsync again

2018-10-06 Thread John Jason Jordan
On Sat, 6 Oct 2018 12:23:04 -0700 Erik Lane dijo: >That would be nice to be able to stop it in that way. I'm not a Linux >guru, so I'd also like to hear if there's some way to do that. > >However, I just wanted to say that I always use -P as one of the >options, and this will resume partial

Re: [PLUG] Rsync again

2018-10-06 Thread Tomas K
The answer is - Do not start rsync until your NAS is mounted and working. Simple if statement in your backup script should take care of it. You can do it number of ways - here is one - checking that there is any content in the directory before starting rsync (in bash): #!/bin/bash

Re: [PLUG] Rsync again

2018-10-06 Thread Erik Lane
That would be nice to be able to stop it in that way. I'm not a Linux guru, so I'd also like to hear if there's some way to do that. However, I just wanted to say that I always use -P as one of the options, and this will resume partial downloads. So if you have to stop it and then resume later,

Re: [PLUG] Rsync again

2018-10-06 Thread John Jason Jordan
On Sat, 6 Oct 2018 10:17:05 -0700 John Jason Jordan dijo: I need some advice with respect to the following command, which makes my Synology NAS device a mirror of my external USB storage enclosure: rsync -rptog --progress --stats --delete

[PLUG] Rsync again

2018-10-06 Thread John Jason Jordan
Is there a way to stop an rsync command so that it gets to the end of the file it is writing before it stops, less you end up with a partially transferred file? ___ PLUG mailing list PLUG@pdxlinux.org http://lists.pdxlinux.org/mailman/listinfo/plug