Nomen Posted January 27 Author Posted January 27 Just answer 1 question. If a mechanical HDD actually does have a physical sector size of 512 bytes, and the installed NTFS-based operating system has a 4-kb cluster size, then is it possible to have a "mis-aligned" formatting? Somewhere around 2002 - 2003 your typical PC hard drive was 80 gb. Did these drives have 512 byte sector size or 4k sector size? (ok they had 512 byte sectors, 4k sectors didn't really start until 2010). When you were installing Win 2k or XP back in 2002-2003, was sector-alignment a thing? Was 2k / XP aware of (and perform) sector alignment during installation? I stumbled across these page, I haven't read it all yet, seems relavent: https://learn.microsoft.com/en-us/troubleshoot/windows-server/backup-and-storage/support-policy-4k-sector-hard-drives https://www.seagate.com/ca/en/blog/advanced-format-4k-sector-hard-drives-master-ti/
Rod Steel Posted January 30 Posted January 30 (edited) On 1/27/2025 at 5:19 PM, Nomen said: When you were installing Win 2k or XP back in 2002-2003, was sector-alignment a thing? Was 2k / XP aware of (and perform) sector alignment during installation? Before 2010 change for 4K size of physical cluster consumer HDD was ALWAYS from the begging of they mass production in early 1980's - a 512 bytes drives. Meaning they physical sector size was 512 bytes. Thus why all windows OS before Vista formatted them with correct alignment by default. It was the only alignment. On 1/27/2025 at 5:19 PM, Nomen said: If a mechanical HDD actually does have a physical sector size of 512 bytes, and the installed NTFS-based operating system has a 4-kb cluster size, then is it possible to have a "mis-aligned" formatting? If you talk about windows OS - apparently NO. As i understand you are confused why NTFS use 4K CLUSTER size as standard even where sectors were 512 bytes? Am i right? The explanation that i read is next: As far as i understand the 4K cluster size in NTFS system before 2010 year 4K FORMAT era was because CPU native minimal memory page size is 4K. The 4K memory page was standard first in late 1970's with VAX and ОS VMS. In x86 CPU world support of 4K memory page was introduced in 1985 with Intel 386. So as i remember the explanation why NTFS use standard cluster size of 4K - it is minimal memory page size of modern popular CPU's. Thus why later, when better efficiency of storage of information was in discussion, 4K as native physical sector size was obvious choice. Edited January 30 by Rod Steel 2
Rod Steel Posted January 30 Posted January 30 (edited) On 1/22/2025 at 4:54 PM, Nomen said: In the Minitool Partition Wizard, if I select "Align Partition" in the left-hand column option list, a window opens that says "The specified partition does not need to change partitions alignment. It is already aligned." The disk alignment test (diskat-gui.exe) still says "Wrong alignment detected. Volume C is not aligned". Well, after all, diskat-gui.exe is old program, more then decade old. And your SSD is new. So maybe it's detect wrong. So better use AS SSD test program - it is far more informative and is new, because it's constantly been updated. Please test your SSD with this program and make and upload here screenshot of AS SSD benchmark result. Here is a picture describing what is what in AS SSD interface: Edited January 30 by Rod Steel 2
Nomen Posted February 1 Author Posted February 1 On 1/30/2025 at 6:03 AM, Rod Steel said: As i understand you are confused why NTFS use 4K CLUSTER size as standard even where sectors were 512 bytes? Am i right? No, I am not confused about that. I keep making the point (or asking the question) how can a drive that actually does have 512-byte physical sector size possibly ever be mis-aligned when the cluster size is 4kb. My point being, if the logical cluster size of the file system is equal to or larger than the physical sector size, then it is not possible to have mis-alignment. If a mechanical HDD has internally a 4kb sector size, BUT IT REPORTS TO THE OS THAT THE SECTOR SIZE IS 512 BYTES, then of course that is a problem and you can easily have mis-alignment because of the lying the HDD is doing in it's reporting. If the HDD reports a 4kb sector size, and the OS is going to create a volume with 4kb cluster size, then will that not lead by defacto to an ALIGNED volume? If a hard drive really does have 4kb sectors, and it reports to Windows that the sector size is 4kb, will Windows still try to access and format the drive AS IF IT HAD 512 byte sectors? Is that even possible? Are older versions of Windows (like 98, NT4, 2K, XP) capable or incapable of "understanding" a sector size other than 512 bytes?
user57 Posted February 2 Posted February 2 1 way to solve this problem would be the firmware doing that on the harddrive you often do not have greater files then 4 GB each chuck but xp can handle file sizes greater then 4 GB / per file the overlappend structure is solving that 32 bit problem it use 32 bit dwords combined as "low" and "high" part https://learn.microsoft.com/en-us/windows/win32/api/minwinbase/ns-minwinbase-overlapped a other thing is the rounding number if you fill 4 kb checks with a file of like 2 mb . something you can fill these 4 kb chucks with 512 kb checks (4 times) only the the very end of the file it can be that you only need 1-3 times the 512 chuck then the last chuck of the 4 kb chuck is just not used that actually dont fall into weight because its only a small piece what would be thinkable that it can exactly handle 2 TB instead of 4 GB is that a DWORD (32 bit) is involved, a idea would be the counter but figuring that out somebody can do ... there would be ways to get this out of a code microsoft published some of their codes - as ms did with their dosbox or their wrk a problem with a big project that dont have a project file is rather that it are many of files if there is no project file where you can scroll around and find the right code in this case it looks to me that the files have to be searched for their names then the structures and functions can be isolated depending how much they are splittered up but the ntoskrnl or windows is a big piece, to pull together all the functions, structs, defs and others parts of code is some work ... google has 300 000 pages for example but then you could actually not only look into the functions you also could compile the outdated ntoskrnl for example from server 2003 the code itself might actually be simple but my editor could actually not just open 300 k files, rather you need a program like visual studio, but vs wants a project file i dont think it just can open all the files at once (all tabs opened) then it probaly has to make a search function what search all the files via filecontrol (and guess what vs has a such thing)
Dave-H Posted February 2 Posted February 2 On 1/23/2025 at 11:16 PM, AstroSkipper said: Eassos DiskGenius (formerly PartitionGuru) has been my favourite partition manager for years. As far as I know, the last XP compatible version is 5.5.0.1488 from 2023 and works very well under Windows XP. Many, many features, and you get very detailed information about your drives. It is even able to create images of partitions. In any case, I no longer allow any other partition tools to access my hard drives. And I tried a lot of them in the past. I'm using DiskGenius 5.6.1.1580 on XP and it works fine. It is however one of those programs that won't install on XP, you have to use the portable version. 1
AstroSkipper Posted February 2 Posted February 2 4 hours ago, Dave-H said: I'm using DiskGenius 5.6.1.1580 on XP and it works fine. It is however one of those programs that won't install on XP, you have to use the portable version. Thanks for the hint! Since the version 5.2, I have been using the portable version exclusively. The installer version stopped working as you also noticed. I have now installed DiskGenius 5.6.1.1580 under Windows XP. However, on my old computer, this version needs much longer for starting as the previous versions. I am not sure if it is really fully compatible. I have to observe this version over a longer time. 5
Dave-H Posted February 2 Posted February 2 It starts pretty quickly on my machine, but my hardware may be more powerful. The only issue I've seen is that when I back up a disk to an image file, there is a bit of a delay in it actually starting the operation, and in the Windows System log there's a string of information entries which say "Timed out sending notification of target device change to window of DiskGenius". The number of entries varies, and they seem to mainly be when the operation is initiated, but the operation does still complete successfully. I did query this with the developers, and their answer was "Windows XP system is too old, which may have caused this warning message due to its lack of certain features." I suppose that's fair comment! It is indeed a great program, it amazes me just how much the free version can do. Cheers, Dave.
Cixert Posted February 3 Posted February 3 (edited) On 1/27/2025 at 4:19 PM, Nomen said: Just answer 1 question. If a mechanical HDD actually does have a physical sector size of 512 bytes, and the installed NTFS-based operating system has a 4-kb cluster size, then is it possible to have a "mis-aligned" formatting? If the first partition starts at sector 63: -Logical sector 512 bytes and physical 512 bytes: 63x512= 32556 bytes 32556:512= 63. Partition starts aligned with the physical sector. -Logical sector 512 bytes and physical 4096 bytes: 63x512 = 32556 bytes 32556:4096 = 7.9482421875. Partition starts misaligned with physical sector. (4096:7.9482421875 = 515.3340705246345 bytes) If the first partition starts in sector 64: -Logical sector 512 bytes and physical 4096 bytes: 64x512 = 32768 bytes 32768:4096 = 8. Partition starts aligned with the physical sector. (4096:8 = 512 bytes) If the hard disk has a 512 bytes logical and physical sector, the partition with a 4096 bytes cluster is always aligned at its start, but it must also be aligned at its end. Otherwise, the first partition will not have all its clusters of size 4096 and the second partition will start out misaligned in relation to the cluster size of the first partition. For this reason, It must be indicated that the partition size is compatible with a 4 KiB cluster, as I mentioned before. Therefore, there are 2 alignments types, one to the physical sector and another to the cluster size. On a hard disk with a 512 byte physical sector, it may not be very important to align the partition to the cluster size, but on a hard disk with a 4096 byte physical sector, it is essential that the partition cluster size be a multiple of the physical sector so that the second partition does not start out misaligned in relation to the physical sector. Edited February 3 by Cixert 1
Cixert Posted February 4 Posted February 4 On 1/30/2025 at 3:14 PM, Rod Steel said: Well, after all, diskat-gui.exe is old program, more then decade old. And your SSD is new. So maybe it's detect wrong. So better use AS SSD test program - it is far more informative and is new, because it's constantly been updated. Please test your SSD with this program and make and upload here screenshot of AS SSD benchmark result. Here is a picture describing what is what in AS SSD interface: Interesting program: I have never found a reliable way to tell if the disks are aligned. I think the most reliable way is to perform a manual calculation. Right now I am confused with the value given in your screenshot: It says 104424 K OK What does this value mean, the partition size? Running As SSD Benchmark on my partition with XP says 67,804,191 K in red, as if it is not aligned, but I do not have that partition size. Disk Genius says that the partition measures 20,545,276 KiB which results in an effectively unaligned size for a 4096 cluster since it is not a multiple of 8 . On my Kingston A400 SSD hard drive I have resized the partitions a year ago, I do not remember which program I used. I'm running multiple applications now and I get conflicting values for my third primary FAT32 partition running Windows XP, some applications say my partition is aligned and others that it's not. -fsutil fsinfo sectorinfo <letter unit> command run from Windows 10 says: Device alignment: Aligned (0x000) Partition alignment on device: Aligned (0x000) -MiniTool partition Wizard says: Okay MiniTool Partition Wizard needs to align a partition. -Disk Alignment Test: This program is indeed out of date. In the past I've already found that it says some AF disks are not AF and disks that are AF are AF. In theory, if I'm not mistaken my SSD is not AF since it has 512 byte physical sectors. Am I wrong? The program says that it is AF and that I need to align the partition with XP.
Rod Steel Posted February 4 Posted February 4 1 hour ago, Cixert said: Right now I am confused with the value given in your screenshot: It says 104424 K OK What does this value mean, the partition size? I have no idea what this number means. It's a mystery to me. If Disk Alignment Test, MiniTool partition Wizard and AS SSD all says your partition is not aligned, then it is not aligned. You should align partition using MiniTool partition Wizard option. 1 hour ago, Cixert said: if I'm not mistaken my SSD is not AF since it has 512 byte physical sectors. Am I wrong? I don't know any SATA3 SSD that is not 4K. As far as i know, they all are AF 4K. Where did you get this idea that Kingston A400 have 512 byte physical sectors? This is ridiculous idea. Just align your SSD with MiniTool partition Wizard, dude. And then show here screenshots of AS SSD BENCHMARKING BEFORE AND AFTER alignment performed. 2
D.Draker Posted February 5 Posted February 5 15 hours ago, Rod Steel said: And then show here screenshots of AS SSD BENCHMARKING BEFORE AND AFTER alignment performed. How much improvement we are to expect? Approximate percentage?
Cixert Posted February 6 Posted February 6 On 2/4/2025 at 11:46 PM, Rod Steel said: I have no idea what this number means. It's a mystery to me. If Disk Alignment Test, MiniTool partition Wizard and AS SSD all says your partition is not aligned, then it is not aligned. You should align partition using MiniTool partition Wizard option. I don't know any SATA3 SSD that is not 4K. As far as i know, they all are AF 4K. Where did you get this idea that Kingston A400 have 512 byte physical sectors? This is ridiculous idea. Just align your SSD with MiniTool partition Wizard, dude. And then show here screenshots of AS SSD BENCHMARKING BEFORE AND AFTER alignment performed. These are the values for SDD Kingston A400 connected to SATA port, reported by various tools such as HDDscan & Eassos DiskGenius running on Windows 10 and the command "fsutil fsinfo sectorinfo": Sector Size: 512 Physical Sector Size: 512 However DiskAlignment Test says it is an AF disk and report: Logical block size: 512 bytes Physical block size: 4096 bytes I remember that when I first installed it a few years ago I had problems with partitions allocated to sector 63 that reduced its performance. It's curious the error rate of all the tools. So what I'm looking at is the AS SSD Benchmark Aliggment value in green or red ending in K, which corresponds to the size in KiB of the sectors prior to the indicated partition. That is, if it starts in sector 2048, it gives a value of 1024 K for disks with a logical sector of 512 bytes. That is, the value of the partition offset.
Rod Steel Posted February 6 Posted February 6 On 2/5/2025 at 5:03 AM, D.Draker said: How much improvement we are to expect? Approximate percentage? I don't know. It's depends also of what controller in that SSD, (A400 can have different controllers, depend of month and year of production) of what operation system installed - this information are not given to us by Cixert. If that SSD was all years misaligned and run on non TRIM OS like Vista, or XP, or 2000, then it's numbers maybe ridiculously low. But if internal technology of idle state garbage collection is active there, the penalty might be not so big at all. 3 hours ago, Cixert said: So what I'm looking at is the AS SSD Benchmark Aliggment value Well i hope you will give us screenshots of AS SSD. I want to see screenshots. 1
Cixert Posted February 8 Posted February 8 (edited) On 2/6/2025 at 8:48 PM, Rod Steel said: I don't know. It's depends also of what controller in that SSD, (A400 can have different controllers, depend of month and year of production) of what operation system installed - this information are not given to us by Cixert. If that SSD was all years misaligned and run on non TRIM OS like Vista, or XP, or 2000, then it's numbers maybe ridiculously low. But if internal technology of idle state garbage collection is active there, the penalty might be not so big at all. Well i hope you will give us screenshots of AS SSD. I want to see screenshots. The disk is aligned to sector 2048 (1024 K for logical sector 512 bytes) I understand that "pciide - bad" in red is because it is in IDE mode. Right now I have the system performing several operations and I cannot do tests, but the speed with the disk aligned usually ranges between 200 and 500 MB/s depending on whether TRIM is performed or not. In XP I have not noticed an increase in performance by doing TRIM with Solid State Doctor 3.0.3.2 (SSD Tools) but I have seen it by doing TRIM with SSD Tweaker Pro 4.0.1 . Edited February 8 by Cixert
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now