Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
This is a list of random shell commands that solved problems for me.

Show processes and sub-processes in a tree:


Restart networking stuff in Ubuntu:

sudo /etc/init.d/networking restart

Undo an add in mercurial:

hg status -an0 | xargs -0 hg revert

Check linux kernel version and processor type:

uname -a

Show how much disk space remains and show how big the files/directories in the current directory are.

df -h
du -sh *

Ports in use:

sudo netstat -taupen
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment