* [PATCH] xfs_quota: Enable 3 more foreign commands
@ 2016-09-15 21:53 Eric Sandeen
2016-09-16 13:30 ` Bill O'Donnell
0 siblings, 1 reply; 2+ messages in thread
From: Eric Sandeen @ 2016-09-15 21:53 UTC (permalink / raw)
To: xfs-oss
Enable restore, limit, and timer.
Unsupported commands remain, for lack of kernel support, generally:
warn, quot,, enable, disable, and remove.
xfs_quota> report
User quota on /mnt/test2/git/xfsprogs/mnt (/dev/loop0)
Blocks
User ID Used Soft Hard Warn/Grace
---------- --------------------------------------------------
root 13 0 0 00 [--------]
xfs_quota> restore -f quotadump
xfs_quota> report
User quota on /mnt/test2/git/xfsprogs/mnt (/dev/loop0)
Blocks
User ID Used Soft Hard Warn/Grace
---------- --------------------------------------------------
root 13 0 0 00 [--------]
testuser 0 16384 32768 00 [--------]
fsgqa 0 102400 112640 00 [--------]
xfs_quota> limit bsoft=200m fsgqa
xfs_quota> report
User quota on /mnt/test2/git/xfsprogs/mnt (/dev/loop0)
Blocks
User ID Used Soft Hard Warn/Grace
---------- --------------------------------------------------
root 13 0 0 00 [--------]
testuser 0 16384 32768 00 [--------]
fsgqa 0 204800 112640 00 [--------]
xfs_quota> state -u
User quota state on /mnt/test2/git/xfsprogs/mnt (/dev/loop0)
Accounting: ON
Enforcement: ON
Inode: #12 (16 blocks, 1 extents)
Blocks grace time: [7 days]
Inodes grace time: [7 days]
xfs_quota> timer -b 3days
xfs_quota> state -u
User quota state on /mnt/test2/git/xfsprogs/mnt (/dev/loop0)
Accounting: ON
Enforcement: ON
Inode: #12 (16 blocks, 1 extents)
Blocks grace time: [3 days]
Inodes grace time: [7 days]
Realtime Blocks grace time: [--------]
Signed-off-by: Eric Sandeen <sandeen@redhat.com>
---
diff --git a/quota/edit.c b/quota/edit.c
index e5ddc8c..36b327a 100644
--- a/quota/edit.c
+++ b/quota/edit.c
@@ -709,6 +709,7 @@ edit_init(void)
_("[-g|-p|-u] bsoft|bhard|isoft|ihard|rtbsoft|rtbhard=N -d|id|name");
limit_cmd.oneline = _("modify quota limits");
limit_cmd.help = limit_help;
+ limit_cmd.flags = CMD_FLAG_FOREIGN_OK;
restore_cmd.name = "restore";
restore_cmd.cfunc = restore_f;
@@ -716,6 +717,7 @@ edit_init(void)
restore_cmd.argmax = -1;
restore_cmd.args = _("[-g|-p|-u] [-f file]");
restore_cmd.oneline = _("restore quota limits from a backup file");
+ restore_cmd.flags = CMD_FLAG_FOREIGN_OK;
timer_cmd.name = "timer";
timer_cmd.cfunc = timer_f;
@@ -724,6 +726,7 @@ edit_init(void)
timer_cmd.args = _("[-bir] [-g|-p|-u] value");
timer_cmd.oneline = _("set quota enforcement timeouts");
timer_cmd.help = timer_help;
+ timer_cmd.flags = CMD_FLAG_FOREIGN_OK;
warn_cmd.name = "warn";
warn_cmd.cfunc = warn_f;
_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] xfs_quota: Enable 3 more foreign commands
2016-09-15 21:53 [PATCH] xfs_quota: Enable 3 more foreign commands Eric Sandeen
@ 2016-09-16 13:30 ` Bill O'Donnell
0 siblings, 0 replies; 2+ messages in thread
From: Bill O'Donnell @ 2016-09-16 13:30 UTC (permalink / raw)
To: Eric Sandeen; +Cc: xfs-oss
On Thu, Sep 15, 2016 at 04:53:51PM -0500, Eric Sandeen wrote:
> Enable restore, limit, and timer.
>
> Unsupported commands remain, for lack of kernel support, generally:
> warn, quot,, enable, disable, and remove.
>
> xfs_quota> report
> User quota on /mnt/test2/git/xfsprogs/mnt (/dev/loop0)
> Blocks
> User ID Used Soft Hard Warn/Grace
> ---------- --------------------------------------------------
> root 13 0 0 00 [--------]
>
> xfs_quota> restore -f quotadump
> xfs_quota> report
> User quota on /mnt/test2/git/xfsprogs/mnt (/dev/loop0)
> Blocks
> User ID Used Soft Hard Warn/Grace
> ---------- --------------------------------------------------
> root 13 0 0 00 [--------]
> testuser 0 16384 32768 00 [--------]
> fsgqa 0 102400 112640 00 [--------]
>
> xfs_quota> limit bsoft=200m fsgqa
>
> xfs_quota> report
> User quota on /mnt/test2/git/xfsprogs/mnt (/dev/loop0)
> Blocks
> User ID Used Soft Hard Warn/Grace
> ---------- --------------------------------------------------
> root 13 0 0 00 [--------]
> testuser 0 16384 32768 00 [--------]
> fsgqa 0 204800 112640 00 [--------]
>
> xfs_quota> state -u
> User quota state on /mnt/test2/git/xfsprogs/mnt (/dev/loop0)
> Accounting: ON
> Enforcement: ON
> Inode: #12 (16 blocks, 1 extents)
> Blocks grace time: [7 days]
> Inodes grace time: [7 days]
>
> xfs_quota> timer -b 3days
> xfs_quota> state -u
> User quota state on /mnt/test2/git/xfsprogs/mnt (/dev/loop0)
> Accounting: ON
> Enforcement: ON
> Inode: #12 (16 blocks, 1 extents)
> Blocks grace time: [3 days]
> Inodes grace time: [7 days]
> Realtime Blocks grace time: [--------]
>
> Signed-off-by: Eric Sandeen <sandeen@redhat.com>
Reviewed-by: Bill O'Donnell <billodo@redhat.com>
> ---
>
> diff --git a/quota/edit.c b/quota/edit.c
> index e5ddc8c..36b327a 100644
> --- a/quota/edit.c
> +++ b/quota/edit.c
> @@ -709,6 +709,7 @@ edit_init(void)
> _("[-g|-p|-u] bsoft|bhard|isoft|ihard|rtbsoft|rtbhard=N -d|id|name");
> limit_cmd.oneline = _("modify quota limits");
> limit_cmd.help = limit_help;
> + limit_cmd.flags = CMD_FLAG_FOREIGN_OK;
>
> restore_cmd.name = "restore";
> restore_cmd.cfunc = restore_f;
> @@ -716,6 +717,7 @@ edit_init(void)
> restore_cmd.argmax = -1;
> restore_cmd.args = _("[-g|-p|-u] [-f file]");
> restore_cmd.oneline = _("restore quota limits from a backup file");
> + restore_cmd.flags = CMD_FLAG_FOREIGN_OK;
>
> timer_cmd.name = "timer";
> timer_cmd.cfunc = timer_f;
> @@ -724,6 +726,7 @@ edit_init(void)
> timer_cmd.args = _("[-bir] [-g|-p|-u] value");
> timer_cmd.oneline = _("set quota enforcement timeouts");
> timer_cmd.help = timer_help;
> + timer_cmd.flags = CMD_FLAG_FOREIGN_OK;
>
> warn_cmd.name = "warn";
> warn_cmd.cfunc = warn_f;
>
> _______________________________________________
> xfs mailing list
> xfs@oss.sgi.com
> http://oss.sgi.com/mailman/listinfo/xfs
_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2016-09-16 13:30 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-09-15 21:53 [PATCH] xfs_quota: Enable 3 more foreign commands Eric Sandeen
2016-09-16 13:30 ` Bill O'Donnell
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).