2024年6月13日发(作者:戴采白)
1、查看VG属性
root@rzcs:/#vgdisplay-v/dev/vg02
---Volumegroups---
VGName/dev/vg02
VGWriteAccessread/write
VGStatusavailable
MaxLV2047
CurLV2
OpenLV2
CurSnapshotLV0
MaxPV2048
CurPV2
ActPV2
MaxPEperPV4800
VGDA4
PESize(Mbytes)64
Unshareunitsize(Kbytes)1024
TotalPE4800
AllocPE4799
Currentpre-allocatedPE0
FreePE1
TotalPVG0
TotalSparePVs0
TotalSparePVsinuse0
VGVersion2.2
VGMaxSize300g
VGMaxExtents4800
CurSnapshotCapacity0p
MaxSnapshotCapacity300g
可以看出,该VG最大只能300G,显然不能满足我们需求,此时即使使用
vgextend扩展也无用,因此需要修改VG的最大大小“VGMaxSize”
2、修改VG属性
命令和语法:
Usage:
Fordeactivatedversion1.0volumegroups,
vgmodify
[-v]
[-n]
[-r]
[-eMaxPhysicalExtents]
[-pMaxPhysicalVolumes]
[-lMaxLogicalVolumes]
VolumeGroupName
vgmodify-Bbootable
[-n]
[-r]
[-v]
[-eMaxPhysicalExtents]
[-pMaxPhysicalVolumes]
[-lMaxLogicalVolumes]
vgmodify-o
[-v]
[-r]
VolumeGroupName
vgmodify-o-Bbootable
[-v]
[-r]
vgmodify-CDLC_Size
[-r]
VolumeGroupNamepv_path
Foractivatedversion1.0volumegroups,
vgmodify-a
[-v]
[-n]
[-r]
[-eMaxPhysicalExtents]
[-pMaxPhysicalVolumes]
[-lMaxLogicalVolumes]
VolumeGroupName
vgmodify-a-Bbootable
[-n]
[-r]
[-v]
[-eMaxPhysicalExtents]
[-pMaxPhysicalVolumes]
[-lMaxLogicalVolumes]
vgmodify-a-o
[-v]
[-r]
VolumeGroupName
vgmodify-a-o-Bbootable
[-v]
[-r]
vgmodify-a-E
[-o]
[-v]
[-r]
VolumeGroupName[]
vgmodify-a-E
[-v]
[-r]
[-eMaxPhysicalExtents]
[-pMaxPhysicalVolumes]
[-lMaxLogicalVolumes]
VolumeGroupName[]
vgmodify-a-CDLC_Size
[-r]
VolumeGroupNamepv_path
Torecoveraphysicalvolumefromapreviousonlineorofflinevgmodifyfailure,
vgmodify-Rconf_
Todisplayatableofoptimizedpossiblevolumegroupsettingsforanactivatedordeactivatedversion1.0volumegr
oup,
vgmodify-t
[-v]
[-n]
VolumeGroupName
vgmodify-t-Bbootable
[-v]
[-n]
Foractivatedvolumegroupsversion2.0andhigher,
vgmodify-a-E
[-r]
VolumeGroupName[]
vgmodify-a-CDLC_Size
[-r]
VolumeGroupNamepv_path
vgmodify-a
[-E]
-SMax_VG_Size[-r]VolumeGroupName
我这里是2.2版本,因此使用如下命令:
root@rzcs:/#vgmodify-a-S1024G/dev/vg02
再次查看,已经修改成功
root@rzcs:/#vgdisplay/dev/vg02
---Volumegroups---
VGName/dev/vg02
VGWriteAccessread/write
VGStatusavailable
MaxLV2047
CurLV2
OpenLV2
CurSnapshotLV0
MaxPV2048
CurPV2
ActPV2
MaxPEperPV16384
VGDA4
PESize(Mbytes)64
Unshareunitsize(Kbytes)1024
TotalPE11998
AllocPE4799
Currentpre-allocatedPE0
FreePE7199
TotalPVG0
TotalSparePVs0
TotalSparePVsinuse0
VGVersion2.2
VGMaxSize1t
VGMaxExtents16384
CurSnapshotCapacity0p
MaxSnapshotCapacity1t
2024年6月13日发(作者:戴采白)
1、查看VG属性
root@rzcs:/#vgdisplay-v/dev/vg02
---Volumegroups---
VGName/dev/vg02
VGWriteAccessread/write
VGStatusavailable
MaxLV2047
CurLV2
OpenLV2
CurSnapshotLV0
MaxPV2048
CurPV2
ActPV2
MaxPEperPV4800
VGDA4
PESize(Mbytes)64
Unshareunitsize(Kbytes)1024
TotalPE4800
AllocPE4799
Currentpre-allocatedPE0
FreePE1
TotalPVG0
TotalSparePVs0
TotalSparePVsinuse0
VGVersion2.2
VGMaxSize300g
VGMaxExtents4800
CurSnapshotCapacity0p
MaxSnapshotCapacity300g
可以看出,该VG最大只能300G,显然不能满足我们需求,此时即使使用
vgextend扩展也无用,因此需要修改VG的最大大小“VGMaxSize”
2、修改VG属性
命令和语法:
Usage:
Fordeactivatedversion1.0volumegroups,
vgmodify
[-v]
[-n]
[-r]
[-eMaxPhysicalExtents]
[-pMaxPhysicalVolumes]
[-lMaxLogicalVolumes]
VolumeGroupName
vgmodify-Bbootable
[-n]
[-r]
[-v]
[-eMaxPhysicalExtents]
[-pMaxPhysicalVolumes]
[-lMaxLogicalVolumes]
vgmodify-o
[-v]
[-r]
VolumeGroupName
vgmodify-o-Bbootable
[-v]
[-r]
vgmodify-CDLC_Size
[-r]
VolumeGroupNamepv_path
Foractivatedversion1.0volumegroups,
vgmodify-a
[-v]
[-n]
[-r]
[-eMaxPhysicalExtents]
[-pMaxPhysicalVolumes]
[-lMaxLogicalVolumes]
VolumeGroupName
vgmodify-a-Bbootable
[-n]
[-r]
[-v]
[-eMaxPhysicalExtents]
[-pMaxPhysicalVolumes]
[-lMaxLogicalVolumes]
vgmodify-a-o
[-v]
[-r]
VolumeGroupName
vgmodify-a-o-Bbootable
[-v]
[-r]
vgmodify-a-E
[-o]
[-v]
[-r]
VolumeGroupName[]
vgmodify-a-E
[-v]
[-r]
[-eMaxPhysicalExtents]
[-pMaxPhysicalVolumes]
[-lMaxLogicalVolumes]
VolumeGroupName[]
vgmodify-a-CDLC_Size
[-r]
VolumeGroupNamepv_path
Torecoveraphysicalvolumefromapreviousonlineorofflinevgmodifyfailure,
vgmodify-Rconf_
Todisplayatableofoptimizedpossiblevolumegroupsettingsforanactivatedordeactivatedversion1.0volumegr
oup,
vgmodify-t
[-v]
[-n]
VolumeGroupName
vgmodify-t-Bbootable
[-v]
[-n]
Foractivatedvolumegroupsversion2.0andhigher,
vgmodify-a-E
[-r]
VolumeGroupName[]
vgmodify-a-CDLC_Size
[-r]
VolumeGroupNamepv_path
vgmodify-a
[-E]
-SMax_VG_Size[-r]VolumeGroupName
我这里是2.2版本,因此使用如下命令:
root@rzcs:/#vgmodify-a-S1024G/dev/vg02
再次查看,已经修改成功
root@rzcs:/#vgdisplay/dev/vg02
---Volumegroups---
VGName/dev/vg02
VGWriteAccessread/write
VGStatusavailable
MaxLV2047
CurLV2
OpenLV2
CurSnapshotLV0
MaxPV2048
CurPV2
ActPV2
MaxPEperPV16384
VGDA4
PESize(Mbytes)64
Unshareunitsize(Kbytes)1024
TotalPE11998
AllocPE4799
Currentpre-allocatedPE0
FreePE7199
TotalPVG0
TotalSparePVs0
TotalSparePVsinuse0
VGVersion2.2
VGMaxSize1t
VGMaxExtents16384
CurSnapshotCapacity0p
MaxSnapshotCapacity1t