1、查看linux系统内核版本命令
[root@localhost ~]# uname -r3.8.13-35.3.1.el7uek.x86_64[root@localhost ~]# uname -aLinux localhost.localdomain 3.8.13-35.3.1.el7uek.x86_64 #2 SMP Wed Jun 25 15:27:43 PDT 2014 x86_64 x86_64 x86_64 GNU/Linux2、查看linux系统发行版本
[root@localhost ~]# cat /etc/redhat-release Red Hat Enterprise Linux Server release 7.0 (Maipo)[root@localhost ]# cat /etc/issueRed Hat Enterprise Linux Server release 5.8 (Tikanga)Kernel \r on an \m3、查看linux系统具体版本号
[root@localhost ~]# cat /proc/versionLinux version 3.8.13-35.3.1.el7uek.x86_64 (mockbuild@ca-build56.us.oracle.com) (gcc version 4.8.2 20140120 (Red Hat 4.8.2-16) (GCC) ) #2 SMP Wed Jun 25 15:27:43 PDT 20144、查看Linux硬盘大小
[root@localhost ~]# df -lh文件系统 容量 已用 可用 已用% 挂载点/dev/mapper/ol-root 22G 7.2G 15G 33% /devtmpfs 857M 0 857M 0% /devtmpfs 866M 84K 866M 1% /dev/shmtmpfs 866M 9.0M 858M 2% /runtmpfs 866M 0 866M 0% /sys/fs/cgroup/dev/sda1 497M 143M 354M 29% /boot/dev/sr0 3.9G 3.9G 0 100% /run/media/root/OL-7.0 Server.x86_645、查看内存大小
[root@localhost ~]# free -g total used free shared buffers cachedMem: 15 8 7 0 0 5-/+ buffers/cache: 2 13Swap: 17 0 17You have new mail in /var/spool/mail/root[root@localhost ~]# free -m total used free shared buffers cachedMem: 16049 8512 7537 0 198 5911-/+ buffers/cache: 2401 13648Swap: 18047 0 18047查看内存占用百分比:
[root@rusky ~]# free -m | sed -n '2p' | awk '{print "used mem is "$3"M,total mem is "$2"M,used percent is "$3/$2*100"%"}' used mem is 15765M,total mem is 15949M,used percent is 98.8463%6、查看CPU个数
[root@localhost ]# ls /proc/acpi/processor/CPU0 CPU1 CPU2 CPU3 CPU4 CPU5 CPU6 CPU77、查看CPU详细信息
[root@YNCMldap195 /]# cat /proc/cpuinfoprocessor : 0vendor_id : AuthenticAMDcpu family : 21model : 2model name : AMD Opteron(tm) Processor 6348 stepping : 0cpu MHz : 2800.033cache size : 2048 KBfpu : yesfpu_exception : yescpuid level : 13wp : yesflags : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 syscall nx mmxext fxsr_opt rdtscp lm rep_good constant_tsc nonstop_tsc pni ssse3 cx16 sse4_1 sse4_2 popcnt lahf_lm extapic abm sse4a misalignsse 3dnowprefetch osvw xop fma4bogomips : 5600.06TLB size : 1536 4K pagesclflush size : 64cache_alignment : 64address sizes : 40 bits physical, 48 bits virtualpower management: [8]processor : 1
vendor_id : AuthenticAMDcpu family : 21model : 2model name : AMD Opteron(tm) Processor 6348 stepping : 0cpu MHz : 2800.033cache size : 2048 KBfpu : yesfpu_exception : yescpuid level : 13wp : yesflags : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 syscall nx mmxext fxsr_opt rdtscp lm rep_good constant_tsc nonstop_tsc pni ssse3 cx16 sse4_1 sse4_2 popcnt lahf_lm extapic abm sse4a misalignsse 3dnowprefetch osvw xop fma4bogomips : 5600.06TLB size : 1536 4K pagesclflush size : 64cache_alignment : 64address sizes : 40 bits physical, 48 bits virtualpower management: [8]……
processor : 7