我的笔记本电脑上安装了 Ubuntu 13.04。
我决定不进行升级,而是在新的 SSD 上全新安装 14.04。
因此,我有两个驱动器。一个装有 13.04 和我的旧数据,另一个装有 14.04。两个 Ubuntu 实例均使用默认的“擦除磁盘并安装 Ubuntu”选项安装,并选中 LVM。
我现在正尝试安装旧驱动器来迁移数据。但是,LVM 分区的名称相同,因此不允许它出现。
我该如何解决这个问题?我可以重命名吗?
一些诊断...
root@computer:/# fdisk -lu
Disk /dev/sda: 240.1 GB, 240057409536 bytes
255 heads, 63 sectors/track, 29185 cylinders, total 468862128 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 identifier: 0x00087708
Device Boot Start End Blocks Id System
/dev/sda1 * 2048 499711 248832 83 Linux
/dev/sda2 501758 468860927 234179585 5 Extended
/dev/sda5 501760 468860927 234179584 8e Linux LVM
Disk /dev/mapper/ubuntu--vg-root: 222.7 GB, 222746902528 bytes
255 heads, 63 sectors/track, 27080 cylinders, total 435052544 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 identifier: 0x00000000
Disk /dev/mapper/ubuntu--vg-root doesn't contain a valid partition table
Disk /dev/mapper/ubuntu--vg-swap_1: 17.0 GB, 17049845760 bytes
255 heads, 63 sectors/track, 2072 cylinders, total 33300480 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 identifier: 0x00000000
Disk /dev/mapper/ubuntu--vg-swap_1 doesn't contain a valid partition table
Disk /dev/sdb: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders, total 976773168 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk identifier: 0x000903b4
Device Boot Start End Blocks Id System
/dev/sdb1 * 2048 499711 248832 83 Linux
/dev/sdb2 501758 976771071 488134657 5 Extended
Partition 2 does not start on physical sector boundary.
/dev/sdb5 501760 976771071 488134656 8e Linux LVM
root@computer:/# pvscan
PV /dev/sdb5 VG ubuntu-vg lvm2 [465.52 GiB / 48.00 MiB free]
PV /dev/sda5 VG ubuntu-vg lvm2 [223.33 GiB / 0 free]
Total: 2 [688.85 GiB] / in use: 2 [688.85 GiB] / in no VG: 0 [0 ]
root@computer:/# vgscan
Reading all physical volumes. This may take a while...
Found volume group "ubuntu-vg" using metadata type lvm2
Found volume group "ubuntu-vg" using metadata type lvm2
root@computer:/# lvscan
inactive '/dev/ubuntu-vg/root' [449.60 GiB] inherit
inactive '/dev/ubuntu-vg/swap_1' [15.88 GiB] inherit