博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
centos6挂载U盘
阅读量:4331 次
发布时间:2019-06-06

本文共 2950 字,大约阅读时间需要 9 分钟。

一、FAT格式的U盘

插入U盘

[root@localhost ~]# dmesg | grep usbusbcore: registered new interface driver usbfsusbcore: registered new interface driver hubusbcore: registered new device driver usbusb usb1: New USB device found, idVendor=1d6b, idProduct=0002usb usb1: New USB device strings: Mfr=3, Product=2, SerialNumber=1usb usb1: Product: EHCI Host Controllerusb usb1: Manufacturer: Linux 2.6.32-431.el6.x86_64 ehci_hcdusb usb1: SerialNumber: 0000:00:0b.0usb usb1: configuration #1 chosen from 1 choiceusb usb2: New USB device found, idVendor=1d6b, idProduct=0001usb usb2: New USB device strings: Mfr=3, Product=2, SerialNumber=1usb usb2: Product: OHCI Host Controllerusb usb2: Manufacturer: Linux 2.6.32-431.el6.x86_64 ohci_hcdusb usb2: SerialNumber: 0000:00:06.0usb usb2: configuration #1 chosen from 1 choiceusbcore: registered new interface driver hiddevusbcore: registered new interface driver usbhidusbhid: v2.6:USB HID core driverusb 1-1: new high speed USB device number 2 using ehci_hcdusb 1-1: New USB device found, idVendor=0951, idProduct=1666usb 1-1: New USB device strings: Mfr=1, Product=2, SerialNumber=3usb 1-1: Product: DataTraveler 3.0usb 1-1: Manufacturer: Kingstonusb 1-1: SerialNumber: 60A44C3FACC9F21109990161usb 1-1: configuration #1 chosen from 1 choiceusbcore: registered new interface driver usb-storageusb-storage: device found at 2usb-storage: waiting for device to settle before scanningusb-storage: device scan completeusb 1-1: USB disconnect, device number 2

 

[root@localhost ~]# fdisk -lDisk /dev/sdb: 15.5 GB, 15472047104 bytes255 heads, 63 sectors/track, 1881 cylindersUnits = cylinders of 16065 * 512 = 8225280 bytesSector size (logical/physical): 512 bytes / 512 bytesI/O size (minimum/optimal): 512 bytes / 512 bytesDisk identifier: 0xcad4ebea   Device Boot      Start         End      Blocks   Id  System/dev/sdb4   *           1        1882    15109293    c  W95 FAT32 (LBA)

 

[root@localhost ~]# mkdir /mnt/usb[root@localhost ~]# mount /dev/sdb4 /mnt/usb/[root@localhost ~]# df -hFilesystem                    Size  Used Avail Use% Mounted on/dev/mapper/VolGroup-lv_root   50G  880M   46G   2% /tmpfs                         1.9G     0  1.9G   0% /dev/shm/dev/sda1                     485M   33M  427M   8% /boot/dev/mapper/VolGroup-lv_home   65G  180M   62G   1% /home/dev/sdb4                      15G  5.3G  9.2G  37% /mnt/usb

二、NTFS格式挂载

我自己的移动硬盘为NTFS格式,共3个分区

连接上之后dmesg | grep usb可以看到USB设备已经连接了。

然后centos6.5默认是不识别NTFS分区的(微软专利,得谈合作),所以需要安装NTFSde rpm包

然后我就在https://pkgs.org/下载了fuse-ntfs-3g-2013.1.13-2.el6.rf.x86_64.rpm,然后装了glibc也死活不行,

然后又去https://pkgs.org/下载了fuse-ntfs-3g-2013.1.13-2.el6.rf.x86_64.rpm,执行

yum install -y fuse-ntfs-3g-2013.1.13-2.el6.rf.x86_64.rpm

然后搞定了。哎!不能求新丫!!!

 

modprobe usb-storage    #fdisk看不到就执行这条命令fdisk -l

 

mount  /dev/sdb2 /mnt/usb/mount -t ntfs-3g /dev/sdb2 /mnt/usb/mount.ntfs /dev/sdb2 /mnt/usb/

以上3个命令都可以,只不过不指定mount文件系统的时候系统会多花1s的时间去查看到底是啥系统。

 

转载于:https://www.cnblogs.com/tcicy/p/8492553.html

你可能感兴趣的文章
微软自己的官网介绍 SSL 参数相关
查看>>
Composite UI Application Block (CAB) 概念和术语
查看>>
ajax跨域,携带cookie
查看>>
阶段3 2.Spring_01.Spring框架简介_03.spring概述
查看>>
阶段3 2.Spring_02.程序间耦合_1 编写jdbc的工程代码用于分析程序的耦合
查看>>
阶段3 2.Spring_01.Spring框架简介_04.spring发展历程
查看>>
阶段3 2.Spring_02.程序间耦合_3 程序的耦合和解耦的思路分析1
查看>>
阶段3 2.Spring_02.程序间耦合_5 编写工厂类和配置文件
查看>>
阶段3 2.Spring_01.Spring框架简介_05.spring的优势
查看>>
阶段3 2.Spring_02.程序间耦合_7 分析工厂模式中的问题并改造
查看>>
阶段3 2.Spring_02.程序间耦合_4 曾经代码中的问题分析
查看>>
阶段3 2.Spring_03.Spring的 IOC 和 DI_2 spring中的Ioc前期准备
查看>>
阶段3 2.Spring_03.Spring的 IOC 和 DI_4 ApplicationContext的三个实现类
查看>>
阶段3 2.Spring_02.程序间耦合_8 工厂模式解耦的升级版
查看>>
阶段3 2.Spring_03.Spring的 IOC 和 DI_6 spring中bean的细节之三种创建Bean对象的方式
查看>>
阶段3 2.Spring_04.Spring的常用注解_3 用于创建的Component注解
查看>>
阶段3 2.Spring_04.Spring的常用注解_2 常用IOC注解按照作用分类
查看>>
阶段3 2.Spring_09.JdbcTemplate的基本使用_5 JdbcTemplate在spring的ioc中使用
查看>>
阶段3 3.SpringMVC·_07.SSM整合案例_02.ssm整合之搭建环境
查看>>
小D课堂 - 零基础入门SpringBoot2.X到实战_第1节零基础快速入门SpringBoot2.0_3、快速创建SpringBoot应用之手工创建web应用...
查看>>