Scheduled Backups of Home Directory
Gabriel M Dragffy
dragffy at yandex.ru
Mon Aug 14 18:02:57 UTC 2006
On Mon, 2006-08-14 at 03:41 +0100, mattskr wrote:
> This is what I do to copy my home directory nightly to a USB hard
> disk...
>
>
>
> Run -> sudo crontab -e
>
>
>
> to open roots cron
>
>
>
> Add this line:
>
>
>
> * 2 * * * rsync -av --delete --update /home /media/usbdisk
>
>
>
> Change your output direcotry, close the file, and your done. Been
> working fine for almost a year, and I had restore my files from backup
> once.
>
>
>
> It backups nightly at 2 AM copying only files that changed and deleting
> any files that have been deleted in /home that day.
>
>
> --
> mattskr
>
Hi this is a good script and I have been using rsync with a very similar
command for some time now. However, one thing is missing. It backs up to
a USB hard disk and any and all files/folders copied there have the
permissions and ownership changed to the current user AND 755, which is
not the best of things. I've been working on writing a script that will
make a text file listing the permissions of the actual files and letting
this run automatically, but my skill is not good enough - anyone can
help?
More information about the ubuntu-users
mailing list