How can I get processor/RAM/disk specs from the Linux command Line? [duplicate]

Possible Duplicate:
How to find out details about hardware on the Linux machine?

How can I get processor/RAM/disk specs from the Linux command Line?


Solution 1:

CPU

$ cat /proc/cpuinfo

Memory :

$ free
$ cat /proc/meminfo

HDD:

$ df -h
$ sudo fdisk -l
$ hdparm -i /dev/device (for example sda1, hda3...)

Solution 2:

lshw command is also really useful to get a lot of information about all the hardware !

Solution 3:

sudo dmidecode command will also give you more hardware info than you ever wanted.

Solution 4:

hwinfo would be one way to do it.