From: Eric Sandeen <sandeen@redhat.com>
To: fsdevel <linux-fsdevel@vger.kernel.org>, xfs@oss.sgi.com
Cc: Jan Kara <jack@suse.cz>
Subject: [PATCH 0/4] quota: add new quotactl Q_XGETQUOTA2
Date: Fri, 8 Jan 2016 10:56:12 -0600 [thread overview]
Message-ID: <568FEA2C.6080708@redhat.com> (raw)
This adds a new quotactl, Q_XGETQUOTA2.
Q_XGETQUOTA2 is exactly like Q_XGETQUOTA, except that it will
return quota information for the id equal to or greater than
the id requested. In other words, if the specified id has
no quota, the command will return quota information for the
next higher id which does have a quota set. If no higher id
has an active quota, -ESRCH is returned.
So if you ask for id X, you can get back quota for id X,
id X+N, or -ESRCH if no higher id has a quota.
This allows filesystems to do efficient iteration in kernelspace,
much like extN filesystems do in userspace when asked to report
all active quotas.
Today, filesystems such as XFS require getpwent()-style iterations,
and for systems which have i.e. LDAP backends, this can be very
slow, or even impossible, if iteration is not allowed in the
configuration.
I have patches to xfsprogs to allow xfs_quota to use this interface,
but I haven't looked at generic quota tools yet TBH. I'll send the
xfsprogs patches to the xfs list shortly.
Using an id as input fits very nicely with existing interfaces;
however, I could imagine that making it a more generic "cookie"
interface might be more extensible; is there any filesystem which
wouldn't be collecting all active IDs in a linear fashion, and
would rather have an arbitrary cookie passed back & forth?
(I hope not) :)
Thanks,
-Eric
_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs
next reply other threads:[~2016-01-08 16:56 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-01-08 16:56 Eric Sandeen [this message]
2016-01-08 16:57 ` [PATCH 1/4] quota: add new quotactl Q_XGETQUOTA2 Eric Sandeen
2016-01-08 16:57 ` [PATCH 2/4] xfs: get quota inode from mp & flags rather than dqp Eric Sandeen
2016-01-08 16:58 ` [PATCH 3/4] xfs: Factor xfs_seek_hole_data into helper Eric Sandeen
2016-01-08 17:07 ` [PATCH 3/4 V2] " Eric Sandeen
2016-01-11 15:57 ` [PATCH 3/4] " Jan Kara
2016-01-11 16:01 ` [PATCH 3/4 V3] " Eric Sandeen
2016-01-08 16:59 ` [PATCH 4/4] xfs: wire up Q_XGETQUOTA2 / get_dqblk2 Eric Sandeen
2016-01-08 18:36 ` [PATCH] linux-quota: wire Q_XGETQUOTA2 into generic repquota Eric Sandeen
2016-01-09 7:26 ` [PATCH 0/4] quota: add new quotactl Q_XGETQUOTA2 Christoph Hellwig
2016-01-11 13:26 ` Jan Kara
2016-01-11 16:07 ` Eric Sandeen
2016-01-11 16:28 ` Jan Kara
2016-01-13 22:40 ` Eric Sandeen
2016-01-13 22:40 ` Eric Sandeen
2016-01-15 9:35 ` Jan Kara
2016-01-15 17:31 ` Eric Sandeen
2016-01-15 19:38 ` Eric Sandeen
2016-01-18 10:33 ` Jan Kara
2016-01-18 11:00 ` Christoph Hellwig
2016-01-18 15:18 ` Eric Sandeen
2016-01-18 15:40 ` Jan Kara
2016-01-19 0:31 ` Eric Sandeen
2016-01-15 22:50 ` Dave Chinner
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=568FEA2C.6080708@redhat.com \
--to=sandeen@redhat.com \
--cc=jack@suse.cz \
--cc=linux-fsdevel@vger.kernel.org \
--cc=xfs@oss.sgi.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox