Score:1

rsync (ubuntu 20.04) to Synology DS218 option -a doesnot preserve user name and group of files

kr flag

I have been on the internet searching for my problem. I use rsync to copy files from my ubuntu 20.04 desktop to NAS Synology DS218+. It worked fine with ubuntu 18.04.

I was able to reproduce the error manually on the terminal, so that makes it easy to tell you the problem. Normally my backup runs in the background via a cron job.

The Synology share is mounted as follows:

///backup /mnt/cifs cifs credentials=,vers=1.0,iocharset=utf8,sec=ntlm 0 0

And works.

Now the problem

rsync -av ~/tmp /mnt/cifs

option -a should preserve the user name and group also, my files on the ubuntu desktop are of my username:my usergroup. The error log shows following error:

rsync: chgrp "/mnt/cifs/tmp" failed: Operation not permitted (1)

The directory tmp is created on the NAS anyhow. The user name now is 1026 (not my user name) of the user group users (initially not assigned to my user name).

Question How can I really preserve username and usergroup of the files. On the NAS I use the same user name as for ubuntu and this user has read write access to the share.

24601 avatar
in flag
I use LuckyBackup to backup files to my Synology NAS. The command issued is: `rsync -h --progress --stats -r -tgo -p -l -D --update --delete-after /home/graham/Dropbox/ /media/NAS/GnV_Common/DropboxG/` which addresses the share directly using the full path to it. You might want to use LuckyBackup (from the USC) to initially build your instruction set then utilise it in your cron job later (if that is your preference).
kees_ubuntu avatar
kr flag
Thnx, but also when I use the exact options as above, the same problem occurs.
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.