即使文件内容未更改,rsync 所有权也会更改
我有两个磁盘,它们上的文件几乎相同,只是文件的所有权不同,因为 uid 和 gid 最初不同。
我想找到一种从源磁盘到目标磁盘进行 rsync 的方法,并且自动更改目标磁盘上文件的所有权,即使文件具有相同的大小和上次修改时间。
例如,我的 /mnt/disk1/a.txt 的所有者为 bob:bob,/mnt/disk2/a.txt 的所有者为 alice:alice,a.txt 的所有其他方面都是相同的。 rsync 会识别文件所有权差异吗?
多谢
I have two disks that the files are on them are almost identical except that the ownership on files are different because the uid and gid were originally different.
I want to find a way to rsync from source disk to dest disk and also automatically change the ownership of the files on the destination disk, even if the file has the same size and last modified time.
For example, my /mnt/disk1/a.txt has owner of bob:bob, /mnt/disk2/a.txt has owner of alice:alice, all other aspects of a.txt are the same. Will rsync recognize the file ownership difference?
Thanks a lot
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论