Troubleshooting, upgrading, or just curious? Find out what’s in your system without opening the case. Using these Linux command line tools, you can get details about your hardware and distribution.
I’ve tested these commands in Ubuntu 7.10, but they should all work in other Linux distributions. Unless noted otherwise, all of this software is included by default with Ubuntu.
Graphics card:
1 |
glxinfo |
– details about OpenGL, the Xserver, and your graphics card
1 |
glxinfo | grep direct |
– do you have direct 3d rendering?
1 |
glxinfo | grep vendor |
– graphics card vendor
1 |
lspci | grep VGA |
– specific graphics card model
1 |
glxgears |
– a simple 3d benchmark, prints frame rate to the terminal
1 |
xrandr |
– supported display resolutions
Audio:
1 |
lspci | grep Audio |
– audio controller
1 |
aplay --list-devices |
– more audio device information
Software versions:
1 |
cat /etc/issue |
– current distribution and version
1 |
apt-cache showpkg packagename |
– packagename’s version and dependencies
1 |
uname -r |
– Linux kernel version
1 |
uname -a |
– all kernel details
Networking:
1 |
lspci | grep Ethernet |
– Ethernet controllers
1 |
ifconfig |
– networking interfaces, IP addresses, and more
Processor:
1 |
cat /proc/cpuinfo |
– all processors, clock speeds, flags, and more
1 |
cat /proc/loadavg |
– processor load average for the last 1, 5, and 15 minutes
1 |
top |
– press C key to sort processes by CPU usage
Memory:
1 |
cat /proc/meminfo |
– amount of RAM and swap, and how much is being used for what
1 |
free -m |
– total, used, and free memory shown in MB
1 |
top |
– press M key to sort processes by memory usage
Hard disks:
1 |
df -H |
– partitions, as well as their mount-points and usage in GB
1 |
sudo fdisk -l |
– all partitions, their device names, and positions on disk
USB devices:
1 |
lsusb |
– USB buses and attached devices
Even more:
1 |
lshal -m |
– monitor for hardware changes
1 |
lspci |
– all PCI devices
1 |
hwinfo --short |
(install from package hwinfo) – overview of all hardware, as well as more detailed info
1 |
lshw |
– another program for listing hardware
1 |
lshw -html | w3m -T text/html |
– lists hardware with HTML output in the w3m web browser
1 |
uptime |
– current time elapsed since last reboot, users, and load average
0 Comments.