Ubuntu 24.04 find hardware info: Difference between revisions
Created page with " == RAM and Swap Info == To display memory (RAM) and swap usage in a human-readable format with totals in megabytes: <code>free -m -h</code> * '''-m''': Shows output in megabytes. * '''-h''': Makes the output human-readable (e.g., GB, MB). Example output might look like: <pre> total used free shared buff/cache available Mem: 7.8Gi 2.1Gi 3.5Gi 0.2Gi 2.2Gi 5.4Gi Swap: 2.0Gi 0.0Gi..." |
(No difference)
|
Latest revision as of 00:13, 7 March 2025
RAM and Swap Info
To display memory (RAM) and swap usage in a human-readable format with totals in megabytes:
free -m -h
- -m: Shows output in megabytes.
- -h: Makes the output human-readable (e.g., GB, MB).
Example output might look like:
total used free shared buff/cache available Mem: 7.8Gi 2.1Gi 3.5Gi 0.2Gi 2.2Gi 5.4Gi Swap: 2.0Gi 0.0Gi 2.0Gi
Hard Drive Space Info
To check disk space usage for mounted filesystems:
df -h
- -h: Displays sizes in human-readable format (e.g., GB, MB).
Example output:
Filesystem Size Used Avail Use% Mounted on /dev/sda1 100G 25G 75G 25% /
CPU Info
To display detailed information about the CPU:
lscpu
This shows architecture, number of cores, clock speed, etc. Example output snippet:
Architecture: x86_64 CPU(s): 4 Model name: Intel(R) Core(TM) i5-8250U CPU @ 1.60GHz CPU MHz: 2400.000
For a more concise CPU summary, use:
cat /proc/cpuinfo
Look for lines like "model name" and "cpu cores" in the output.
Motherboard Info
To get motherboard details (vendor, product name, version), use:
sudo dmidecode -t baseboard
- Requires sudo privileges.
- Example output:
Base Board Information Manufacturer: Dell Inc. Product Name: 0F6X5P Version: A00
Alternatively, for a broader system overview (including motherboard):
sudo dmidecode -t system
Additional Useful Hardware Info
Here are more commands to round out your hardware info page:
List Block Devices (Disks and Partitions)
Shows all block devices like hard drives and SSDs:
lsblk
Example:
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT sda 8:0 0 120G 0 disk ├─sda1 8:1 0 100G 0 part / ├─sda2 8:2 0 1K 0 part └─sda5 8:5 0 20G 0 part [SWAP]
GPU/Graphics Card Info
To check graphics hardware:
lspci | grep -i vga
Example:
00:02.0 VGA compatible controller: Intel Corporation UHD Graphics 620 (rev 07)
For detailed driver info, use:
glxinfo | grep "OpenGL renderer"
- Requires `mesa-utils` package (`sudo apt install mesa-utils`).
Network Hardware
List network interfaces and hardware:
lshw -C network
- Requires `lshw` package (`sudo apt install lshw`).
- Use sudo for full details.
Full Hardware Summary
For a complete hardware overview in one go:
sudo lshw
- Outputs everything: CPU, memory, disks, network, etc.
- Pipe to `less` for easier reading: `sudo lshw | less`.
Notes
- Some commands (e.g., `dmidecode`, `lshw`) require root privileges via `sudo`.
- Install missing tools with `sudo apt install <package>` if a command isn’t found.
- Tested on Ubuntu 24.04 as of March 06, 2025.
SEO
SEO Keywords if searching for this page.
How do I check how much free RAM I have in Linux? How do I see swap space usage in Linux? How do I know what hard drive space I have left? How can I find CPU details in Linux? How do I get motherboard info on Linux? How do I list disks and partitions in Linux? How do I check my graphics card in Linux? How do I see network hardware in Linux? How do I get a full hardware summary in Linux? What command shows memory usage in megabytes? How do I view human-readable disk space in Linux? How do I install tools to check system info in Linux?