[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: quota permissions
hi Ethan,
This EPERM sounds like a botch in the spilt patches. CVS works
fine for me after a quick test, but CVS has different quota code.
Could you mail me your fs/quota.c please? (will save me having
to download and apply the split patches).
The tools problem is known and has been fixed in current devel
tools, not yet released (the workaround you used should always
work).
thanks.
On Sun, Mar 24, 2002 at 04:32:03AM -0900, Ethan Benson wrote:
>
> I started testing quotas on XFS and found that users cannot find out
> what thier quota is set to, this is normally found by running the
> quota command, under 2.2 kernels (this is the first time ive used
> quota under 2.4) quota details are printed for any filesystems which
> they have files, with 2.4 and XFS (2.4.18) quota always reports that
> they have no quotas.
>
> strace shows that this appears to be due to the quota syscalls
> returning EPERM:
>
> eb@ash ~$ quota
> Disk quotas for user eb (uid 1000): none
> eb@ash ~$ quota -u eb
> Disk quotas for user eb (uid 1000): none
> eb@ash ~$ sudo quota -u eb
> Disk quotas for user eb (uid 1000):
> Filesystem blocks quota limit grace files quota limit grace
> /dev/hda9 0 20480 25600 1 6000 8000
> eb@ash ~$
>
> strace reveals:
>
> quotactl(0x5805 /* Q_??? */|USRQUOTA, "/dev/hda9", 0, {16777219, 0, 0, 131, 0, 7, 5, 0}) = 0
> stat64(0x10024f88, 0x100274d0) = 0
> quotactl(0x5805 /* Q_??? */|USRQUOTA, "/dev/hda9", 0, {16777219, 0, 0, 131, 0, 7, 5, 0}) = 0
> geteuid() = 1000
> quotactl(0x5803 /* Q_??? */|USRQUOTA, "/dev/hda9", 1000, {2147481280, 805354732, 805463848, 2147481248, 2147481296, 805354732, 2147481280, 267568876}) = -1 EPERM (Operation not permitted)
>
> I used the split patches, the following were applied:
> xfs-2.4.18-split-only.bz2
> xfs-2.4.18-split-xattr.bz2
> xfs-2.4.18-split-quota32.bz2
> xfs-2.4.18-split-kernel.bz2
> xfs-2.4.18-split-misc.bz2
> xfs-2.4.18-split-acl-dmapi.bz2
>
> as a sidenote, this is probably a quota userland bug, but edquota
> refused to work initially after activating quotas (i unmounted and
> remounted the filesystem with the quota mountopt) i had to use edquota
> -F xfs -u user for the first time, after this it seems to figure out
> the format without -F. im using quota 3.0.4-1 from debian woody.
>
> --
> Ethan Benson
> http://www.alaska.net/~erbenson/
--
Nathan