Jump to content

Read GPT hard disk on Windows XP


Cixert

Recommended Posts

Personally I recommend NOT using GPT on XP at all.

Either learn to live with internal hard disks smaller than 2.2 TB or find an external USB that exposes 4kb sized sectors and compatible with MBR up to 17 TB or so.

Now, finding these external USB enclosures might be unfortunately really tricky as producers/sellers are unlikely to highlight how their controller works.

On this thread where the matter is discussed on superuser there are a couple hints, but nothing "exact" on the make/models:

https://superuser.com/questions/1271871/4k-emulation-sata-usb-controllers

There is yet another option, use (if you can find one) a native 4K drive (that does not do "512e" emulation), I believe they exist  only in largish sizes (8 TB and more) but really cannot say.

Remember that 4kb drives won't normally be bootable with MBR.

jaclaz

Link to comment
Share on other sites

  • 2 weeks later...

On 7/12/2023 at 1:06 PM, jaclaz said:

There is yet another option, use (if you can find one) a native 4K drive (that does not do "512e" emulation), I believe they exist  only in largish sizes (8 TB and more) but really cannot say.

I was looking up this one as I don't want larger disks with helium

 https://www.westerndigital.com/products/internal-drives/wd-blue-desktop-sata-hdd#WD80EAZZ

 

Link to comment
Share on other sites

On 7/12/2023 at 1:06 PM, jaclaz said:

Either learn to live with internal hard disks smaller than 2.2 TB or find an external USB that exposes 4kb sized sectors and compatible with MBR up to 17 TB or so.

I prefer the reliability of SATA ports and internal power supply over any USB external enclosure

anyway M$ stated that the 4K disks would not support anything under W8 :wacko:

https://learn.microsoft.com/en-us/troubleshoot/windows-server/backup-and-storage/support-policy-4k-sector-hard-drives

Link to comment
Share on other sites

3 minutes ago, jaclaz said:

Sure, what did you expect?

I expected nothing because I am not familiar with disks technology as you are.

are you sure that XP would be able to recognize any 4kn disk and create large partitions up to 17+ TB

 

Link to comment
Share on other sites

21 minutes ago, Milkinis said:

I expected nothing because I am not familiar with disks technology as you are.

are you sure that XP would be able to recognize any 4kn disk and create large partitions up to 17+ TB

 

Of course cannot say for sure, what we know is that XP has had no issues with external USB disks exposing 4k sectors, which for all it matters are the same as 4kn.

The 17 TB limit is a theoretical one, the capacity of the field in the MBR is that one, and you are actually using it already when you reach the 2.2TB "limit", so that in itself poses no issues.

The NTFS in itself (like *any* filesystem) should depend not on sector size, but rather on cluster size, and XP is included in the OS's where NTFS volumes up to 256 TB are supported:

https://support.microsoft.com/en-us/topic/default-cluster-size-for-ntfs-fat-and-exfat-9772e6f1-e31a-00d7-e18f-73169155af95

this does not mean that a number of MS (or third party) tools might have issues with largish volumes.

A good example (unrelated) is the mentioned issue with "new" alignment and Disk Manager incompatibility with logical volumes inside Extended partition (that BTW MS never publicized, let alone fix).

My "Sure, what did you expect?" note was more "general" and related to the fact that both XP and 7 (and Vista) are not supported anyway anymore and MS has spent time in the last few years to remove references to them and re-writing articles/Knowledge base/etc. to exclude them from lists of supported OS.

jaclaz

Link to comment
Share on other sites

1 hour ago, jaclaz said:

what we know is that XP has had no issues with external USB disks exposing 4k sectors, which for all it matters are the same as 4kn.

what happens if the external enclosure goes bad ?

can you restore your disk data without the enclosure onto W7 ?

can you swap the enclosure out or does it have a unique ID for each disk ?

Edited by Milkinis
Link to comment
Share on other sites

As always, it depends.

Proprietary enclosures (those disks "born USB" such as many WD and Seagate external units) may have some form of identifying the disk in it (the real issue may come out if you use the provided encryption feature) but, also, some have "non-standard" disks inside (without an actual SATA connector) and in case of problems you would need to trace and solder to the PCB, example:

https://blog.acelab.eu.com/pc-3000-hdd-how-to-solder-a-sata-adapter-to-the-usb-western-digital-drive.html

Third party enclosures/bridges are simpler as the disk itself is a standard one, and there is no "disk ID matching) so it should work the same in another enclosures (that behaves the same, i.e. either performs or does not perform a sector size translation, and this may happen only when the disk is over a given size or not work at all), here is a related report:

https://goughlui.com/2013/10/02/experiment-usb-to-sata-bridge-chips-and-2tb-drives/ 

There are in any case (though the el-cheapo ones might have size limitations) SATA to USB converters, normally used in data recovery or for temporary access to a disk to be later mounted internal, that work with *any* disk.

Just like enclosures, it is extremely difficult if not impossible to know (as the manufacturers do not include this info) how a given bridge will behave.

Some chips can be re-programmed using their manufacturer tool (some of them are available for Asmedia chips, as an example) but as well the manufacturer of the bridge or enclosure won't say which chip is used in their product.

If the disk is functional, you can always recover the data at file level, even if there is a sector size mismatch, using suitable tools, whether it would be possible to directly restore it may as well depend on a number of factors, hard to say.

jaclaz

Link to comment
Share on other sites

14 hours ago, jaclaz said:

Third party enclosures/bridges are simpler as the disk itself is a standard one, and there is no "disk ID matching so it should work the same in another enclosures

I don't like the propietary enclosures because of this and one doesn't actually know what is buying, SMR or CMR disks.

if the disk fails you may not get it back working with a different disk

you have to send it in thousands of Km away to the service center.

the 3rd party enclosure sounds like a better alternative if it can convert any disk into 4Kn but we are stuck on the same problem mentioned before

if the enclosure ever goes bad you have to find a identical one that coud restore the partition 

 

Link to comment
Share on other sites

1 hour ago, Milkinis said:

if the enclosure ever goes bad you have to find a identical one that coud restore the partition

Well, no, you need a similar one (in the sense of one that makes the same translation or no translation) if you want to use the disk normally, but data recovery is possible no matter if the sector size exposed is different, by using *any* other enclosure or connecting the disk drive directly to a computer.

Of course in this case you need another suitable disk to copy to, but this is standard procedure when recovering data.

jaclaz

Link to comment
Share on other sites

On 6/27/2023 at 4:19 AM, realisty said:

@Cixert did the win2003 drivers worked for you?

 

readed here: https://www.vogons.org/viewtopic.php?f=8&t=79711&start=20

about file corruption using 2k3 drivers.. anyone can confirm this??

 

I have tried the following 2 methods with external USB drives and have had no problems if these steps are followed and the indicated errors are avoided.

READ GTP HARD DRIVES ON WINDOWS XP

It can be done with any of the following methods.

A - with the "Windows 2003" drivers
B - with the "Paragon GPT Loader" driver


A - with the 2003 Windows drivers

Step 1 - From another operating system copy the Windows 2003 drivers replacing the current XP.

"Partmgr.sys" copy in the folder:
Windows \ System32 \ dllcache

"Disk.sys" and "Partmgr.sys" copy in the folder:
Windows \ System32 \ drivers

Any version of Windows 2003 drivers works both v. 5.2.3790.3959 (W2003 SP2) as v. 5.2.3790.1830 (W2003 SP1).
Both files have = number of bytes, only change version number.
The files are valid for all languages (at least work with XP English & XP Spanish).
Check that there are no more old versions in other folders such as \ Windows \ Lastgoods

If these files are sought with the Windows XP search engine these do not appear, since these are special system files.
Use an alternative search engine like "File Finder."

Note:
To copy them from the operating system itself, both files would have to be glued very quickly in both folders and then update the folder view checking that version 5.2 has been fixed
Ideally, paste the files on the hard drive from another operating system, since we will not be able to perform step 2 from Windows XP itself.

You can also try to deactivate Windows file protection.
-To disable the Windows files protection, activate sfcdisable in the registry:
HKLM \ SOFTWARE \ Microsoft \ Windows NT \ CurrentVersion \ Winlogon
SFCDisable = 1


Restart Windows and copy the files.

-Then deactivate it again:
SFCdisable = 0
And restart Windows.


Step 2 - Copy the "disk.sys" file of Windows 2003 inside the "sp3.cab" file that is in \ windows \ driver cache \ i386 with the Windows CAB file packaging" tool called "iexpress.exe" (Windows Cabinet) that is in \ Windows \ System32

Extract sp3.CAB:
- Extract the files that sp3.CAB contains with Winrar or with 7zip or with IExpress (slower) in a folder whose name does not match "SP3" the name of the file to be created, since if it does not let it create it when packaging.

- Paste the "Disk.Sys" file of Windows 2003 replacing the XP file.

Packing sp3.CAB:
- Go to start+run and write "iexpress".

- In the menu choose «Create New Self Extraction Directive File» and press next.

- In the menu choose «Create Compressed Files Only (Active X Installs)» and press next.

- Add the files contained in the "ADD" folder.

- To record the file to choose the location to examine, but the file.CAB is created in
C: \ Documents and Settings \ User

- Choose a name of 8 characters.

Note:
If the same file name is chosen as the folder enters the folder instead of saving it.

- Mark allow compressed files to have a long name in "Store Files Using Long File Name Inside Package", leaving the other white box (Create Fixed Sice Cab File (s)).

- Optionally save compilation.

Note:
If the same name as the folder has been chosen, the .CAB file is created in
C:\Documents and Settings\user
because the location is automatically blanked.

Note:
If step 2 is not done, then Windows XP stops booting when a new USB stick is installed.
Since to install its drivers the original version of "disk.sys" of Windows XP is restored.
There is no problem if you install the pen with the Windows XP drivers from before step 1 and then recopy the Windows 2003 drivers. At least until you reinsert a new pen.
https://msfn.org/board/topic/183225-windows-xp-does-not-start-after-entering-kingston-usb-pencil/#comment-1210203



Step 3 - Star Windows XP

The first time Windows XP starts with the new files takes several minutes.
Be patient and wait.

Note:
Tested in Windows 2000, this gives blue screenshot with MBR discs, you can't access the Boot Device.



B - With Paragon GPT Loader driver
The loose Paragon GPT Loader driver is no longer offered on the Paragon website and is virtually impossible to find on the Internet. Now only the Paragon HFS for Win v.10.5.0.95 variant is offered, which also contains the Paragon GPT Loader driver inside, so we can use it to read GPT disks on Windows XP.
This variant for reading MAC-formatted drives includes the Paragon GPT 10.5.0.95 driver, while the Paragon GPT Loader 10.5.0.95 version has the 8.0.1.0 driver with many bugs.

If Windows XP is installed on a FAT 32 partition before rebooting you need to modify the registry...

Error correction:
Any version of the Paragon GPT Loader driver that we install, be it the original, the HFS or the modified fork, contains an error that will cause us to suffer a blue screen when rebooting the system, at least if we have FAT32 on the Windows XP boot partition . This is because the driver file name "gpt_loader.sys" contains 10 characters instead of 8.
It is installed in the \WINDOWS\system32\drivers directory.
To solve it, we will modify the Windows registry as soon as we install it and before restarting the system.
Go to start + run, type "regedit" and search
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\gpt_loader

Here change the value of ImagePath which says:
system32\DRIVERS\gpt_loader.sys
by
system32\DRIVERS\GPT_LO~1.SYS
and then reboot.
Problem solved.

Fork version
In addition to the official version there is a fork that fixes the bugs of Paragon GPT 8.0.1.0.
But, as far as I've checked, currently it's better to install Paragon HFS for Win v.10.5.0.95 which contains the 10.5.0.95 driver.
The current fork version is 8.0.1.2
On their website they do not give the full version 8.0.1.2 (despite the fact that it exists on other websites). And they do legally give the patches to correct the official version 8.0.1.0
http://hardwarefetish.com/777-paragon-gpt-loader-3
(on this website there are only patches, there is no full version)

How to install the fork
1 - Unzip
2 - Right click on the .inf file
3 - Install
To uninstall the fork we need to install some official version and then uninstall it.

Edited by Cixert
Link to comment
Share on other sites

How to edit GPT partitions from Windows XP

In 2016 I tested the partition programs that work correctly with MBR disks larger than 2TB in Windows XP, ruling out the others.

The ones that worked were the following:
-Windows XP Disk Manager
(although it possibly leaves the partitions misaligned).
-Acronis Disk Director
(although it possibly leaves the partitions misaligned).
-EaseUS Partition Master.
-Eassos DiskGenius
-Macrorit Disk Partition Expert
-MiniTool Partition Wizard.

In 2022 I have checked from the above that they work correctly with GPT disks in Windows XP.
In Windows 10 they all work but in Windows XP they don't. It only works correctly:
-Windows XP Disk Manager
(although it possibly leaves the partitions misaligned).
-Acronis Disk Director 12.5.0.163 (year 2019)
(although it possibly leaves the partitions misaligned).

The following programs detect the GPT disk and its capacity but neither read the partitions nor allow them to work with the disk:
-EaseUS Partition Master 16.8 (year 2022)
-MiniTool Partition Wizard 12.5 (year 2021)

In addition, the following program does not read the partitions but it does let you work with the disk, although it is possibly unable to complete the operations and leaves the disk defective:
-Macrorit Disk Partition Expert 6.1.2 Pro (year 2022)

The following program does detect the partitions, but when performing a disk operation it is unable to complete it and leaves the disk defective:
-Eassos DiskGenius 5.4.6.1432 (year 2022)

Therefore, only the following programs allow working with GPT partitions in Windows XP:
-Windows XP Disk Manager.
-Acronis Disk Director 12.5.0.163
(year 2019)

Being able to work alternatively with any of the programs mentioned in this post in its WinPE boot disk version (I have not tried it).


PROCEDURE TO CONVERT MBR DISK TO GPT
1- With Acronis Disk Director 12.5.0.163 right click on the disk and press "Convert to GPT".
The procedure is not reversible if there are more than 4 partitions.

2- To create the partitions you must also use Acronis Disk Director 12.5.0.163 or alternatively the Windows XP Disk Manager. Both programs give the same result, they set the first partition to sector 63.

3- Format NTFS partitions with Acronis Disk Director 12.5.0.163
I don't remember right now if it works on GPT "guiformat.exe" aka Fat 32 Format to format large FAT32 partitions. I think there should be no problem.
http://www.ridgecrop.demon.co.uk/guiformat.htm

4- I don't know of any program with which you could align GPT partitions directly from Windows XP, so you would have to align them from another operating system or with a boot disk from one of the programs mentioned earlier in this post.


PROCEDURE TO CONVERT GPT DISK TO MBR
It requires disk erasing, although it could work without data loss if there are a maximum of 4 primary partitions and no extended ones.

The best procedure to convert GPT to MBR and partition the disk is:
1- With Acronis Disk Director 12.5.0.163 convert the disk to MBR or use the "Clean up disk" option which will leave the disk uninitialized. The options are seen with a right click on the disk (not on the partitions).

2- Create MBR partitions with MiniTool Partition Wizard 10.3

3- Format large NTFS partitions with MiniTool Partition Wizard 10.3 or if they are created in FAT32 with "guiformat.exe" aka Fat 32 Format
http://www.ridgecrop.demon.co.uk/guiformat.htm

4- Align partitions with MiniTool Partition Wizard 10.3
(versions higher than 10.3 produce various problems when formatting partitions)

Note:
After aligning the partitions, I understand that there is no problem of losing extended partitions when using the Disk Manager of higher versions of Windows, even though they have been created from the Windows XP Disk Manager.
If it could happen the other way around, that after aligning the partitions there are problems with the Windows XP Disk Manager.

Edited by Cixert
Link to comment
Share on other sites

10 hours ago, Cixert said:

Note:

After aligning the partitions, I understand that there is no problem of losing extended partitions when using the Disk Manager of higher versions of Windows, even though they have been created from the Windows XP Disk Manager.
If it could happen the other way around, that after aligning the partitions there are problems with the Windows XP Disk Manager.

Yes :yes:, to be more accurate what "may" happen is the following:

1) in XP the "standard alignment is on cylinder/head, so primary partitions will always start on a CHS s=1 h=0 or 1 and end on a CHS s=63 h=max (usually 254, in a nx255x63 geometry)
2) this applies also to logical volumes inside extended, the net result is that each volume will have an offset of 63 from the relative Extended MBR
3) in Vista and later (over a certain - small - size of the device) an alignment of 1 MB (2048x512=1048576) is instead used, and it also applies to the offset to the relative Extended MBR of logical volumes inside extended
4) If you create the Extended partition and logical volumes in XP or however with 63 sector alignment you won't have any issue with both XP and later windows Disk Manager
5) but if you create the Extended partition and logical volumes under a later OS or however with 1 MB alignment, the XP Disk Manager may decide, when performing even an unrelated operation to disk (as an example changing the bootable status of a primary partition), to check/re-calculate the offset of the logical volume from the relative Extended MBR, and silently delete the logical volume entry in the EMBR:

https://web.archive.org/web/20160308045741/http://www.dcr.net/~w-clayton/Vista/DisappearingPartitions/DisappearingPartitions.htm

See also:

http://reboot.pro/index.php?showtopic=9897

The logical volumes are still there (of course) but they are not anymore addressed in the EMBR chain, it is possible to recover them by finding their extents and re-writing proper entries for them, but it needs some time and dedication..

jaclaz

 

Link to comment
Share on other sites

2 hours ago, jaclaz said:

4) If you create the Extended partition and logical volumes in XP or however with 63 sector alignment you won't have any issue with both XP and later windows Disk Manager

When can there be a problem when using the Windows NT6 Disk Manager or higher if the partitions are created from Windows XP Disk Manager?
Thanks

Link to comment
Share on other sites

5 minutes ago, Cixert said:

When can there be a problem when using the Windows NT6 Disk Manager or higher if the partitions are created from Windows XP Disk Manager?
Thanks

I don't understand.

There aren't (AFAIK) any problems, the (serious) bug is in XP (and presumably earlier) Disk Manager.

We can put it this way:

1) when the XP disk manager was created/programmed the ONLY convention for disk aligment in use (according to the usual MS arrogant paradigm of "all is mine") was to head/cylinder, for *some reason* the tool was coded with the assumption that it would only deal with disks partitioned and formatted along that convention (and by MS tools)

2) when the Vista disk manager was created/programmed they introduced the new MB convention, but since 99.99% of the systems already in use had the old one, presumably they tested the new disk manager with both the existing common situation of millions of disks and with the new convention they had just introduced

Historically, third party tools for DOS or Windows tended (understandably) to work similar to the way the Microsoft tools worked, so I wouldn't be surprised that this (or that) third party tool prior to Vista may have some issues with the new 1 MB alignment.

Please note how whilst the "old" cylinder/head alignment was originated (in DOS) by some peculiarities in the actual way the (early) mechanical hard disks worked (that by the time XP came out weren't needed at all, as hard disk had changed their architecture already since years), the 1 MB is a completely arbitrary one, what may or may not make a difference is alignment to a multiple of sector size (so 4096 bytes for newer disks), any multiple would have done as well, and even if they had went ahead, and have only NTFS (which is inherently aligned, while FAT is not unless especially created so, impossible to do with MS own tools only) the cluster size (to make sure to have an integer number of clusters in a volume and no slack space) could have been 64KB (the max cluster size MS uses in its filesystems) or - at the most and leaving some provisions for larger clusters in the future - 128KB. .

jaclaz

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...