1、查看当前系统版本信息
linux09@5-3:~$ cat /etc/os-release
NAME="Ubuntu"
VERSION="18.04.3 LTS (Bionic Beaver)"
ID=ubuntu
ID_LIKE=debian
PRETTY_NAME="Ubuntu 18.04.3 LTS"
VERSION_ID="18.04"
HOME_URL="https://www.ubuntu.com/"
SUPPORT_URL="https://help.ubuntu.com/"
BUG_REPORT_URL="https://bugs.launchpad.net/ubuntu/"
PRIVACY_POLICY_URL="https://www.ubuntu.com/legal/terms-and-policies/privacy-policy"
VERSION_CODENAME=bionic
UBUNTU_CODENAME=bionic
linux09@5-3:~$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 18.04.3 LTS
Release: 18.04
Codename: bionic
linux09@5-3:~$ uname -r
4.15.0-213-generic
2、查看当前系统CPU信息
linux09@5-3:~$ lscpu
Architecture: x86_64
CPU op-mode(s): 32-bit, 64-bit
Byte Order: Little Endian
CPU(s): 64
On-line CPU(s) list: 0-63
Thread(s) per core: 1
Core(s) per socket: 1
Socket(s): 64
NUMA node(s): 1
Vendor ID: GenuineIntel
CPU family: 6
Model: 85
Model name: Intel Xeon Processor (Skylake)
Stepping: 4
CPU MHz: 2194.842
BogoMIPS: 4389.68
Hypervisor vendor: KVM
Virtualization type: full
L1d cache: 32K
L1i cache: 32K
L2 cache: 4096K
L3 cache: 16384K
NUMA node0 CPU(s): 0-63
Flags: fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 ss syscall nx pdpe1gb rdtscp lm constant_tsc rep_good nopl xtopology cpuid tsc_known_freq pni pclmulqdq ssse3 fma cx16 pcid sse4_1 sse4_2 x2apic movbe popcnt tsc_deadline_timer aes xsave avx f16c rdrand hypervisor lahf_lm abm 3dnowprefetch invpcid_single pti fsgsbase tsc_adjust bmi1 hle avx2 smep bmi2 erms invpcid rtm mpx avx512f avx512dq rdseed adx smap clflushopt clwb avx512cd avx512bw avx512vl xsaveopt xsavec xgetbv1 arat
3、查看当前系统内存配置
linux09@5-3:~$ free -h
total used free shared buff/cache available
Mem: 125G 4.0G 4.9G 38M 117G 120G
Swap: 0B 0B 0B
linux09@5-3:~$ vmstat -s
132017808 K total memory
4208080 K used memory
65661736 K active memory
38230376 K inactive memory
5083568 K free memory
34947308 K buffer memory
87778848 K swap cache
0 K total swap
0 K used swap
0 K free swap
2099335016 non-nice user cpu ticks
1604351128 nice user cpu ticks
623437028 system cpu ticks
103531225637 idle cpu ticks
411622039 IO-wait cpu ticks
0 IRQ cpu ticks
7344374 softirq cpu ticks
282848037 stolen cpu ticks
67183214484 pages paged in
112610265068 pages paged out
0 pages swapped in
0 pages swapped out
3994572844 interrupts
1703174947 CPU context switches
1755738523 boot time
859173872 forks
4、查看当前系统网卡信息
linux09@5-3:~$ ip addr
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
inet 127.0.0.1/8 scope host lo
valid_lft forever preferred_lft forever
inet6 ::1/128 scope host
valid_lft forever preferred_lft forever
2: ens3: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP group default qlen 1000
link/ether fa:16:3e:66:7e:1a brd ff:ff:ff:ff:ff:ff
inet 192.168.238.78/24 brd 192.168.238.255 scope global ens3
valid_lft forever preferred_lft forever
inet6 fe80::f816:3eff:fe66:7e1a/64 scope link
valid_lft forever preferred_lft forever
linux09@5-3:~$ ip route
default via 192.168.238.254 dev ens3
169.254.169.254 via 192.168.238.2 dev ens3
192.168.238.0/24 dev ens3 proto kernel scope link src 192.168.238.78