* Available space after enable quota in XFS
@ 2012-11-20 6:46 geturmaddy
2012-11-20 9:07 ` Dave Chinner
0 siblings, 1 reply; 2+ messages in thread
From: geturmaddy @ 2012-11-20 6:46 UTC (permalink / raw)
To: xfs
[-- Attachment #1.1: Type: text/plain, Size: 1467 bytes --]
Hi all,
I am trying to evaluation XFS for NFS server. We need to configure
directory level quota in order to better manage storage in the server. I
came to know that, we can use project quota which looks similar to
directory level quotas.
I was able to configure project level quota for XFS file system in my
Cent)S 5.7 machine. Below are the details
[root@linux-nfs ~]# cat /etc/issue
CentOS release 5.6 (Final)
Kernel \r on an \m
[root@linux-nfs ~]# cat /etc/projects
13:/das/myproject1
[root@linux-nfs ~]# cat /etc/projid
myproject1:13
[root@linux-nfs ~]# xfs_quota -xc 'report -p' /das
Project quota on /das (/dev/cciss/c0d0)
Blocks
Project ID Used Soft Hard Warn/Grace
---------- --------------------------------------------------
myproject1 0 0 102400 00 [--------]
You can see the hard limit set to 1G. But, when i check directory space
using df -h command. its showing entire file system space in "Avail" column.
[root@linux-nfs ~]# df -h /das/myproject1/
Filesystem Size Used *Avail *Use% Mounted on
/dev/cciss/c0d0 100M 0 *13T *0% /das
Is there a way we can restrict showing entire FS size in Avail column (or
show available space which is left after using the allocated quota i.e,
Avail space = Size - Used) ? This actually cause confusion to end user who
things they still have enough space in the directory.
Thanks in advance
__madhusudhan
[-- Attachment #1.2: Type: text/html, Size: 1928 bytes --]
[-- Attachment #2: Type: text/plain, Size: 121 bytes --]
_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: Available space after enable quota in XFS
2012-11-20 6:46 Available space after enable quota in XFS geturmaddy
@ 2012-11-20 9:07 ` Dave Chinner
0 siblings, 0 replies; 2+ messages in thread
From: Dave Chinner @ 2012-11-20 9:07 UTC (permalink / raw)
To: geturmaddy@gmail.com; +Cc: xfs
On Tue, Nov 20, 2012 at 12:16:32PM +0530, geturmaddy@gmail.com wrote:
> Hi all,
> I am trying to evaluation XFS for NFS server. We need to configure
> directory level quota in order to better manage storage in the server. I
> came to know that, we can use project quota which looks similar to
> directory level quotas.
>
> I was able to configure project level quota for XFS file system in my
> Cent)S 5.7 machine. Below are the details
>
> [root@linux-nfs ~]# cat /etc/issue
> CentOS release 5.6 (Final)
> Kernel \r on an \m
>
> [root@linux-nfs ~]# cat /etc/projects
> 13:/das/myproject1
>
> [root@linux-nfs ~]# cat /etc/projid
> myproject1:13
>
> [root@linux-nfs ~]# xfs_quota -xc 'report -p' /das
> Project quota on /das (/dev/cciss/c0d0)
> Blocks
> Project ID Used Soft Hard Warn/Grace
> ---------- --------------------------------------------------
> myproject1 0 0 102400 00 [--------]
>
> You can see the hard limit set to 1G. But, when i check directory space
> using df -h command. its showing entire file system space in "Avail" column.
>
> [root@linux-nfs ~]# df -h /das/myproject1/
> Filesystem Size Used *Avail *Use% Mounted on
> /dev/cciss/c0d0 100M 0 *13T *0% /das
Your kernel is too old to support project quotas showing up properly
in df output.
A current kernel shows:
$ sudo xfs_quota -x -c 'project -s -p /mnt/scratch/foo 42' /mnt/scratch
Setting up project 42 (path /mnt/scratch/foo)...
Processed 1 (/etc/projects and cmdline) paths for project 42 with recursion depth infinite (-1).
$ sudo xfs_quota -x -c 'limit -p bhard=1g 42' /mnt/scratch
$ sudo dd if=/dev/zero of=/mnt/scratch/foo/bar bs=1024k count=100
100+0 records in
100+0 records out
104857600 bytes (105 MB) copied, 0.133275 s, 787 MB/s
$ sync
$ $ df -h /mnt/scratch /mnt/scratch/foo
Filesystem Size Used Avail Use% Mounted on
/dev/vdb 11G 133M 11G 2% /mnt/scratch
/dev/vdb 1.0G 100M 924M 10% /mnt/scratch
Which is exactly what you are asking for. Solution: upgrade.
Cheers,
Dave.
--
Dave Chinner
david@fromorbit.com
_______________________________________________
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:[~2012-11-20 9:05 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-11-20 6:46 Available space after enable quota in XFS geturmaddy
2012-11-20 9:07 ` Dave Chinner
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox