System Administration

⏱ 1 min remaining

Linux Monitoring and Troubleshooting

In this chapter we will discover the various techniques and utilities we can use to monitor a Linux machine.

Resource Monitoring and troubleshooting

  • vmstat: information about system processes, memory, paging, block I/O, and CPU activity
  • free: information about system memory and swap usage.
  • df: information about partition and volumes.
  • du: information about disk usage
  • iostat: input/output statistics for block devices.

Process Monitoring

  • ps: show information about processes
  • pgrep: grep through process list
  • pkill: send a signal to a specific process

Log Monitoring

  • /var/log/: where all system logs are stored
  • journalctl: Journald client
  • syslog: linux logging protocol
  • audit logs: auditing and monitoring security-relevant events.

Networking

  • iproute2: Linux userpace network utilities
  • ping: ICMP utility
  • traceroute, mtr: Network path monitoring. Learn More
  • curl: HTTP swiss knife
  • dig, nslookup: DNS lookup utilities
  • tcpdump, wireshark: Packet analyzers
  • nmap: Network scanning
  • netcat: Networking swiss knife
  • tcpstat: Network interface statistics