How To preserve file attributes (chattr/lsattr) when copy it to another location
Patrick O'Callaghan
pocallaghan at gmail.com
Tue May 12 15:53:46 UTC 2015
On Tue, 2015-05-12 at 17:13 +0200, Dario Lesca wrote:
> I must copy a dir with some file with 'i' attribute set, but rsync (or
> cp) do not copy this attribute.
>
> See this little example:
>
> # touch testfile
> # chattr +i testfile
> # rsync -aAX testfile testfile2
> # lsattr testfile*
> ----i---------- testfile
> --------------- testfile2
>
> There is a way to copy all attribute?
You don't say what options you tried. According to rsync(1) archive mode
copies attributes.
poc
More information about the users
mailing list