/ CentOS

ntfs-3g: CentOS7挂载1T移动硬盘

  • NTFS:安装NTFS支持

yum install ntfs-3g fuse

  • NTFS:查看移动硬盘

[root@X61CentOS ~]# fdisk -l
磁盘 /dev/sda:120.0 GB, 120034123776 字节,234441648 个扇区
Units = 扇区 of 1 * 512 = 512 bytes
扇区大小(逻辑/物理):512 字节 / 512 字节
I/O 大小(最小/最佳):512 字节 / 512 字节
磁盘 /dev/sdb:1000.2 GB, 1000204886016 字节,1953525168 个扇区
Units = 扇区 of 1 * 512 = 512 bytes
扇区大小(逻辑/物理):512 字节 / 4096 字节
I/O 大小(最小/最佳):4096 字节 / 4096 字节

   设备 Boot      Start         End      Blocks   Id  System
/dev/sdb1               1  4294967295  2147483647+  ee  GPT
Partition 1 does not start on physical sector boundary.
  • NTFS:准备专用目录

[ntfs@X61CentOS ~]$ sudo mkdir -p /www/syncRepos
[ntfs@X61CentOS ~]$ sudo chown -R ntfs /www/syncRepos
  • NTFS:挂载移动硬盘 - fstab方式 # 【失败】

[ntfs@X61CentOS ~]$ sudo chmod +w /etc/fstab;sudo vi /etc/fstab;sudo chmod -w /etc/fstab;
/dev/sdb1       /www/syncRepos   ntfs-3g  rw,umask=0000,defaults 0 0 
[ntfs@X61CentOS ~]$ sudo mount /www/syncRepos
Mount is denied because the NTFS volume is already exclusively opened.
The volume may be already mounted, or another software may use it which
could be identified for example by the help of the 'fuser' command.
[ntfs@X61CentOS ~]$ fuser -m -u /www/syncRepos
/www/syncRepos:     7695re(ntfs)
[ntfs@X61CentOS ~]$ kill 7695re
bash: kill: 7695re: 参数必须是进程或任务 ID
  • NTFS:挂载移动硬盘 - ntfs-3g方式 【成功】

[root@X61CentOS ~]# sudo mount -t ntfs-3g /dev/sdb1 /www/syncRepos -o username=ntfs
NTFS signature is missing.
Failed to mount '/dev/sdb1': 无效的参数
The device '/dev/sdb1' doesn't seem to have a valid NTFS.
Maybe the wrong device is used? Or the whole disk instead of a
partition (e.g. /dev/sda, not /dev/sda1)? Or the other way around?


[ntfs@X61CentOS ~]$ sudo mount -t ntfs-3g /dev/sdb1 /www/syncRepos -o username=ntfs
[ntfs@X61CentOS ~]$ ls /www/syncRepos/
bookOther  bookTest  codeOpen    Config.Msi  GhostT430sWin10  iniDevice  movie  osAndroid  osWin    $RECYCLE.BIN  softGame   softWin                    temp
bookRead   codeJava  codePython  fileJob     icon.ico         iniOSWin   music  osLinux    picture  RECYCLER      softLinux  System Volume Information  迅雷下载