创建逻辑卷快照发生的错误

2019-03-09  本文已影响0人  晨曦_zdq

1、

[root@a-210 lv01]# lvcreate -s -L 12M -n snap_lv01 /dev/mydata/lv01
  Using default stripesize 64.00 KiB.
  Logical volume "snap_lv01" created.
[root@a-210 lv01]# lsblk
NAME                   MAJ:MIN RM  SIZE RO TYPE MOUNTPOINT
sda                      8:0    0   20G  0 disk 
├─sda1                   8:1    0  300M  0 part /boot
├─sda2                   8:2    0    2G  0 part [SWAP]
└─sda3                   8:3    0 17.7G  0 part /
sdb                      8:16   0   20G  0 disk 
├─mydata-data          253:0    0    4G  0 lvm  /mydata/data
├─mydata-lv01-real     253:1    0    2G  0 lvm  
│ ├─mydata-lv01        253:2    0    2G  0 lvm  /mnt/lv01
│ └─mydata-snap_lv01   253:4    0    2G  0 lvm  
└─mydata-snap_lv01-cow 253:3    0   12M  0 lvm  
  └─mydata-snap_lv01   253:4    0    2G  0 lvm  
sr0                     11:0    1 1024M  0 rom  

#[root@d-163 lv01]# lvcreate -s -L 100M -n snap_lv01 /dev/vg01/lv01 

[root@d-163 mnt]# mount /dev/vg01/snap_lv01 /mnt/snap_lv01/
mount: wrong fs type, bad option, bad superblock on /dev/mapper/vg01-snap_lv01,
       missing codepage or helper program, or other error

       In some cases useful info is found in syslog - try
       dmesg | tail or so.

案例三:修复superblock
挂载的时候报错超级快损坏的解决办法
找到备份的superblock
[root@tianyun ~]# dumpe2fs -h /dev/datavg/lv1 |grep 'Blocks per group'
dumpe2fs 1.42.9 (28-Dec-2013)
Blocks per group: 8192

利用备份的 superblock恢复superblock
[root@tianyun ~]# fsck.ext4 -b 8192 /dev/datavg/lv1

上一篇下一篇

猜你喜欢

热点阅读