du (disk usage) The Unix
command
du -s
directory shows how much disk space is used
by a directory and everything below it. While we
work on creating the complicated command
needed to automatically check all the
directories you are associated with, you can
find out how much space is in use by the WWW
files for a domain with
du -s
/www/htdocs/domain If you don't have anything
much in your home directory or mail spool, this
comes close to the total space you have in
use. (You would know if you did have other
things in your home directory, and could use
du -s $HOME to check on that.)
If you have an
anonymous FTP area, also check
du -s
~ftp/my.domain For example, snoopy.com might
need to run some number of the following:
du -s
/www/htdocs/snoopy du -s
~ftp/snoopy.com du -s $HOME and add the
results to find out how much space he's using.
You might find it
useful to use the -c command and group the paths
Example: brown:~$ du -sc /www/htdocs/pir
~ftp/pir.com $HOME
5489
/www/htdocs/pir 4 /www/ftp/pir.com 13
/home/rmiller 5510 total Actual results.
brown:~$ du -sc
/www/htdocs/pir ~ftp/pir.com $HOME 5489
/www/htdocs/pir du: /www/ftp/pir.com/bin:
Permission denied du: /www/ftp/pir.com/dev:
Permission denied du: /www/ftp/pir.com/etc:
Permission denied du: /www/ftp/pir.com/lib:
Permission denied 4 /www/ftp/pir.com 13
/home/rmiller 5510 total
The numbers
reported are kilobytes. A senior or RealAudio
account gets to use about 51,000 blocks
before having additional charges. A junior or
telnet- only account gets about 5,100.
|