晕了,Linux下创建的NTFS分区Windows识别不了。

编译打包和其他
回复
头像
vickycq
帖子: 4507
注册时间: 2011-03-20 13:12
系统: Debian
来自: 山东省寿光县
联系:

晕了,Linux下创建的NTFS分区Windows识别不了。

#1

帖子 vickycq » 2014-10-15 0:27

不知道该发哪个版。

由于要和其它Windows机器交换数据,不得不在移动硬盘上使用NTFS。用gparted创建了NTFS分区,结果在Windows 7下无法识别。

用不同硬盘,不同系统做了对照实验,确定(EDIT:不确定?)是由在Linux下创建NTFS导致的。

逆向工程出来的还是不够完善?

有人遇到过吗? :em20
上次由 vickycq 在 2014-10-15 9:16,总共编辑 1 次。
Debian 中文论坛 - forums.debiancn.org
欢迎所有 Debian GNU/Linux 用户
poloshiao
论坛版主
帖子: 18279
注册时间: 2009-08-04 16:33

Re: 晕了,Linux下创建的NTFS分区Windows识别不了。

#2

帖子 poloshiao » 2014-10-15 8:35

把下面指令 複製 貼進終端機 執行
1-1. sudo fdisk -l
1-2. sudo parted -l print
把結果直接複製 貼上來
請說明 Windows 無法識別的是哪個分割區
头像
vickycq
帖子: 4507
注册时间: 2011-03-20 13:12
系统: Debian
来自: 山东省寿光县
联系:

Re: 晕了,Linux下创建的NTFS分区Windows识别不了。

#3

帖子 vickycq » 2014-10-15 9:14

感谢回答 :em01

$ sudo fdisk -l

代码: 全选

Disk /dev/sda: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders, total 976773168 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 identifier: 0xa18470c7

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1            2048    52600831    26299392   83  Linux
/dev/sda2   *    52600832    97656831    22528000    7  HPFS/NTFS/exFAT
/dev/sda3        97656832   974725119   438534144   83  Linux
/dev/sda4       974727166   976771071     1021953    5  Extended
Partition 4 does not start on physical sector boundary.
/dev/sda5       974727168   976771071     1021952   82  Linux swap / Solaris

Disk /dev/sdb: 2000.4 GB, 2000398934016 bytes
14 heads, 12 sectors/track, 23256126 cylinders, total 3907029168 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0xd981045a

   Device Boot      Start         End      Blocks   Id  System
/dev/sdb1            2048  3907024895  1953511424   83  Linux
以上,/dev/sda2是在Windows下正经创建的NTFS分区,后面System显示为HPFS/NTFS/exFAT;
/dev/sdb1是移动硬盘,用gparted格式化为NFTS,但System显示为Linux。

=======================================================

$ sudo parted -l print

代码: 全选

Model: ATA Hitachi HTS54505 (scsi)
Disk /dev/sda: 500GB
Sector size (logical/physical): 512B/4096B
Partition Table: msdos

Number  Start   End     Size    Type      File system     Flags
 1      1049kB  26.9GB  26.9GB  primary   ext4
 2      26.9GB  50.0GB  23.1GB  primary   ntfs            boot
 3      50.0GB  499GB   449GB   primary   ext4
 4      499GB   500GB   1046MB  extended
 5      499GB   500GB   1046MB  logical   linux-swap(v1)


Model: Generic External (scsi)
Disk /dev/sdb: 2000GB
Sector size (logical/physical): 512B/512B
Partition Table: msdos

Number  Start   End     Size    Type     File system  Flags
 1      1049kB  2000GB  2000GB  primary  ntfs
这个倒没看出有何异常。 :em06
Debian 中文论坛 - forums.debiancn.org
欢迎所有 Debian GNU/Linux 用户
头像
vickycq
帖子: 4507
注册时间: 2011-03-20 13:12
系统: Debian
来自: 山东省寿光县
联系:

Re: 晕了,Linux下创建的NTFS分区Windows识别不了。

#4

帖子 vickycq » 2014-10-15 9:48

另找了一个usb stick,用gparted格式化为NTFS文件系统,保存下来的log如下:

代码: 全选

GParted 0.18.0 --enable-libparted-dmraid --enable-online-resize

Libparted 2.3

Create Primary Partition #1 (ntfs, 3.75 GiB) on /dev/sdb  00:00:04    ( SUCCESS )
    	
create empty partition  00:00:01    ( SUCCESS )
    	
path: /dev/sdb1
start: 2048
end: 7864319
size: 7862272 (3.75 GiB)
clear old file system signatures in /dev/sdb1  00:00:00    ( SUCCESS )
    	
write 68.00 KiB of zeros at byte offset 0  00:00:00    ( SUCCESS )
write 4.00 KiB of zeros at byte offset 67108864  00:00:00    ( SUCCESS )
write 4.00 KiB of zeros at byte offset 4025479168  00:00:00    ( SUCCESS )
flush operating system cache of /dev/sdb  00:00:00    ( SUCCESS )
set partition type on /dev/sdb1  00:00:00    ( SUCCESS )
    	
new partition type: ntfs
create new ntfs file system  00:00:03    ( SUCCESS )
    	
mkntfs -Q -v -L "" /dev/sdb1
    	
Cluster size has been automatically set to 4096 bytes.
Creating NTFS volume structures.
Creating root directory (mft record 5)
Creating $MFT (mft record 0)
Creating $MFTMirr (mft record 1)
Creating $LogFile (mft record 2)
Creating $AttrDef (mft record 4)
Creating $Bitmap (mft record 6)
Creating $Boot (mft record 7)
Creating backup boot sector.
Creating $Volume (mft record 3)
Creating $BadClus (mft record 8)
Creating $Secure (mft record 9)
Creating $UpCase (mft record 0xa)
Creating $Extend (mft record 11)
Creating system file (mft record 0xc)
Creating system file (mft record 0xd)
Creating system file (mft record 0xe)
Creating system file (mft record 0xf)
Creating $Quota (mft record 24)
Creating $ObjId (mft record 25)
Creating $Reparse (mft record 26)
Syncing root directory index record.
Syncing $Bitmap.
Syncing $MFT.
Updating $MFTMirr.
Syncing device.
mkntfs completed successfully. Have a nice day.
========================================
Debian 中文论坛 - forums.debiancn.org
欢迎所有 Debian GNU/Linux 用户
头像
onshoestring
论坛版主
帖子: 4666
注册时间: 2009-09-06 5:53

Re: 晕了,Linux下创建的NTFS分区Windows识别不了。

#5

帖子 onshoestring » 2014-10-15 10:49

Device Boot Start End Blocks Id System
/dev/sdb1 2048 3907024895 1953511424 83 Linux
可以用 fdisk或 gdisk命令中的t修改分区表中的system id,和文件系统没什么关系.
或许windwos不认识system id和文件系统不一致的情况.
头像
vickycq
帖子: 4507
注册时间: 2011-03-20 13:12
系统: Debian
来自: 山东省寿光县
联系:

Re: 晕了,Linux下创建的NTFS分区Windows识别不了。

#6

帖子 vickycq » 2014-10-15 21:30

4楼用gparted新格式化的u盘在Windows7中可以正常识别,用fdisk -l查看,system id为HPFS/NTFS/exFAT :em20

如下,/dev/sdb1为2T移动硬盘,system id == Linux
/dev/sdc1为u盘,system id == HPFS/NTFS/exFAT

都是用gparted格式化为NTFS的。

代码: 全选

Disk /dev/sdb: 2000.4 GB, 2000398934016 bytes
14 heads, 12 sectors/track, 23256126 cylinders, total 3907029168 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0xd981045a

   Device Boot      Start         End      Blocks   Id  System
/dev/sdb1            2048  3907024895  1953511424   83  Linux

Disk /dev/sdc: 4026 MB, 4026531840 bytes
136 heads, 30 sectors/track, 1927 cylinders, total 7864320 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x0003d8ba

   Device Boot      Start         End      Blocks   Id  System
/dev/sdc1            2048     7864319     3931136    7  HPFS/NTFS/exFAT
:em20 :em20
Debian 中文论坛 - forums.debiancn.org
欢迎所有 Debian GNU/Linux 用户
头像
vickycq
帖子: 4507
注册时间: 2011-03-20 13:12
系统: Debian
来自: 山东省寿光县
联系:

Re: 晕了,Linux下创建的NTFS分区Windows识别不了。

#7

帖子 vickycq » 2014-10-15 21:36

进展

此帖中描述的情况和俺遇到的一样:
http://bbs.chinaunix.net/thread-1940051-1-1.html

俺的移动硬盘第一次上电运行也是在Linux下,虽然格式化为NTFS,system id仍然为83 Linux。结果就是在Windows下无法挂载。

虽然可以手动改为7 HPFS/NTFS/exFAT,但硬盘中已有大量重要数据,不敢轻易动分区表。 :em20
Debian 中文论坛 - forums.debiancn.org
欢迎所有 Debian GNU/Linux 用户
poloshiao
论坛版主
帖子: 18279
注册时间: 2009-08-04 16:33

Re: 晕了,Linux下创建的NTFS分区Windows识别不了。

#8

帖子 poloshiao » 2014-10-16 8:03

硬盘中已有大量重要数据
1. 建議
先掛載/備存 起來
2. 暫時 在 Windows 重新分割/格式化
3. 再把數據回存
備存/回存 在 windows / ubuntu 都行
4. 這樣可能會比較快
5. 有些問題 要找原因 不容易 縱使找得出來原因 可能虛耗許多時間
6. 如果你決定採取上面行動 下面的問題 不一定需要回答
mkntfs -Q -v -L "" /dev/sdb1
類似案例
http://forums.fedoraforum.org/showthread.php?t=239767
Partitions created with mkfs.ntfs not recognised by Windows 7
GParted 0.18.0 --enable-libparted-dmraid --enable-online-resize
什麼原因需要啟動這兩個參數
e2002
帖子: 246
注册时间: 2006-06-07 18:15

Re: 晕了,Linux下创建的NTFS分区Windows识别不了。

#9

帖子 e2002 » 2019-10-20 10:51

我遇到这个问题已经很久了,至少有好几年,存在至今。
昨天拿了个新的ssd用kubuntu分的ntfs区(临时用,在等下月初的wd的移动硬盘发货),结果在导入大量数据之后才想起这个问题,在windows10中果然无法识别,但在linux和macos中读写却一点问题都没有。目前没什么办法,不敢乱动分区表,先对付用了,反正我也只是接在这台mbp13tb2016上用,虚拟机内的win10能访问到就得了。
handyw
帖子: 352
注册时间: 2007-06-11 13:06

Re: 晕了,Linux下创建的NTFS分区Windows识别不了。

#10

帖子 handyw » 2019-10-20 14:27

我也遇到过,后来在win7里格式化NTFS
zhangjint5
帖子: 304
注册时间: 2011-01-02 12:31

Re: 晕了,Linux下创建的NTFS分区Windows识别不了。

#11

帖子 zhangjint5 » 2023-03-26 7:23

Win要认分区id和文件系统,MBR 架构的磁盘 NTFS 分区 id为7
而Linux 自只认文件系统就可以挂载
改个分区id都怕就不要玩了
sxgpic
帖子: 98
注册时间: 2013-12-13 6:57

Re: 晕了,Linux下创建的NTFS分区Windows识别不了。

#12

帖子 sxgpic » 2023-04-09 23:12

论坛不活跃,人们都开始考古了。
回复