Red Hat Training
A Red Hat training course is available for Red Hat Enterprise Linux
4.3.4. 顯示卷冊群組
您可使用兩項指令來顯示 LVM 卷冊群組的內容:
vgs
和 vgdisplay
。
The
vgscan
command, which scans all the disks for volume groups and rebuilds the LVM cache file, also displays the volume groups. For information on the vgscan
command, see 節 4.3.5, “掃描磁碟來找尋卷冊群組以便建立快取檔案”.
The
vgs
command provides volume group information in a configurable form, displaying one line per volume group. The vgs
command provides a great deal of format control, and is useful for scripting. For information on using the vgs
command to customize your output, see 節 4.9, “LVM 的自訂化回報”.
vgdisplay
指令會以固定的格式來顯示卷冊群組內容(例如大小、扇區、實體卷冊數量等等)。下列範例顯示了 vgdisplay
指令針對於 new_vg
卷冊群組的輸出。若您不指定卷冊群組的話,所有現有的卷冊群組就會被顯示出。
# vgdisplay new_vg
--- Volume group ---
VG Name new_vg
System ID
Format lvm2
Metadata Areas 3
Metadata Sequence No 11
VG Access read/write
VG Status resizable
MAX LV 0
Cur LV 1
Open LV 0
Max PV 0
Cur PV 3
Act PV 3
VG Size 51.42 GB
PE Size 4.00 MB
Total PE 13164
Alloc PE / Size 13 / 52.00 MB
Free PE / Size 13151 / 51.37 GB
VG UUID jxQJ0a-ZKk0-OpMO-0118-nlwO-wwqd-fD5D32