On Sat, 29 May 2010 10:01:39 +0100 Mick wrote: > Hi All, > > I run: > > rsync -a -l --delete -v /mnt/Business_dir /media/sdf1 > > to back up a directory from a PC to a USB stick. However, from a > cursory look this *seems* to copy the complete directory (every time > I run it) and overwrites the USB stick. Carrying on like this it > will life-expire the USB stick in no time, plus it takes ages to > complete as it copies over every single file again and again. > > Is there a cleverer option I can add to rsync so that it only copies > new files, overwrites older versions of the same and only deletes any > files or directories that have been deleted from the source directory? > -- > Regards, > Mick
For years I've used "rsync -Cavzu ..." to do updates. That's been my mantra for so long I don't recall what each option does do know that it updates (rather than copies everything). Indeed flash drives _do_ have a lifetime. My recollection is that it's in the thousands of writes if not the hundreds of thousands of writes. Assuming a life of 1,000 writes and you backup once daily, that's 3 years of backups. 10,000 writes would be 30 years. Of course if you backup every hour, 10,000 writes is a year (or so). Honestly, I've stopped worrying about manual copies to flash drives. Of course if you have a program that writes to a flash drive frequently, that's a very different story ... HTH, David