#3 quota(1) extension suggestion

open
nobody
None
5
2003-04-05
2003-04-05
No

Extension to the quota(1) utility:
I'd love to see an extension which forces quota(1) to
output a user-defined message (to stdout) when the
specified user exceeded his/her quota in one or more
filesystem(s). Moreover, the return value of quota(1)
should depend on whether or not the quotas on one or
more filesystem(s) are exceeded. As a special goodie,
the user-specified message could contain variables that
would be replaced with things as the user's login name,
disk usage, quota, etc.

Rationale:
The proposed extension is intended to make quota(1)
more usable for scripting (exit value) and to provide more
user-friendly output (not all users feel comfortable with
things like /dev/hda3, blocks and inodes), especially
when they interact with the system via a Samba service
and thus never really see the Linux behind the scenes.

Example usage (simplified): quota <user>
exit 0: no quota set of not exceeded
exit 1: soft limit hit, in grace period
exit 2: soft limit hit, grace over
exit 3: hard limit hit.
For 1,2,3: user-defined message to stdout, else: be
quiet.

Discussion

  • Logged In: NO

    Actually, i would like to extend your request a little...
    Besides sending a message to stdout, it could automatically
    create a file (touch) on the user's home directory with a
    specified message letting him know that he's over quota...
    that would help a lot the combination of quota/ftp...
    and after the quota is back under it's limit the file would
    be deleted..

     
  • Mayel
    Mayel
    2004-12-26

    Logged In: YES
    user_id=1184757

    Actually, i would like to extend your request a little...
    Besides sending a message to stdout, it could automatically
    create a file (touch) on the user's home directory with a
    specified message letting him know that he's over quota...
    that would help a lot the combination of quota/ftp...
    and after the quota is back under it's limit the file would
    be deleted..

     
  • Logged In: NO

    I fully agree with this extension suggestion as this is one
    of the reason why I am still not using quotas on the linux
    servers I am monitoring. They are all running samba
    versions and using roaming profiles, adding the use of
    groups working directories. Being able to personnalize
    quota outputs messages would help a lot !

     


Anonymous


Cancel   Add attachments