有些場景,我們需要在服務器上插入U盤,但是現在的U盤或者移動硬盤,大多都是exFat格式的,有時候linux系統識別不了,可以按照以下方式掛載。
1、安裝nux repo(可以不裝)
yum install -y http://li.nux.ro/download/nux/dextop/el7/x86_64/nux-dextop-release-0-5.el7.nux.noarch.rpm
2、安裝fuse包
yum install exfat-utils fuse-exfa -y
3、插u盤,fdisk -l 看看u盤是否讀取成功
[root@localhost data]# fdisk -l Disk /dev/sda: 1000.2 GB, 1000204886016 bytes, 1953525168 sectors Units = sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 4096 bytes I/O size (minimum/optimal): 4096 bytes / 4096 bytes Disk label type: dos Disk identifier: 0x00053782 Device Boot Start End Blocks Id System /dev/sda1 * 2048 1026047 512000 83 Linux /dev/sda2 1026048 1953523711 976248832 8e Linux LVM Disk /dev/mapper/centos-root: 995.4 GB, 995379642368 bytes, 1944100864 sectors Units = sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 4096 bytes I/O size (minimum/optimal): 4096 bytes / 4096 bytes Disk /dev/mapper/centos-swap: 4294 MB, 4294967296 bytes, 8388608 sectors Units = sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 4096 bytes I/O size (minimum/optimal): 4096 bytes / 4096 bytes Disk /dev/sdb: 512.1 GB, 512076283904 bytes, 1000148992 sectors Units = sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 4096 bytes I/O size (minimum/optimal): 4096 bytes / 1048576 bytes Disk label type: dos Disk identifier: 0x16f2a91f Device Boot Start End Blocks Id System /dev/sdb1 1 4294967295 2147483647+ ee GPT Partition 1 does not start on physical sector boundary. [root@localhost data]# # 發現已經有了sdb1,讀取成功
4、掛載
[root@localhost data]# mount -t exfat /dev/sdb1 /mnt FUSE exfat 1.2.7 [root@localhost data]# df -Th Filesystem Type Size Used Avail Use% Mounted on devtmpfs devtmpfs 3.8G 0 3.8G 0% /dev tmpfs tmpfs 3.8G 0 3.8G 0% /dev/shm tmpfs tmpfs 3.8G 298M 3.5G 8% /run tmpfs tmpfs 3.8G 0 3.8G 0% /sys/fs/cgroup /dev/mapper/centos-root xfs 927G 243G 685G 27% / /dev/sda1 xfs 494M 144M 350M 30% /boot tmpfs tmpfs 771M 0 771M 0% /run/user/0 /dev/sdb1 fuseblk 477G 9.0M 477G 1% /mnt [root@localhost data]# cd /mnt/ [root@localhost mnt]# ls System Volume Information [root@localhost mnt]# ll total 1024 drwxrwxrwx. 1 root root 1048576 Dec 21 11:18 System Volume Information [root@localhost mnt]#
掛載成功,可以開始使用了。