rsync -a user@host:/dir/to/backup /local/backup/dir/
produces
rsync error: some files could not be transferred (code 23)
Rsync is an awesome program for maintaining backups, it checks the source against the backup and only transfers the differences. In using it over ssh I came up against error 23 and could not work out why.
I could only perform the sync if I used the root account of the host (source PC) when running the command from the backup server.
Fortunately I am the root user of almost all the boxes in question, but it did make me wonder what would occur should I not be.
So in order to establish exactly what was and wasn’t dealt with I used the -vv switch. This gives us verbose mode with a short description like “isuptodate” or (in my case)
failed: Permission denied (13).
HAZZAH! We know what the issue is – trixy perms.
So I scoot on over to the directory in question and
ls -l
the shiz out of it, and sure enough the directory is missing its read perms. A quick
chmod -R g+r directory
and away we go. Gotta love Linux … *Jizz…in…mapants*
Leave a Reply