Solaris: Disk Usage of All Users on a Filesystem

The quot command provides a quick measure of the disk usage of multiple users on a filesystem.


The quote command must be run as or with the privileges of root. The following is sample output for the quot command:

quot /usr
/dev/rdsk/c0t0d0s3:
851637 root
690088 bin
25828 daemon
16880 #5115
10025 #317
8568 mailsrv
6326 qmchenry
767 uucp
295 adm
202 nobody
46 lp

In this output, the raw device of the filesystem is shown first. The username is provided, if known. The numeric uids 5115 and 317 own files but are unassociated with a username in /etc/passwd as is common when files are untarred from another system.

The -a option can be used in place of the filesystem to check (/usr in that example) and will make quot iterate through all mounted filesystems. The -f option will add a middle column containing the number of files owned by each user.

The quot command could be very useful when a filesystem fills suddenly as it can quickly determine what user to flog or which application has to be checked.

 

About Quinn McHenry

Quinn was one of the original co-founders of Tech-Recipes. He is currently crafting iOS applications as a senior developer at Small Planet Digital in Brooklyn, New York.
View more articles by Quinn McHenry

The Conversation

Follow the reactions below and share your own thoughts.

  • Anonymous

    I have never used this command in all my 10 years and I am happy I have found it:

    my commonly used command is normally:

    # du -ks * | sort +0rn | more ; which takes ages!

    Thanks again!