Solve the Problem of attaching LVM names in Linux

Source: Internet
Author: User


Solve the Problem of attaching LVM names in Linux by using a new hard disk to install the system. After installation, mount the original hard disk. The partition format is all System
Default partition. The default format is lvm. The default volume is VolGroup00 www.2cto.com and pvs is displayed as follows: [root @ localhost ~] # Pvs pv vg Fmt Attr PSize PFree/dev/sda2 VolGroup00 lvm2 a-136.62G 0/dev/sdb2 VolGroup00 lvm2 a-136.62G 0 found that the correct identification of two VG, but with the same name, how can I mount it? The solution is to rename the original VG and mount it after resolving the conflict. When you rename the file in the format of vgrename VolGroup00 VolGroup01, the message [root @ localhost ~] is displayed. # Vgrename VolGroup00 VolGroup01 Found more than one VG called VolGroup00. Please supply VG uuid. The reason is that two VolGroup00 exists. The modification method prompts you to specify the VG uuid. Run the following command to view the 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.00 M 1 2 0 136.62G 0 dcHa6G-abU2-Xfq8-EPBm-jBLj-sf18-O5uH0U VolGroup00 wz -- n-32.00 M 1 2 0 136.62G 0 OF8g7h-PQJB-9D9z-yPxn-1kfY-Advq-YbNHJ9 found VG uuid, rename again: [root @ localhost ~] # Vgrename OF8g7h-PQJB-9D9z-yPxn-1kfY-Advq-YbNHJ9 VolGroup01 Volume group & quot; VolGroup00 & quot; still has active LVs
After the modification is successful, run 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 '/dev/VolGroup00/LogVol01' [5.78 GB] inherit shows that the modified VolGroup01 is inactive. Use vgchange to load VolGroup01 [root @ localhost ~] # Vgchange-ay/dev/VolGroup01 2 logical volume (s) in volume group "VolGroup01" now the last mount is available [root @ localhost ~] # Mount/dev/VolGroup01/LogVol00/mnt/old now, all completed

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.