Rsync Directory Replication
I'm trying to synchronize two directories on two separate server and haven't found many good ways to do it. I've concluded that rsync and cron is the best way. I synchronize the shares and then use Samba as a way to access the shares from windows machines. My question is... if I syncronize the owner and group and permissions over, will anything go wrong. I've never understood how that works with UIDs and all
|
you would need to explain what is that anything which went wrong. We cannot fix anything. What did you make and what was the error message you got?
|
I havent done anything yet. I'm asking if I do set this up, will I have troubles. I read that keeping the ownership and permissions on the files can mess things up if the UIDs don't match. Is this the case.
|
I think the OP is asking of something is likely to go wrong. The answer is "yes."
You can find the UIDs of your users with the following command: Code:
less /etc/passwd Code:
root:x:0:0:root:/root:/bin/bash The problem is making the UIDs from one PC match those on another so that you can access them from the other PC. Alternatively, you can use a chown or find/chown command to change the UID or user (that is, by name or by number) to one on the other system--either as part of the backup process or as part of accessing the data. I don't recommend using chmod, since this will basically defeat the purpose of keeping the user the same (by setting all the permissions to rwx or some such). You should look into how rsync deals with user preservation--whether by name or UID. Also look into "--owner", "--group", "--super", "--fake-super", and any others you find in rsync. Hope that helps. --Dane |
All times are GMT -5. The time now is 12:32 PM. |