xfs
[Top] [All Lists]

RE: XFS- Quotas: setting up project quotas

To: Nathan Scott <nathans@xxxxxxx>, Prabhakar Krishnan <kpkar@xxxxxxx>
Subject: RE: XFS- Quotas: setting up project quotas
From: Prabhakar Krishnan <kpkar@xxxxxxx>
Date: Thu, 20 Oct 2005 21:36:20 -0400
Cc: "'linux-xfs@xxxxxxxxxxx'" <linux-xfs@xxxxxxxxxxx>
Sender: linux-xfs-bounce@xxxxxxxxxxx
Nathan

Xfs_allow '-x' option is now showing a whole set of commands that I was
looking for.
Though 'edit' is called 'limit' for setting quota limits.

This 'limit' command doesn't work as expected. Please comment if there was
any configuration/command usage error. Also if there is any new updated xfs
in the latest kernel.

Thanks
-kpkar

(PS: Here@AMI ,I am just evaluating XFS right now .cant say about products)

Config:
------
[root@localhost ~]# uname -a
Linux localhost 2.6.9-1.667smp #1 SMP Thu Oct 6 19:06:02 EDT 2005 i686 i686
i386 GNU/Linux
[root@localhost ~]#
[root@localhost ~]# rpm -qai xfsprogs
Name        : xfsprogs                     Relocations: (not relocatable)
Version     : 2.7.3                             Vendor: Silicon Graphics,
Inc.
Release     : 1                             Build Date: Fri 07 Oct 2005
09:55:39 AM PDT
Install Date: Wed 12 Oct 2005 03:20:55 PM PDT      Build Host:
penguin.americas.sgi.com
Group       : System Environment/Base       Source RPM:
xfsprogs-2.7.3-1.src.rpm
Size        : 2741772                          License: GPL
Signature   : (none)
Packager    : Silicon Graphics, Inc. <http://www.sgi.com/>
URL         : http://oss.sgi.com/projects/xfs/
Summary     : Utilities for managing the XFS filesystem.
Description :
A set of commands to use the XFS filesystem, including mkfs.xfs.

XFS is a high performance journaling filesystem which originated
on the SGI IRIX platform.  It is completely multi-threaded, can
support large files and large filesystems, extended attributes,
variable block sizes, is extent based, and makes extensive use of
Btrees (directories, extents, free space) to aid both performance
and scalability.

Refer to the documentation at http://oss.sgi.com/projects/xfs/
for complete details.  This implementation is on-disk compatible
with the IRIX version of XFS.

Command output:
---------------
[root@localhost ~]# mount
/dev/sda1 on / type ext3 (rw)
none on /proc type proc (rw)
none on /sys type sysfs (rw)
none on /dev/pts type devpts (rw,gid=5,mode=620)
usbfs on /proc/bus/usb type usbfs (rw)
none on /dev/shm type tmpfs (rw)
none on /proc/sys/fs/binfmt_misc type binfmt_misc (rw)
sunrpc on /var/lib/nfs/rpc_pipefs type rpc_pipefs (rw)
nfsd on /proc/fs/nfsd type nfsd (rw)
/dev/mapper/stor1_nas on /volumes/stor1_nas type xfs (rw,usrquota)
/dev/mapper/stor2_nas on /volumes/stor2_nas type xfs (rw,usrquota)
/dev/mapper/stor2_0 on /volumes/stor2_0 type xfs (rw)
/dev/mapper/stor2_quota on /kpkar type xfs (rw,pquota)
[root@localhost /]# cd /kpkar
[root@localhost kpkar]# ls
log  root
[root@localhost kpkar]# ls -l
total 0
drwxr-xr-x  3 root root 16 Oct 20 18:07 log
dr-xrw-rwt  2 root root  6 Oct 12 16:21 root
[root@localhost kpkar]#
[root@localhost ~]# xfs_quota -x
xfs_quota> ?
df [-bir] [-hn] [-f file] -- show free and used counts for blocks and inodes
disable [-gpu] [-v] -- disable quota enforcement
dump [-gpu] [-f file] -- dump quota information for backup utilities
enable [-gpu] [-v] -- enable quota enforcement
help [command] -- help for one or all commands
limit [-gpu] bsoft|bhard|isoft|ihard|rtbsoft|rtbhard=N -d|id|name -- modify
quota  limits
off [-gpu] [-v] -- permanently switch quota off for a path
path [N] -- set current path, or show the list of paths
print -- list known mount points and projects
project [-c|-s|-C] project ... -- check, setup or clear project quota trees
quit -- exit the program
quot [-bir] [-gpu] [-acv] [-f file] -- summarize filesystem ownership
quota [-bir] [-gpu] [-hnv] [-f file] [id|name]... -- show usage and limits
remove [-gpu] [-v] -- remove quota extents from a filesystem
report [-bir] [-gpu] [-ahnt] [-f file] -- report filesystem quota
information
restore [-gpu] [-f file] -- restore quota limits from a backup file
state [-gpu] [-f file] -- get overall quota state information
timer [-bir] [-gpu] value -d|id|name -- get/set quota enforcement timeouts
warn [-bir] [-gpu] value -d|id|name -- get/set enforcement warning counter

Use 'help commandname' for extended help.
xfs_quota> print
Filesystem          Pathname
/volumes/stor1_nas  /dev/mapper/stor1_nas (uquota)
/volumes/stor2_nas  /dev/mapper/stor2_nas (uquota)
/Access.Share/forjasonk /dev/mapper/stor1_nas (uquota)
/Access.Share/ftp   /dev/mapper/stor2_nas (uquota)
/volumes/stor2_0    /dev/mapper/stor2_0
/kpkar              /dev/mapper/stor2_quota
/kpkar/log          /dev/mapper/stor2_quota (project 42, logfile)
xfs_quota> project -s logfile
Setting up project logfile (path /kpkar/log)...
Processed 1 /etc/projects paths for project logfile
xfs_quota> project -c logfile
Checking project logfile (path /kpkar/log)...
/kpkar/log/xfs - project identifier is not set (inode=0, tree=42)
/kpkar/log/xfs - project inheritance flag is not set
/kpkar/log - project identifier is not set (inode=0, tree=42)
/kpkar/log - project inheritance flag is not set
Processed 1 /etc/projects paths for project logfile
xfs_quota> limit -p bhard=1g logfile
xfs_quota: cannot set limits: Invalid argument

-----Original Message-----
From: Nathan Scott [mailto:nathans@xxxxxxx] 
Sent: Thursday, October 20, 2005 4:16 PM
To: Prabhakar Krishnan
Cc: 'linux-xfs@xxxxxxxxxxx'; 'ag@xxxxxxxxxxx'
Subject: Re: XFS- Quotas: setting up project quotas


On Tue, Oct 18, 2005 at 11:42:23PM -0400, Prabhakar Krishnan wrote:
> XFS- Quotas:
> ...
> -using mkfs.xfs created filesystem , with pquota flag enabled.

[p]quota are not mkfs options, they're mount options.

> - using xfs_quota , trying to setup and the 'cmd' quota inside the 
> shell doesnt work as advertised in the man page.
> ...
>  > man xfs_quota
> EXAMPLE :

Looks like I missed -x on the command line for some examples.

So, OOC, do all these ACL/quota questions indicate AMI is developing a NAS
product using XFS?

cheers.

-- 
Nathan


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