技术
成就梦想!

Centos挂载NTFS分区设备

一、环境信息

操作系统:CentOS Linux release 8.5.2111
YUM源:http://mirrors.aliyun.com/repo/Centos-8.repo

二、设备配置

1、yum安装ntfs-3g

yum install epel-release -y   #安装epel源
yum install ntfs-3g -y

2、通过 mount -t ntfs-3g /dev/sdb1 /data/挂载ntfs分区到/data,如果提示下面的报错,则通过第3步修复;

[root@localhost ~]# mount -t ntfs-3g /dev/sdb1 /data/
$MFTMirr does not match $MFT (record 3).
Failed to mount '/dev/sdb1': 输入/输出错误
NTFS is either inconsistent, or there is a hardware fault, or it's a
SoftRAID/FakeRAID hardware. In the first case run chkdsk /f on Windows
then reboot into Windows twice. The usage of the /f parameter is very
important! If the device is a SoftRAID/FakeRAID then first activate
it and mount a different device under the /dev/mapper/ directory, (e.g.
/dev/mapper/nvidia_eahaabcc1). Please see the 'dmraid' documentation
for more details.

3、linux中修复分区表;

yum install ntfsprogs -y
ntfsfix /dev/sdb1   #修复NTFS分区,修复文件系统可能会造成数据丢失,请记得备份数据;

4、永久挂载文件系统

echo "mount -t ntfs-3g /dev/sdb1 /data/" >> /etc/rc.local
mount -a
chmod +x /etc/rc.local

赞(0)
未经允许不得转载:未来往事 » Centos挂载NTFS分区设备

评论 抢沙发

  • 昵称 (必填)
  • 邮箱 (必填)
  • 网址