Page tree
Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 38 Next »

Detailed Articles

Disk Management

List directories from largest to smallest at the top level only. On older system h will not work and you must use k.

du -sh * | sort

Long Running Processes

To write.

Other Useful Commands

MD5

Check if a file is corrupt,

# On Ubuntu
md5sum /path/to/file

# On Solaris
digest -a md5 -v /path/to/file

Tar

To save a directory into a tar file and gunzip. Make sure to use sudo to keep the permissions intact.

# To tar the directory
sudo tar -zcvpf tarfile.tar.gz ./folder
 
# To untar and gunzip the file in one command
sudo tar -zxvpf tarfile.tar.gz
 
# Encrypting a tar
...

Last

Last searches back through the file /var/log/wtmp  (or the file designated by the -f flag) and displays a list of all users logged in (and out) since that file was created. 

  • No labels