xfs
[Top] [All Lists]

Re: Problem setting up quotas ...

To: Jan Rekorajski <baggins@xxxxxxxxxxxxxxxxx>
Subject: Re: Problem setting up quotas ...
From: James Pearson <james-p@xxxxxxxxxxxxxxxxxx>
Date: Thu, 03 May 2001 16:47:38 +0100
Cc: linux-xfs@xxxxxxxxxxx
Organization: Moving Picture Company
References: <3AF16D0A.2D12C344@moving-picture.com> <20010503170018.A31942@sith.mimuw.edu.pl>
Sender: owner-linux-xfs@xxxxxxxxxxx
Jan Rekorajski wrote:
> 
> On Thu, 03 May 2001, James Pearson wrote:
> 
> > I've just installed RedHat 7.1/XFS1.0 on a Athlon based system and I'm
> > trying to get quotas working - so far without success.
> >
> > I've made a XFS file system and mounted it with -o quota and tried to
> > follow the instructions in the quotaon man page and
> > /usr/share/doc/xfsprogs/README.quota but get the following:
> >
> > # rpm -q quota
> > quota-3.01-SGI_5
> >
> > # uname -r
> > 2.4.2-SGI_XFS_1.0
> >
> > # mount | grep quota
> > /dev/hda4 on /disk1 type xfs (rw,quota)
> >
> > # setquota james 600 800 15 20 /disk1
> > Not all specified mountpoints are using quota.
> >
> > # repquota /disk1
> > Not all specified mountpoints are using quota.
> >
> > # edquota james
> > No filesystems with quota detected.
> >
> > I've also recompiled the kernel with CONFIG_QUOTA=y and
> > CONFIG_XFS_QUOTA=y just in case the supplied kernel didn't have quotas
> > enabled - but with the same results.
> >
> > Is there anything else I need to do?
> 
> I had the same problem. It may be the effect of misplaced patch.
> 
> Look in the fs/dquot.c file somewhere around line 1450,
> and move the following after the if (special != NULL...) statement:
> 
>         if (sb && sb->s_op && sb->s_op->quotactl) {
>                 unlock_kernel();
>                 return sb->s_op->quotactl(sb, cmds, type, id, addr);
>         }
> 
>         if (id & ~0xFFFF)
>                 goto out;
> 
> I don't know why, but it happened.
> 

Not quite sure what needs to be moved where - there's nothing like that
around line 1450, but at around line 2050 there is:

        dev = NODEV;
        if (special != NULL || (cmds != Q_SYNC && cmds != Q_GETSTATS)) {
                mode_t mode;
                struct nameidata nd;

                ret = user_path_walk(special, &nd);
                if (ret)
                        goto out;

                dev = nd.dentry->d_inode->i_rdev;
                mode = nd.dentry->d_inode->i_mode;
                path_release(&nd);

                ret = -ENOTBLK;
                if (!S_ISBLK(mode))
                        goto out;
                ret = -ENODEV;
                sb = get_super(dev);
                if (!sb)
                        goto out;
        }

        if (sb && sb->s_op && sb->s_op->quotactl) {
                unlock_kernel();
                return sb->s_op->quotactl(sb, cmds, type, id, addr);
        }

        if (id & ~0xFFFF)
                goto out;

        ret = -EINVAL;


What needs to be changed?

Thanks

James Pearson

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