> CentOS > CentOS教程 >

CentOS LVM分区修复挂载

在Linux下使用新硬盘安装系统,安装好以后再挂载原来的硬盘,分区格式全为系统默认分区,系统默认使用的
是lvm格式,并且默认的卷都是 VolGroup00


使用 pvs 查看显示如下:



[root@localhost ~]# pvs PV VG Fmt Attr PSize PFree Found more than one VG called VolGroup00. Please supply VG uuid.



原因是存在两个 VolGroup00,修改的方法他已经提示了要指定 VG uuid即可。

查看VG uuid的命令为:



[root@localhost ~]# vgs -v Finding all volume groups Finding volume group “VolGroup00″ Finding volume group “VolGroup00″ VG Attr Ext #PV #LV #SN VSize VFree VG UUID VolGroup00 wz–n- 32.00M 136.62G 0 dcHa6G-abU2-Xfq8-EPBm-jBLj-sf18-O5uH0U VolGroup00 wz–n- 32.00M 136.62G 0 OF8g7h-PQJB-9D9z-yPxn-1kfY-Advq-YbNHJ9



查到VG uuid以后,再次执行改名:



[root@localhost ~]# vgrename OF8g7h-PQJB-9D9z-yPxn-1kfY-Advq-YbNHJ9 VolGroup01 Volume group “VolGroup00″ still has active LVs



修改成功以后,再执行:lvscan



[root@localhost ~]# lvscan inactive ‘/dev/VolGroup01/LogVol00′ [130.84 GB] inherit inactive ‘/dev/VolGroup01/LogVol01′ [5.78 GB] inherit ACTIVE ‘/dev/VolGroup00/LogVol00′ [130.84 GB] inherit ACTIVE ‘logical volume



至此,全部完成。

Linux下挂载lvm 并解决同名冲突

fsck -y

(责任编辑:IT)