Linux - GeneralThis Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I'm setting up rsync to backup my files to a separate computer every night. I've found some very good docs which have made the process very simple to setup and use.
I have 1 problem howerver: My backups all have the ownership of the rsync process instead of the original owner.
I have a cron job which runs rsync as the user "archiver", and copies files from the "/home" directories onto the backup disk. When I look at the files on the backup disk, I find that the owner and group of these files are all set to "archiver", NOT the original owners.
I am using the rsync "--archive" flag, and also explicitly setting both the "--owner" and "--group" flags (to no effect).
I had to set the backup directory to allow the user "archiver" to be able to write to the directory, so I suspect I've got a permissions problem inherent in my Debian system.
Can anyone suggest a possible solution or area for investigation?
rsync process uid? What is the exact command your using to back these files up to your other computer and the user one computer A, does their uid match the same user on computer B?
the user archiver is common on both computers, and I have exchanged the "authorized keys" files so no passwords have to be exchanged. Obviously, I dont want to pass along authorized keys for the root user on both computers.
Just curious, what did you ultimately do here? Were you ever able to get rsync to run as a non-root user *and* maintain the original owner of the copied files?
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.