Skip to content
forked from axic/ruby-quota

Ruby-quota is a Ruby extension providing access to filesystem quota under Linux, FreeBSD, NetBSD, Dragonfly BSD, Solaris and Mac OS X.

License

Notifications You must be signed in to change notification settings

stcatz/ruby-quota

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Ruby/Quota

-------------------------------------------------------------------------------
This module provides functions which manipulate disk quotas.
-------------------------------------------------------------------------------

SUPPORTED ENVIRONMENT

  * Linux 2.4.x, 2.6.x
  * Solaris 2.6, 7, 8
  * FreeBSD
  * NetBSD
  * Dragonfly BSD
  * Mac OS X

UNTESTED

  * OpenBSD

-------------------------------------------------------------------------------

SYNOPSIS


Quota::GroupID.new(id)
Quota::GroupID[id]
Quota::UserID.new(id)
Quota::UserID[id]

Quota.quotaon(dev, quotas)
Quota.quotaoff(dev)
Quota.getquota(dev, uid)
Quota.setquota(dev, uid, dq)
Quota.setqlim(dev, uid, dq) # *BSD does not have this function.
Quota.sync(dev)

  * 'dev' is a device file or a mount point (e.g. /dev/hda0, /mnt/foo). On *
    BSD, this library will try to find a mounted directory from a given filesystem
    using getmntinfo().

  * 'quotas' is a quotas file.

  * 'uid' can be a integer, in this case it is treated as a user id. If it is
    a UserID or a GroupID object, it will be treated as desired.

  * 'dq' is an entry of the quotas. its members are same as 'dqblk' structure
    (e.g. dqb_curblocks => dq.curblocks). see also the quotactl man pages and
    header files (e.g. linux/quota.h).

About

Ruby-quota is a Ruby extension providing access to filesystem quota under Linux, FreeBSD, NetBSD, Dragonfly BSD, Solaris and Mac OS X.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • C 82.4%
  • Ruby 17.6%