Backing Up ACLs
One of the things you need to be aware of if you plan to use ACLs is that
most backup utilities will correctly backup files containing ACLs, and even
restore those files, but not their ACLs. A good solution to this is to install
/usr/ports/archivers/star from the ports collection. If you've ever
tar, it won't take long to train yourself to add a few extra
switches to catch all of those ACLs.
In this example, the superuser has made a backup directory for
dru outside of her home directory so she can store backups of her
# mkdir -p /usr/backups/dru # chmod dru:dru /usr/backups/dru # exit
dru backs up her home directory, which contains files with
% whoami dru % cd % star -cv -Hexustar -acl -f /usr/backups/dru/home.tgz .
dru will try a test restore in a temporary directory in
her home directory:
% mkdir ~/tmp % cd ~/tmp % star -xv -Hexustar -acl -f home.tgz
Note: If you try to restore to a filesystem that doesn't have ACLs enabled,
star will complain but will still restore the files minus the
Many users either haven't yet heard of the benefits of ACLs or believe them
to be difficult to use. Spend a half an hour showing your users how to use
star, and they'll wonder how they ever
lived without ACLs.
Dru Lavigne is a network and systems administrator, IT instructor, author and international speaker. She has over a decade of experience administering and teaching Netware, Microsoft, Cisco, Checkpoint, SCO, Solaris, Linux, and BSD systems. A prolific author, she pens the popular FreeBSD Basics column for O'Reilly and is author of BSD Hacks and The Best of FreeBSD Basics.
Read more FreeBSD Basics columns.
Return to the BSD DevCenter