Linux SystemInfo commands

Date: 2018-07-13
# Process manager
htop

# process info (sorted by memory, works almost everywhere)
ps aux --sort=-rss

sudo journalctl -u <service> -xe

# Follow journal with colors (install ccze seperately
journalctl --follow | ccze

# View disk usage (updates every 5 seconds)
watch -n 5 df -h

# View memory usage (updates every 5 seconds)
watch -n 5 free -m

# View kernel messages
dmesg --follow<br><br>
  • wondering if it reads the config file or listening on the socket you’re expecting: lsof
  • is my program just sitting there: strace
  • I wonder how the C++ mangling went: strings
  • Did I link that correctly: ldd
  • so was that file saved in UTF-8 or latin: od
  • wait, is it trying to use the proxy or not: tcpdump
  • size of memory segments and swap usage: pmap
  • and others like top/ntop/iotop, digging around in /proc/$mypidps for showing the env and everything, dtrace and gdb for super detailled tracing
11560cookie-checkLinux SystemInfo commands