• We’re currently investigating an issue related to the forum theme and styling that is impacting page layout and visual formatting. The problem has been identified, and we are actively working on a resolution. There is no impact to user data or functionality, this is strictly a front-end display issue. We’ll post an update once the fix has been deployed. Thanks for your patience while we get this sorted.

finding disk usage totals in unix

aDub

Junior Member
Im stuck in a rut here. How do you find out how much space a given user is using in unix? I have a project for school and I have to write a shell script that gets usernames from a text file and gets the disk usage for that user. Thanks for any help.
 
"man du" as long as they keep their stuff in a specific directory. otherwise you're going to have to find all files they own, and I dont know any easy way to do that. of course, *nix probably has user quota support somewhere, i've just never seen it. 😉
 
Originally posted by: CTho9305
"man du" as long as they keep their stuff in a specific directory. otherwise you're going to have to find all files they own, and I dont know any easy way to do that. of course, *nix probably has user quota support somewhere, i've just never seen it. 😉

quota support exists. But it wont help this problem.

find / -user n0cmonkey -name example.html -print should find the file example.html owned by the user n0cmonkey.

And all of each users' files should be in specific directories... Their home directories.
 
Back
Top