linux修改挂载目录
修改扩展磁盘默认的挂载点/home到/data
[root@localhost ~]# df -h
/dev/mapper/VolGroup-lv_root
50G 3.3G 44G 7% /
tmpfs 7.7G 0 7.7G 0% /dev/shm
/dev/sda2 485M 36M 424M 8% /boot
/dev/sda1 200M 256K 200M 1% /boot/efi
/dev/mapper/VolGroup-lv_home
492G 3.7G 463G 1% /home
# mkdir /data
# umount /home
# mount /dev/mapper/VolGroup-lv_home /data
# vi /etc/fstab
/dev/mapper/VolGroup-lv_root / ext4 defaults 1 1
UUID=e8e5023f-de70-4a7e-9bc9-4d22ed6fdc0b /boot ext4 defaults 1 2
UUID=5268-C0F3 /boot/efi vfat umask=0077,shortname=winnt 0 0
/dev/mapper/VolGroup-lv_home /home ext4 defaults 1 2
/dev/mapper/VolGroup-lv_swap swap swap defaults 0 0
tmpfs /dev/shm tmpfs defaults 0 0
devpts /dev/pts devpts gid=5,mode=620 0 0
sysfs /sys sysfs defaults 0 0
proc /proc proc defaults 0 0
修改/etc/fstab里面的/home为/data, 让系统启动的时候自动挂载到/data
转载:http://www.2cto.com/os/201310/253452.html