使用 rsync 出错:rsync: chgrp "XXXX" failed: Operation not permitted

Posted

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了使用 rsync 出错:rsync: chgrp "XXXX" failed: Operation not permitted相关的知识,希望对你有一定的参考价值。

You are probably running rsync like this:

rsync -a dir/ remote:/dir/

The -a option according to the documentation is equivalent to: -rlptgoD

      -a, --archive    archive mode; equals -rlptgoD (no -H,-A,-X)

You probably want to remove the -o and -g options:

      -o, --owner                 preserve owner (super-user only)
      -g, --group                 preserve group

So instead your rsync command should look something like this:

rsync -rlptD dir/ remote:/dir/

Or as @glglgl points out:

rsync -a --no-o --no-g dir/ remote:/dir/

The remaining options in use are:

      -r, --recursive             recurse into directories
      -l, --links                 copy symlinks as symlinks
      -p, --perms                 preserve permissions
      -t, --times                 preserve modification times
      -D                          same as --devices --specials
          --devices               preserve device files (super-user only)
          --specials              preserve special files


以上是关于使用 rsync 出错:rsync: chgrp "XXXX" failed: Operation not permitted的主要内容,如果未能解决你的问题,请参考以下文章

rsync: chgrp "." (in backup) failed:Operation not

rsync报错:rsync: chgrp ".hejian.txt.D1juHb" (in backup) failed: Operation not permitted

linux rsync配置出错

rsync添加多模块,客户端推送出错!

服务器迁移 rsync

Centos7 rsync 实现文件同步