xfs
[Top] [All Lists]

Re: quota on xfs

To: linux-xfs@xxxxxxxxxxx
Subject: Re: quota on xfs
From: Ethan Benson <erbenson@xxxxxxxxxx>
Date: Tue, 16 Apr 2002 23:27:50 -0800
In-reply-to: <20020417065035.GA16162@ids.org.au>; from ian@ids.org.au on Wed, Apr 17, 2002 at 04:50:35PM +1000
Mail-copies-to: nobody
Mail-followup-to: linux-xfs@xxxxxxxxxxx
References: <20020417065035.GA16162@ids.org.au>
Sender: owner-linux-xfs@xxxxxxxxxxx
User-agent: Mutt/1.2.5i
On Wed, Apr 17, 2002 at 04:50:35PM +1000, Ian Cumming wrote:
> Hi,
> 
> I've noticed something strange with quotas on xfs (kernel 2.4.18, Debian 
> Woody,
> latest XFS patch).
> 
> As root, quota works fine. ie:
> 
> newserver:/usr/share/doc/quota# quota ian
> Disk quotas for user ian (uid 1000):
> Filesystem  blocks   quota   limit   grace   files   quota   limit grace
> /dev/hda8       0   20480   51200               1   10000   15000
> /dev/hdc5      28  204800  225280              11  50000   55000
> 
> 
> However, as a user, I get:
> 
> ian@newserver:~$ quota
> Disk quotas for user ian (uid 1000): none
> 
> 
> This happens even if I specify xfs to the quota command.
> 
> I'm not sure if this should be directed to the linux-quota folks, but I
> thought I would ask in here first.

i found this earlier, search the archives for `quota permissions'
basically the quota syscalls are returning -EPERM for non-root, this
is a bug in the 2.4.18 split XFS patches, the following patch will
fix it:

$ diff -Naur quota.c.orig quota.c
--- quota.c.orig        Mon Mar 25 12:19:57 2002
+++ quota.c     Mon Mar 25 12:20:55 2002
@@ -47,6 +47,7 @@
                             (type == GRPQUOTA && !in_egroup_p(id))) &&
                            !capable(CAP_SYS_ADMIN))
                                goto error;
+                       break;

                default:
                        if (!capable(CAP_SYS_ADMIN))


this is already merged in the XFS cvs tree.

-- 
Ethan Benson
http://www.alaska.net/~erbenson/

Attachment: pgp3421b5MvHi.pgp
Description: PGP signature

<Prev in Thread] Current Thread [Next in Thread>