CentOS7挂载读写NTFS分区的方法(ntfs-3g)

http://www.linuxidc.com/Linux/2017-08/146365.htm

因为CentOS 默认不识别NTFS的磁盘格式,所以我们要借助另外一个软件来挂载,那就是ntfs-3g了

自带的yum源没有这个软件,要用第三方的软件源,这里我用的是阿里的epel.

  1. 切换到系统yum目录并下载阿里的
[root@localhost ~]# cd /etc/yum.repos.d/
[root@localhost yum.repos.d]# wget http://mirrors.aliyun.com/repo/epel-7.repo
  1. 查找当前源上可用的ntfs-3g软件
[root@localhost yum.repos.d]# yum list ntfs*
已加载插件:fastestmirror, langpacks
Repository epel is listed more than once in the configuration
Repository epel-debuginfo is listed more than once in the configuration
Repository epel-source is listed more than once in the configuration
Loading mirror speeds from cached hostfile
 * elrepo: dfw.mirror.rackspace.com
 * epel: mirrors.aliyun.com
已安装的软件包
ntfs-3g.x86_64                        2:2017.3.23-1.el7                  @epel
可安装的软件包
ntfs-3g-devel.x86_64                  2:2017.3.23-1.el7                  epel
ntfsprogs.x86_64  
  1. 安装:
[root@localhost yum.repos.d]# yum -y install ntfs-3g
  1. 挂载U盘

插入NTFS格式的U盘,fdisk -l 查看盘符,新建挂载目录并挂载

[root@localhost ~]# fdisk -l

磁盘 /dev/sdb:31.1 GB, 31104958464 字节,60751872 个扇区
Units = 扇区 of 1 * 512 = 512 bytes
扇区大小(逻辑/物理):512 字节 / 512 字节
I/O 大小(最小/最佳):512 字节 / 512 字节
磁盘标签类型:dos
磁盘标识符:0x00000000

  设备 Boot      Start        End      Blocks  Id  System
/dev/sdb1  *        2048    60751871    30374912    7  HPFS/NTFS/exFAT   -->这里的U盘是sdb1

[root@localhost ~]# mkdir /mnt/ukey

[root@localhost ~]# mount ntfs-3g /dev/sdb1 /mnt/ukey
  1. 卸载U盘, 听说不卸载的话到Windows上会提示格式化磁盘 -_-”
[root@localhost ~]# umount /dev/sdb1
  • 1
    点赞
  • 10
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值