Penguin

Differences between current version and revision by previous author of quotactl(2).

Other diffs: Previous Major Revision, Previous Revision, or view the Annotated Edit History

Newer page: version 2 Last edited on Sunday, March 16, 2003 8:22:26 pm by PerryLorier
Older page: version 1 Last edited on Tuesday, June 4, 2002 12:23:44 am by perry Revert
@@ -1,212 +1,56 @@
-QUOTACTL  
-!!!QUOTACTL  
-NAME  
-SYNOPSIS  
-DESCRIPTION  
-RETURN VALUE  
-ERRORS  
-CONFORMING TO  
-SEE ALSO  
-----  
 !!NAME 
+quotactl - manipulate disk quotas  
  
-  
-quotactl - manipulate disk quotas  
 !!SYNOPSIS 
+ __#include <sys/types.h>__  
+ __#include <sys/quota.h>__  
  
+ __int quotactl (int__ ''cmd''__, const char *__''special''__, int__ ''id'' __, caddr_t__ ''addr''__);__  
  
-__#include __  
-#include __ 
+ __#include <linux/unistd.h> __ 
  
+ ___syscall4(int, quotactl, int,__ ''cmd''__, const char *,__ ''special'' __, int,__ ''id''__, caddr_t,__ ''addr''__);__  
  
-__int quotactl (int__ ''cmd''__, const char  
-*__''special''__, int__ ''id'' __, caddr_t__  
-''addr''__);__  
-  
-  
-__#include __  
-  
-  
-___syscall4(int, quotactl, int,__ ''cmd''__, const  
-char *,__ ''special'' __, int,__ ''id''__,  
-caddr_t,__ ''addr''__);__  
 !!DESCRIPTION 
+The quota system defines for each user and/or group a soft limit and a hard limit bounding the amount of disk space that can be used on a given file system. The hard limit cannot be crossed. The soft limit can be crossed, but warnings will ensue. Moreover, the user cannot be above the soft limit for more than one week (by default) at a time: after this week the soft limit counts as hard limit.  
  
+The __quotactl__ system call manipulates these quota. Its first argument is of the form ''QCMD(''__subcmd__'',''__type__'')'' where ''type'' is either __USRQUOTA__ or __GRPQUOTA__ (for user quota and group quota, respectively), and ''subcmd'' is described below.  
  
-The quota system defines for each user and/or group a soft  
-limit and a hard limit bounding the amount of disk space  
-that can be used on a given file system . The hard limit  
-cannot be crossed. The soft limit can be crossed, but  
-warnings will ensue. Moreover, the user cannot be above the  
-soft limit for more than one week (by default) at a time:  
-after this week the soft limit counts as hard  
-limit
+The second argument ''special'' is the block special device these quota apply to . It must be mounted
  
+The third argument ''id'' is the user or group id these quota apply to (when relevant).  
  
-The __quotactl__ system call manipulates these quota. Its  
-first argument is of the form  
-''QCMD(''__subcmd__'',''__type__'')'' where  
-''type'' is either __USRQUOTA__ or __GRPQUOTA__  
-(for user quota and group quota, respectively), and  
-''subcmd'' is described below.  
-  
-  
-The second argument ''special'' is the block special  
-device these quota apply to. It must be  
-mounted.  
-  
-  
-The third argument ''id'' is the user or group id these  
-quota apply to (when relevant).  
-  
-  
- The fourth argument ''addr'' is the address of a data  
- structure, depending on the command.  
-  
+The fourth argument ''addr'' is the address of a data structure, depending on the command. 
  
 The ''subcmd'' is one of 
  
+;__Q_QUOTAON__: Enable quotas. The ''addr'' argument is the pathname of the file containing the quotas for the filesystem.  
+;__Q_QUOTAOFF__: Disable quotas.  
+;__Q_GETQUOTA__: Get limits and current usage of disk space. The ''addr'' argument is a pointer to a dqblk structure (defined in '''').  
+;__Q_SETQUOTA__: Set limits and current usage; ''addr'' is as before.  
+;__Q_SETQLIM__: Set limits; ''addr'' is as before.  
+;__Q_SETUSE__: Set usage.  
+;__Q_SYNC__: Sync disk copy of a filesystems quotas.  
+;__Q_GETSTATS__: Get collected stats.  
  
-__Q_QUOTAON__  
-  
-  
-Enable quotas. The ''addr'' argument is the pathname of  
-the file containing the quotas for the  
-filesystem.  
-  
-  
-__Q_QUOTAOFF__  
-  
-  
-Disable quotas.  
-  
-  
-__Q_GETQUOTA__  
-  
-  
-Get limits and current usage of disk space. The ''addr''  
-argument is a pointer to a dqblk structure (defined in  
-'''').  
-  
-  
-__Q_SETQUOTA__  
-  
-  
-Set limits and current usage; ''addr'' is as  
-before.  
-  
-  
-__Q_SETQLIM__  
-  
-  
-Set limits; ''addr'' is as before.  
-  
-  
-__Q_SETUSE__  
-  
-  
-Set usage.  
-  
-  
-__Q_SYNC__  
-  
-  
-Sync disk copy of a filesystems quotas.  
-  
-  
-__Q_GETSTATS__  
-  
-  
-Get collected stats.  
 !!RETURN VALUE 
+On success, __quotactl__ returns 0. On error, -1 is returned, and ''errno'' is set appropriately.  
  
-  
-On success, __quotactl__ returns 0. On error, -1 is  
-returned, and ''errno'' is set  
-appropriately.  
 !!ERRORS 
+;[ENOPKG]: The kernel was compiled without quota support.  
+;[EFAULT]: Bad ''addr'' value.  
+;[EINVAL]: ''type'' is not a known quota type. Or, ''special'' could not be found.  
+;[ENOTBLK]: ''special'' is not a block special device.  
+;[ENODEV]: ''special'' cannot be found in the mount table.  
+;[EACCES]: The quota file is not an ordinary file.  
+;[EIO]: Cannot read or write the quota file.  
+;[EMFILE]: Too many open files: cannot open quota file.  
+;[EBUSY]: __Q_QUOTAON__ was asked, but quota were enabled already.  
+;[ESRCH]: __Q_GETQUOTA__ or __Q_SETQUOTA__ or __Q_SETUSE__ or __Q_SETQLIM__ was asked for a file system that didn't have quota enabled.  
+;[EPERM]: The process was not root (for the file system), and __Q_GETQUOTA__ was asked for another ''id'' than thatof the process itself, or anything other than __Q_GETSTATS__ or __Q_SYNC__ was asked.  
  
-  
-__ENOPKG__  
-  
-  
-The kernel was compiled without quota support.  
-  
-  
-__EFAULT__  
-  
-  
-Bad ''addr'' value.  
-  
-  
-__EINVAL__  
-  
-  
-''type'' is not a known quota type. Or, ''special''  
-could not be found.  
-  
-  
-__ENOTBLK__  
-  
-  
-''special'' is not a block special device.  
-  
-  
-__ENODEV__  
-  
-  
-''special'' cannot be found in the mount  
-table.  
-  
-  
-__EACCES__  
-  
-  
-The quota file is not an ordinary file.  
-  
-  
-__EIO__  
-  
-  
-Cannot read or write the quota file.  
-  
-  
-__EMFILE__  
-  
-  
-Too many open files: cannot open quota file.  
-  
-  
-__EBUSY__  
-  
-  
-__Q_QUOTAON__ was asked, but quota were enabled  
-already.  
-  
-  
-__ESRCH__  
-  
-  
-__Q_GETQUOTA__ or __Q_SETQUOTA__ or __Q_SETUSE__ or  
-__Q_SETQLIM__ was asked for a file system that didn't  
-have quota enabled.  
-  
-  
-__EPERM__  
-  
-  
-The process was not root (for the file system), and  
-__Q_GETQUOTA__ was asked for another ''id'' than that  
-of the process itself, or anything other than  
-__Q_GETSTATS__ or __Q_SYNC__ was asked.  
 !!CONFORMING TO 
+BSD  
  
-  
-BSD  
 !!SEE ALSO 
-  
-  
- quota(1), getrlimit(2), setrlimit(2),  
- ulimit(2), quotacheck(8),  
- quotaon(8)  
-----  
+quota(1), getrlimit(2), setrlimit(2), ulimit(2), quotacheck(8), quotaon(8) 
This page is a man page (or other imported legacy content). We are unable to automatically determine the license status of this page.