手动挂载
检测磁盘
$ lsblk
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
sda 8:0 1 14.5G 0 disk
├─sda1 8:1 1 256M 0 part /boot
└─sda2 8:2 1 14.1G 0 part /
sdb 8:16 0 119.2G 0 disk
└─sdb1 8:17 0 119.2G 0 part
mmcblk1 179:0 0 7.3G 0 disk
├─mmcblk1p1 179:1 0 122M 0 part
└─mmcblk1p2 179:2 0 6.5G 0 part
mmcblk1boot0 179:32 0 4M 1 disk
mmcblk1boot1 179:64 0 4M 1 disk
zram0 254:0 0 50M 0 disk /var/log
zram1 254:1 0 870.6M 0 disk [SWAP]
建立目录
mkdir /mnt/sdb1
挂载
mount /dev/sdb1 /mnt/sdb1/
开机自动挂载
查看磁盘信息
记下UUID、TYPE
$ blkid /dev/sdb1
/dev/sdb1: UUID="4c3f013e-4a9b-4794-ac86-9805fbd39907" TYPE="ext4" PARTLABEL="Basic data partition" PARTUUID="d07ccef2-01d5-43bb-b220-1a2b0ecf251b"
修改 /etc/fstab
最下面添加这一行
UUID=4c3f013e-4a9b-4794-ac86-9805fbd39907 /mnt/sdb1 ext4 defaults 0 0
应用
mount -a