免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
最近访问板块 发新帖
查看: 1356 | 回复: 0
打印 上一主题 下一主题

Add an LVM Disk and etc. [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2006-12-16 12:40 |只看该作者 |倒序浏览

# pvcreate -f /dev/rdsk/c0t4d0
# mkdir /dev/vg05
# mknod /dev/vg05/group c 64 0x050000
# vgcreate /dev/vg05 /dev/dsk/c0t4d0
# lvcreate -L 100 vg05
# lvcreate -L 100 vg05
# newfs /dev/vg05/rlvol1
# newfs /dev/vg05/rlvol2
# mkdir /vg5lv1 /vg5lv2
# mount /dev/vg05/lvol1 /vg5lv1
# mount /dev/vg05/lvol2 /vg5lv2
# vgcfgbackup vg05

Extend An LVM Logical Volume:
# lvextend -L 200 /dev/vg05/lvol2
# umount /dev/vg05/lvol2
# extendfs /dev/vg05/rlvol2
# mount /dev/vg05/lvol2
# vgcfgbackup vg05

Reduce the Size of an LVM Logical Volume:
# fbackup -f /dev/rmt/0m -0vHi /accounts
# umount /dev/vg05/lvol2
# lvreduce -L 100 /dev/vg05/lvol2
(Alternatively, the logical volume can be reduced from a specific physical volume as shown below)
# lvreduce -L 100 /dev/vg05/lvol2 /dev/dsk/c0t6d0
# newfs /dev/vg05/rlvol2
# mount -a
If there is sufficient space then restore the data:
# frecover -f /dev/rmt/0m
# vgcfgbackup vg05

Moving an LVM Logical Volume:
# pvcreate -f /dev/rdsk/c0t2d0
# vgextend /dev/vg01 /dev/dsk/c0t2d0
# pvmove -n /dev/vg01/lvol1 /dev/dsk/c0t1d0 /dev/dsk/c0t2d0
# vgcfgbackup vg01



本文来自ChinaUnix博客,如果查看原文请点:http://blog.chinaunix.net/u/27852/showart_216760.html
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP