How to copy ACLs on ZFS with tar ?

Edward Tomasz Napierała trasz at FreeBSD.org
Sat Mar 4 13:37:15 UTC 2017


> On 4 Mar 2017, at 11:50, Kurt Jaeger <pi at FreeBSD.org> wrote:
> 
> Hi!
> 
> I have a file with the following ACL (in fact, a whole tree with files
> like that):
> 
> srv$ getfacl myfile
> # file: myfile
> # owner: myuser
> # group: domain-users
>      group:myuser:rw-p--aARWcCo-:-------:allow
>            group@:rw-p--a-R-c---:-------:allow
>         everyone@:rw-p--a-R-c---:-------:allow
> 
> How do I copy this file or the tree with tar, while preserving the ACLs ?
> Or do I have to use something else ?

Not sure about tar, but plain "cp -p" should do the trick.



More information about the freebsd-stable mailing list