Skip to content

1.3 Hardware Information

Tomato6966 edited this page Jun 29, 2021 · 1 revision

Display messages in kernel ring buffer

dmesg

Display CPU information

cat /proc/cpuinfo

Display memory information

cat /proc/meminfo

Display free and used memory ( -h for human readable, -m for MB, -g for GB.)

free -h

Display PCI devices

lspci -tv

Display USB devices

lsusb -tv

Display DMI/SMBIOS (hardware info) from the BIOS

dmidecode

Show info about disk sda

hdparm -i /dev/sda

Perform a read speed test on disk sda

hdparm -tT /dev/sda

Test for unreadable blocks on disk sda

badblocks -s /dev/sda

PERFORMANCE MONITORING AND STATISTICS

Display and manage the top processes

top

Interactive process viewer (top alternative)

htop

Display processor related statistics

mpstat 1

Display virtual memory statistics

vmstat 1

Display I/O statistics

iostat 1

Display the last 100 syslog messages (Use /var/log/syslog for Debian based systems.)

tail -100 /var/log/messages

Capture and display all packets on interface eth0

tcpdump -i eth0

Monitor all traffic on port 80 ( HTTP )

tcpdump -i eth0 'port 80'

List all open files on the system

lsof

List files opened by user

lsof -u user

Display free and used memory ( -h for human readable, -m for MB, -g for GB.)

free -h

Execute "df -h", showing periodic updates

watch df -h

Clone this wiki locally