View hardware information in centos
I. View CPU using common centos commands
More/proc/cpuinfo | grep "model name"
Grep "Model
Name "/proc/cpuinfo
[Root @ localhost ~] # Grep "CPU"/proc/cpuinfo
Model name: Intel (r)
Xeon (r) CPU e5506 @ 2.13 GHz
Model name: Intel (r) Xeon (r)
CPU e5506 @ 2.13 GHz
Model name: Intel (r) Xeon (r)
CPU e5506 @ 2.13 GHz
Model name: Intel (r) Xeon (r)
CPU e5506 @ 2.13 GHz
Model name: Intel (r) Xeon (r)
CPU e5506 @ 2.13 GHz
Model name: Intel (r) Xeon (r)
CPU e5506 @ 2.13 GHz
Model name: Intel (r) Xeon (r)
CPU e5506 @ 2.13 GHz
Model name: Intel (r) Xeon (r)
CPU e5506 @ 2.13 GHz
If you feel more comfortable to watch
Grep "model name"
/Proc/cpuinfo | cut-F2-D:
Ii. Use common centos commands to view memory,
Grep memtotal
/Proc/meminfo
Grep memtotal/proc/meminfo | cut-F2-D:
Free-M | grep
"Mem"
Iii. Use common centos commands to check whether the CPU is 32-bit or 64-bit
Getconf
Long_bit
5. view the kernel version using common centos commands
Uname-R
Uname-
6. Use common centos commands to view the current time
Date
Set system time
Date-s "20110317 18:30:50" & hwclock
-- Systohc
Synchronize system time
Ntpdate 210.72.145.44
0 23 ***
/Usr/sbin/ntpdate 210.72.145.44>/dev/null
2> & 1
7. View hard disks and partitions using common centos commands
View partition fdisk-l
View all occupied space Du-SH
The directory size is du/etc.
-Sh
8. Use common centos commands to view installed software packages
View the software packages installed during system installation
Cat-n
/Root/install. Log
More/root/install. log | WC-l
Check the software packages that have been installed.
Rpm-Qa
Rpm-Qa | WC-l
Yum list
Installed | WC-l
9. view the keyboard layout using common centos commands
Cat
/Etc/sysconfig/keyboard
CAT/etc/sysconfig/keyboard | grep keytable | cut
-F2-d
10. Use common centos commands to view SELinux Information
Sestatus | cut-F2-D:
Cat
/Etc/sysconfig/SELinux
11: Use common centos commands to view IP addresses and MAC addresses
Ifconfig
CAT/etc/sysconfig/network-scripts/ifcfg-eth0 | grep ipaddr
Cat
/Etc/sysconfig/network-scripts/ifcfg-eth0 | grep ipaddr | cut-F2
Ifconfig eth0 | grep "Inet ADDR :"
View gateway cat
/Etc/sysconfig/Network
View DNS cat
/Etc/resolv. conf
12: Use common centos commands to view the default language
Echo $ Lang
$ Language
12: Use common centos commands to check the time zone and whether UTC time is used
Cat
/Etc/sysconfig/clock
Thirteen: Use common centos commands to view the Host Name
Cat
/Etc/sysconfig/Network
14. Run common centos commands to view the startup time
Uptime
View motherboard Information
Dmidecode | more