$ dmidecode |grep -A16 "System Information$"
System Information
Manufacturer: RDO
Product Name: OpenStack Compute
Version: 17.0.10-1.el7
Serial Number: fc4b41c4-fba2-40b5-8bbe-470fa9a498a2
UUID: f270d386-d9e9-4eff-a144-598b036ad105
Wake-up Type: Power Switch
SKU Number: Not Specified
Family: Virtual Machine
Handle 0x0300, DMI type 3, 21 bytes
Chassis Information
Manufacturer: Red Hat
Type: Other
Lock: Not Present
Version: RHEL 7.6.0 PC (i440FX + PIIX, 1996)
Serial Number: Not Specified
獲取BIOS信息
$ dmidecode -t bios
# dmidecode 3.1
Getting SMBIOS data from sysfs.
SMBIOS 2.8 present.
Handle 0x0000, DMI type 0, 24 bytes
BIOS Information
Vendor: SeaBIOS
Version: 1.11.0-2.el7
Release Date: 04/01/2014
Address: 0xE8000
Runtime Size: 96 kB
ROM Size: 64 kB
Characteristics:
BIOS characteristics not supported
Targeted content distribution is supported
BIOS Revision: 0.0
$ free -h
total used free shared buff/cache available
Mem: 62G 22G 2.7G 1.9G 37G 37G
Swap: 19G 0B 19G
獲取硬盤信息
獲取磁盤分區狀態
$ fdisk -l |grep Disk
Disk /dev/vda: 32.2 GB, 32212254720 bytes, 62914560 sectors
Disk label type: dos
Disk identifier: 0x000ae09f
Disk /dev/vdb: 21.5 GB, 21474836480 bytes, 41943040 sectors
Disk /dev/vdc: 107.4 GB, 107374182400 bytes, 209715200 sectors
Disk label type: dos
Disk identifier: 0xa7343e4f
獲取磁盤和分區分佈
$ lsblk
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
vda 253:0 0 30G 0 disk
└─vda1 253:1 0 30G 0 part /
vdb 253:16 0 20G 0 disk [SWAP]
vdc 253:32 0 100G 0 disk
└─vdc1 253:33 0 100G 0 part /data
獲取磁盤詳細信息
$ fdisk -l
Disk /dev/vda: 32.2 GB, 32212254720 bytes, 62914560 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk label type: dos
Disk identifier: 0x000ae09f
Device Boot Start End Blocks Id System
/dev/vda1 * 2048 62914526 31456239+ 83 Linux
Disk /dev/vdb: 21.5 GB, 21474836480 bytes, 41943040 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk /dev/vdc: 107.4 GB, 107374182400 bytes, 209715200 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk label type: dos
Disk identifier: 0xa7343e4f
Device Boot Start End Blocks Id System
/dev/vdc1 2048 209715199 104856576 83 Linux
獲取磁盤掛載詳情
$ mount| column -t
獲取掛載使用詳情
$ swapon -s
Filename Type Size Used Priority
/dev/vdb partition 20971516 0 -2