System information
Jump to navigation
Jump to search
There are several ways to gather system information. It is a good idea to keep abreast of your machine's utilization and capacities.
General System Information Tools/Utilities
- cat /var/log/messages -- is the same as dmesg
- dmesg -- kernel messages given during booting.
- kinfocenter -- good overview
- tail -f /var/log/messages -- show the last couple of lines and keep outputting new lines
- uname -a -- brief OS and kernel information.
Memory Diagnostic Tools/Utilities
- cat /proc/meminfo -- static information about your RAM
- ksysguard -- real-time RAM and CPU utilization printout and process table
- top -- real-time RAM and CPU utilization printout
- free -- current memory/swap utilization.
CPU Diagnostic Tools/Utilities
Disk and File System Diagnostic Tools/Utilities
- cat /etc/fstab -- show configuration file for file system mounting.
- df -h -- current disk space usage ("-h" gives human-readable output)
- du -h -- determine how much disk space is being used by Cwd, or any directory you specify after the du command (as in df, the "-h" means human-readable)
- fdisk -l [/dev/hda] -- show partition table(s), leave off device name to list all
- mount or cat /etc/mtab -- show currently mounted file systems.
Local Devices Diagnostic Tools/Utilities
- dmidecode -- get all bios information, e.g. computer type.
- hwinfo --pci -- list devices on the pci bus.
- hwinfo --scsi -- list all scsi devices.
- hwinfo --usb -- list all usb devices.
- lsdev -- list all installed hardware.
- lspci -- list devices on the pci bus.
- lsscsi -- list all scsi devices.
- lsusb -- list all usb devices.
- setserial -bg /dev/ttyS[0-9]* -- list all active serial devices(/dev/ttyS*).
Kernel and Kernel Module Diagnostic Tools/Utilities
- lsmod -- list kernel modules currently loaded.
Network Diagnostic Tools/Utilities
- Directory /proc/net/
- File arp: arp cache. Maps IP address to MAC address
- File dev: byte and packet statistics on a per device basis.
- File netstat: various statistics
- File tcp: established connections.
- Directory /proc/sys/net/ipv4/
- File: ip_forward: read/write. Whether or not the kernal will forward IP packets from one interface to another. This is turned on if you want the machine to work as a router or a firewall.
- ethtool $interface -- show the card's speed, capabilities and if a link is detected
- hwinfo --netcard -- show the module name, driver activation command, network card name etc.
- ifconfig -a -- show all current network interface information
- ifconfig $interface -- show the information for $interface (usually something like ifconfig eth0)
- ping $host -- use ping to determine if $host is alive on the network (for troubleshooting your local machine $host can equal "127.0.0.1" or "localhost"
- route -n -- show routing table, using numerical addresses.
If you want to set up a proxy firewall, this should be off, as it will be the application that forwards traffic, not the kernel.
- File: ip_local_port_range: read/write. The range of ports that are used as source ports for outgoing connections.
- File: tcp_sack: read/write. Whether or not TCP connections use selective acknowledgement. One=yes, zero=no.
- File: tcp_timestamps: read/write. Whether or not TCP connections add timestamps to their connections. One=yes, zero=no.
Dynamic information
Or: What does my hardware do?
- xosview -- CPU, network load etc. to get an overview
- ksysguard -- CPU, network load etc. comprehensively
- vmstat -- CPU load, swapping and I/O
- top -- top CPU consuming processes
- lm-sensors -- read CPU temperature etc.
- ethereal -- a network sniffer
- iptraf -- show network packets by size, interface etc.
- netstAt -- show established and listening network connections
- iostAt -- show count of read blocks in a given time etc.
- blktRace -- sniff scsi commands etc.