我今天拿了一顆有作LVM分割的硬碟,想要抓取裡面的資料
一般我們掛載都是直接 mount /dev/sdb1 /XXX 就可以了,但
它是經過LVM切割,mount時會跟我要type,無法成功掛載
所以要這麼作 (如下)
1。先 pvscan 掃一下是否有LVM磁區
PV /dev/hdb2 VG VolGroup lvm2 [98.80 GB / 0 free]
Total: 1 [98.80 GB] / in use: 1 [98.80 GB] / in no VG: 0 [0 ]
2。就可以看到一個VG名稱叫VolGroup,再用 vgchange -ay VolGroup
2 logical volume(s) in volume group “VolGroup” now active
3。用lvdisplay查看LV Name
— Logical volume —
LV Name /dev/VolGroup/lv_root
VG Name VolGroup
LV UUID ezpuV3-k5C3-utDL-uiEW-esH8-XuKf-i8AKXG
LV Write Access read/write
LV Status available
# open 1
LV Size 98.05 GB
Current LE 25100
Segments 1
Allocation inherit
Read ahead sectors auto
– currently set to 256
Block device 253:0— Logical volume —
LV Name /dev/VolGroup/lv_swap
VG Name VolGroup
LV UUID w2sFjH-CaG6-sSdp-caXJ-ep1H-jUwF-5z1hxy
LV Write Access read/write
LV Status available
# open 0
LV Size 768.00 MB
Current LE 192
Segments 1
Allocation inherit
Read ahead sectors auto
– currently set to 256
Block device 253:1
4。就可以掛載了 mount /dev/VolGroup/lv_root /path/mount
留言