ZFS panic: empty ZFS ACL
James R. Van Artsdalen
james-freebsd-fs2 at jrv.org
Mon Nov 29 01:08:10 UTC 2010
Edward Tomasz Napierała wrote:
> Could you try the patch below?
>
> Index: sys/cddl/compat/opensolaris/kern/opensolaris_acl.c
> ===================================================================
> --- sys/cddl/compat/opensolaris/kern/opensolaris_acl.c (revision 215553)
> +++ sys/cddl/compat/opensolaris/kern/opensolaris_acl.c (working copy)
> @@ -105,7 +105,10 @@
> struct acl_entry *entry;
> const ace_t *ace;
>
> - KASSERT(nentries >= 1, ("empty ZFS ACL"));
> + if (nentries < 1) {
> + printf("acl_from_aces: empty ZFS ACL; returning EINVAL.\n");
> + return (EINVAL);
> + }
>
> if (nentries > ACL_MAX_ENTRIES) {
> /*
>
> --
> If you cut off my head, what would I say? Me and my head, or me and my body?
>
The patch prevents the panic but EINVAL propagates back up to the
application in an undesirable way:
kraken:/root# ls -ld /STUFF/fearhome/Backups
ls: /STUFF/fearhome/Backups: Invalid argument
drwxr-xr-x 9 james james 10 Oct 17 2007 /STUFF/fearhome/Backups
kraken:/root#
More information about the freebsd-fs
mailing list