I have a backup server in my LAN which mounts the home dir of user@laptop and creates a backup each hour using a python script.
The problem that I'm having is that I get some hundred "permission denied" errors from rsync. Some files won't copy if I start the backup as root, others won't copy if I start it as user.
The first thought that came to my mind was to set group ownership of home from user
to root
recursively. But I'm not sure if I should really do that..
Does anyone know how to proceed with this?
Some info about the setup:
uid
and gid
numbers are identical for user and root on both computers.
This is how I import/export home:
Export with: /etc/exports
192.168.178.10(ro,sync,no_subtree_check,root_squash)
Mount with: /etc/auto.user
-fstype=nfs4,ro,tcp 192.168.178.20:/home/username
ro
means "read-only". I would suggest you change your mount option fromro
torw
(read/write) when you're performing the backup.