My linux world » Diagnostic Survival Guide

Diagnostic Survival Guide


Contents

Hardware

dstat

Installation

echo "install dstat"
yum -y install dstat
 
echo "Now let list all the aivalable plugins"
dstat --list

Example of use

echo "get cpu usage"
dstat -t --cpu --cpu24
 
echo "get disk read/write usage"
dstat -t --disk
 
echo "get top process memory usage"
dstat --top-io --top-mem

iotop

Disk I/O monitoting.

Installation

echo "install iotop"
yum -y install iotop

Example of use

echo "launch iotop"
iotop --only

lshw

Tools that list all hardware

Installation

echo "install lshw"
yum -y install lshw

Example of use

echo "list everything"
lshw
 
echo "only list network informations"
lshw -class network

top

echo "use this easy command :"
top

Network

iftop

It display bandwidth usage on an interface by host.

Installation

echo "install iftop"
yum -y install iftop

Example of use

iftop

wireshark

Dump and analyze network traffic.

Installation

echo "install wireshark"
yum -y install wireshark

Example of use

echo "capture network interface ens33 for 12 hours"
timeout 12h 'tshark -i ens33 -w /tmp/packets.pcap'

nmap

Verifying Which Ports Are Listening

Installation

echo "install nmap"
yum -y install nmap

Example of use

echo "determines which ports are listening for TCP connections from localhost"
nmap -sT -O localhost

Memory

top

Example of use

echo "display top"
top

free

Display free/used memory

Example of use

echo "display human readable"
free -h

Copyright © 2023 My linux world - by Marc RABAHI
Design by Marc RABAHI and encelades.

Fork me on GitHub