Skip to contentSkip to conversation

Reporting project quota usage?

DISCUSSION Theodore Ts'o 5 participants 10 messages Mar 16, 2016 – Mar 31, 2016

lore
Share & tools
lore
#0 lore raw

Am I missing something, or do we currently don't have a way to report project quota usage with ext4? The support doesn't appear to be in quota tools, and xfs_quota doesn't work without changes because it only tries to operate on XFS file systems.

Thanks,

- Ted

#1 lore raw
Quoted 5 lines · Theodore Ts'o

Am I missing something, or do we currently don't have a way to report project quota usage with ext4? The support doesn't appear to be in quota tools, and xfs_quota doesn't work without changes because it only tries to operate on XFS file systems.

At one time I thought Dave was going to patch xfs_quota to try the quota ioctls for "foreign" filesystems like ext4 that supported them, but I'm not sure if that patch was landed, nor whether it has been released.

On the opposite front, Jan was updating the generic quota tools to support the XFS ioctls that project quota is using?

Cheers, Andreas

#2 lore raw
Quoted 7 lines · Andreas Dilger

At one time I thought Dave was going to patch xfs_quota to try the quota ioctls for "foreign" filesystems like ext4 that supported them, but I'm not sure if that patch was landed, nor whether it has been released.

On the opposite front, Jan was updating the generic quota tools to support the XFS ioctls that project quota is using?

It's quite possible I'm missing something, but it doesn't look like either has landed. I've hacked xfs_quota (not anything that I would want to submit for merging) so I can report usage project quota stats, and to be able to set hard and soft limits. But I was trying to figure out what we should be telling users who wanted to use Project Quota, but I'm pretty sure "pull down xfsprogs sources, and apply this hacky patch[1], and then when you use the tooll ignore a whole bunch of spurious warnings" is the right way to go. :-)

I am also curious how Li Xi was testing the patches he sent me.

- Ted

[1]

libxcmd/paths.c +2 -2
index 5c65737..6c69a35 100644
@@ -301,8 +301,8 @@ fs_table_initialise_mounts(
 			return errno;
 
 	while ((mnt = getmntent(mtp)) != NULL) {
-		if (strcmp(mnt->mnt_type, "xfs") != 0)
-			continue;
+//		if (strcmp(mnt->mnt_type, "xfs") != 0)
+//			continue;
 		if (!realpath(mnt->mnt_dir, rmnt_dir))
 			continue;
 		if (!realpath(mnt->mnt_fsname, rmnt_fsname))
#3 lore raw
Quoted 6 lines · Theodore Ts'o
Quoted 5 lines · Andreas Dilger

At one time I thought Dave was going to patch xfs_quota to try the quota ioctls for "foreign" filesystems like ext4 that supported them, but I'm not sure if that patch was landed, nor whether it has been released.

Quoted 6 lines
Quoted 2 lines

On the opposite front, Jan was updating the generic quota tools to support the XFS ioctls that project quota is using?

It's quite possible I'm missing something, but it doesn't look like either has landed. I've hacked xfs_quota (not anything that I would want to submit for merging)

I posted a patch to do it, but I haven't had a chance to fix the problems Eric noticed because other stuff happened.

You're welcome to fix it up and repost it:

http://oss.sgi.com/archives/xfs/2016-02/msg00109.html

Cheers,

Dave.

Signature · 2 lines
Dave Chinner
[email protected]
#4 lore raw
In reply to Theodore Ts'o
Quoted 18 lines · Ted Tso
Quoted 7 lines · Andreas Dilger

At one time I thought Dave was going to patch xfs_quota to try the quota ioctls for "foreign" filesystems like ext4 that supported them, but I'm not sure if that patch was landed, nor whether it has been released.

On the opposite front, Jan was updating the generic quota tools to support the XFS ioctls that project quota is using?

It's quite possible I'm missing something, but it doesn't look like either has landed. I've hacked xfs_quota (not anything that I would want to submit for merging) so I can report usage project quota stats, and to be able to set hard and soft limits. But I was trying to figure out what we should be telling users who wanted to use Project Quota, but I'm pretty sure "pull down xfsprogs sources, and apply this hacky patch[1], and then when you use the tooll ignore a whole bunch of spurious warnings" is the right way to go. :-)

Quoted 1 line

I am also curious how Li Xi was testing the patches he sent me.

As Li Xi mentioned, he has a patch for quota-tools which implements the project quota support but it needs some cleanup (you can check my reply to email "[PATCH] Add project quota support" - it didn't go to any list but you were CCed). Li Xi, do you have any idea when you can get to it?

Honza

Signature · 2 lines
Jan Kara <[email protected]>
SUSE Labs, CR
#5 lore raw
In reply to Theodore Ts'o

Hi,

I sent a patch of quota tool to Jan Kara ccing you. With that patch, project quota
of ext4 can be reported. However, that patch needs a lot of improvement.

That patch can be found here too:

https://github.com/ddn-lixi/project_quota_ext4_utils/blob/master/quota-tools.git/patches/project_quota_support_for_quota-tools.patch

Regards,
Li Xi

Quoted 8 lines · Theodore Ts'o

Am I missing something, or do we currently don't have a way to report project quota usage with ext4? The support doesn't appear to be in quota tools, and xfs_quota doesn't work without changes because it only tries to operate on XFS file systems.

Thanks,

- Ted

#6 lore raw

Hi,

Quoted 7 lines · Li Xi

I sent a patch of quota tool to Jan Kara ccing you. With that patch, project quota
of ext4 can be reported. However, that patch needs a lot of improvement.

That patch can be found here too:

https://github.com/ddn-lixi/project_quota_ext4_utils/blob/master/quota-tools.git/patches/project_quota_support_for_quota-tools.patch

Li Xi, if I find time to massage the patch into usable form, can I add your Signed-off-by so that I can commit it in quota-tools repository?

Honza

Quoted 9 lines · Theodore Ts'o
Quoted 8 lines

Am I missing something, or do we currently don't have a way to report project quota usage with ext4? The support doesn't appear to be in quota tools, and xfs_quota doesn't work without changes because it only tries to operate on XFS file systems.

Thanks,

- Ted

Signature · 2 lines
Jan Kara <[email protected]>
SUSE Labs, CR
#7 lore raw
Quoted 7 lines · Jan Kara

Hi,

Quoted 4 lines · Li Xi

I sent a patch of quota tool to Jan Kara ccing you. With that patch, project quota
of ext4 can be reported. However, that patch needs a lot of improvement.

Quoted 6 lines
Quoted 3 lines

That patch can be found here too:

https://github.com/ddn-lixi/project_quota_ext4_utils/blob/master/quota-tools.git/patches/project_quota_support_for_quota-tools.patch

Li Xi, if I find time to massage the patch into usable form, can I add your Signed-off-by so that I can commit it in quota-tools repository?

Ping? Without your Signed-off-by tag I cannot really add your code into quota-tools repository...

Honza

Signature · 2 lines
Jan Kara <[email protected]>
SUSE Labs, CR
#8 lore raw

Hi Jan Kara,

Sorry for delay.

Please feel free to add "Signed-off-by: Li Xi <[email protected]>".

Regards,
Li Xi

Quoted 22 lines · Jan Kara
Quoted 7 lines · Jan Kara

Hi,

Quoted 4 lines · Li Xi

I sent a patch of quota tool to Jan Kara ccing you. With that patch, project quota
of ext4 can be reported. However, that patch needs a lot of improvement.

Quoted 6 lines
Quoted 3 lines

That patch can be found here too:

https://github.com/ddn-lixi/project_quota_ext4_utils/blob/master/quota-tools.git/patches/project_quota_support_for_quota-tools.patch

Li Xi, if I find time to massage the patch into usable form, can I add your Signed-off-by so that I can commit it in quota-tools repository?

Ping? Without your Signed-off-by tag I cannot really add your code into quota-tools repository...

Honza
--
Jan Kara <[email protected]>
SUSE Labs, CR

#9 lore raw

Hi!

Quoted 3 lines · Li Xi

Sorry for delay.

Please feel free to add "Signed-off-by: Li Xi <[email protected]>".

Thanks. I have pushed out patches with project quota support to quota-tools reporsitories.

Honza

Signature · 2 lines
Jan Kara <[email protected]>
SUSE Labs, CR