Q_SETQUOTA(2const) Q_SETQUOTA(2const)

Q_SETQUOTA - set quota information for user or group

Standard C library (libc-lc)

#include <sys/quota.h>
int quotactl(QCMD(Q_SETQUOTA, type), const char *_Nullable special,
             int id, caddr_t addr);
#include <sys/quota.h>    /* Definition of Q_* constants */
#include <sys/syscall.h>  /* Definition of SYS_* constants */
#include <unistd.h>
int syscall(SYS_quotactl_fd, int fd, QCMD(Q_SETQUOTA, type),
             int id, struct dqblk *addr);

Set quota information for user or group id, using the information supplied in the dqblk(2type) structure pointed to by addr.

The .dqb_valid field of the dqblk(2type) structure indicates which entries in the structure have been set by the caller.

This operation requires privilege (CAP_SYS_ADMIN).

See quotactl(2).

See quotactl(2).

The specified limits are out of the range allowed by the quota format.

Linux.

Linux.

This operation supersedes the Q_SETQLIM and Q_SETUSE operations in the previous quota interfaces.

quotactl(2), quotactl_fd(2), dqblk(2type)

2026-06-05 Linux man-pages 6.19