修改/etc/fstab配置文件,末尾添加一行:
/dev/xvdb1 /u01 ext4 defaults 0 0
显示当前目录,已成功挂载/u01目录:
[root@localhost ~]# df -h
Filesystem Size Used Avail Use% Mounted on
/dev/mapper/VolGroup-lv_root
26G 2.9G 22G 13% /
tmpfs 1.9G 0 1.9G 0% /dev/shm
/dev/xvda1 485M 32M 428M 7% /boot
/dev/xvdb1 50G 180M 47G 1% /u01