首页 > 学技术 > 技术网文 > IRIX > 正文

[精华] sgi quotas limit disk !!!


来源 chinaunix.net 酷勤网整理

                   Quota  Applications
                      
                          Author:sgiman@sohu.com 

1. How to use Quotas Subsystem For every user disk space ?

Notes:quota just use in localdisk,except sysdisk and remote disk can't use.

a.setup  quotas subsystem of IRIX6.x
  
b.# chkconfig  quotacheck   on
 
  # chkconfig  quotas       on
  
  /etc/init.d

  # quotas  stop
  # quotas  start 
 
c. at /etc/mtab and fstab
 
add "/dev/dsk/dks1d6s7   /disk1 xfs rw,quota 0 0"


d.Add a user e.g  jaleo use disk space just 25m 
  at /disk1/jaleo(/dev/dsk/dks1d6s7)


e.at /disk1/quotas (under every filesystem root must be creat a quotas file )
   
   # touch  /disk1/quotas  

 add " fs /disk1 kbytes (soft = 25000, hard = 25000) inodes (soft = 25000, hard = 25000)"


f. Limit User 
  #edquota   jaleo 

  add "fs /disk1 kbytes (soft = 25000, hard = 25000) inodes (soft = 25000, hard = 25000)"

2.Notes: How to copy jaleo user limit to share jack  user limit ?
   
   #edquota -p  jaleo  share  jack  
 
g.start quota 

  # quotaon -v -a 
  # reboot

h.How to test quota succeed ?
 
  # quota -v jaleo 
  Disk quotas for jaleo (uid 64684):
  Filesystem    usage   quota   limit    timeleft  files   quota   limit    timeleft
  /disk1           96   25000   25000                 49   25000   25000            

  #repquota -v -a 
  /dev/dsk/dks1d6s7 (/disk1):
  ---------------------------
                         Disk limits                       File limits
  User           used    soft    hard    timeleft   used    soft    hard    timeleft
  root      --4099488       0       0                 75       0       0             
  jaleo     --     96   25000   25000                 49   25000   25000             
  
i.If user disk space over mix 25m will be list Quota Message:" Disk quota exceeded  "






原文链接:http://bbs.chinaunix.net/viewthread.php?tid=17008
转载请注明作者名及原文出处



收藏本页到: