1. 创建一个logical volumn
lvcreate -L 1g -n testlv testvg
2. 创建一个文件
touch /mnt/a/testfile
echo 'aaaaaaaaaaaaaaaaa' >> /mnt/a/testfile
3. 创建快照
lvcreate -s -L 100M -n testbackup /dev/testvg/testlv
4. 修改testfile
echo 'bbbbbbbbbbbbbbbbbbb' >> testfile
5. 挂载快照logical volumn
mount /dev/testvg/testbackup /mnt/b
6. 检查备份文件
more /mnt/b/testfile
后续:
1. 取消挂载
umount /mnt/b
umount /mnt/a
2. 删除快照logical volumn
lvremove /dev/testvg/testbackup
3. 删除监控logical volumn
lvremove /ev/testvg/testlv
4. 删除volumn group
vgremove testvg
来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/24751738/viewspace-707318/,如需转载,请注明出处,否则将追究法律责任。
转载于:http://blog.itpub.net/24751738/viewspace-707318/