Linux 更改逻辑卷名称
lvrename vgname old-lvname new-lvname
注意:更改后需重启才能生效,相关的fstab需相应修改,否则启动挂载会出问题,如果修改的是根目录的lv,除了修改fstab相关挂载外,还需要修改grub的启动参数,不然系统都启动不了
/boot/grub/grub.conf文件内容:
# grub.conf generated by anaconda # # Note that you do not have to rerun grub after making changes to this file # NOTICE: You have a /boot partition. This means that # all kernel and initrd paths are relative to /boot/, eg. # root (hd0,2)
# kernel /vmlinuz-version ro root=/dev/VolGroup00/LogVol00 # initrd /initrd-version.img #boot=/dev/sda default=1 timeout=1000 splashimage=(hd0,2)/grub/splash.xpm.gz hiddenmenu title Fedora Core (2.6.9-1.667)
root (hd0,2)
kernel /vmlinuz-2.6.9-1.667 ro root=/dev/VolGroup00/LogVol00 rhgb quiet initrd /initrd-2.6.9-1.667.img title windows 2000 adv rootnoverify (hd0,0)
chainloader +1
修改相关lv加载路径