Question Aligning windows XP on a samsung 850 pro

Jul 30, 2024
4
0
10
Hello! I'm currently building a retro PC that will have 2 SSDs one with XP and the other with Windows 7. I'd like to make sure that the XP SSD is alligned properly. I know very little about this other than a few sites have recommend using windows 7 to partition because it does 2048 byte blocks. My question is should I instead use a windows 10 or even windows 11 machine to do the partition instead so it's 1024 bytes? Would that be better?

Also, I will have 4 SSD's in total. 1 for XP, 1 for 7, and the other 2 will be for both. Would it be possible to RAID0 the remaining drives to use as a gaming drive D: for BOTH operating system? Or would that cause an issue? Should I instead use the extra drives individually for each operating system? (so XP would get 1 extra drive all for itself, and 7 its own extra drive)

Thank for the help! I hope these quesitons don't come off as extremely noob, I'm knowledgable to a point, it's been a VERY long time since i've messed with windows XP so I want to make sure I do everything right to not mess up the drives. I'm aware that I need to find a specific version of Samsung Magician for windows XP though i'm not sure which, in order to have TRIIM working on it. I will also have Windows 7 to fall back on to trim the drives when they are not in use. Does anyone have any extra input on how I should configure the SSD for windows XP so it doesn't destroy the drive? Thanks!
 

ImWolf

Honorable
Mar 18, 2019
198
22
10,615
Your post does not mention the first thing you will need, which would be drivers supplied by the MB manufacturer so that XP will recognize the SSD drives. If you can obtain the drivers, you would then need to supply them during setup either via a 3.5 disk, or by creating a slipstream CD or thumb drive. Since these required drivers aren't always available, a lot of people will install a much newer OS first, and then setup XP as a VM.

It's been many years, but as I recall there are options during the setup of XP Pro that will allow you to create your partitions (you only need one?) and specify the FAU size during formatting. You can set these (File Allocation Units) as small as 512 bytes, but in today's world I don't think there's much advantage to having such tiny FAU's any more. I believe the default is 4096K.
 
If the SSD is SATA or PATA you should not need any extra drivers. The easiest way to set the offset is to format the drive(s) using a modern OS. Otherwise it can be done with diskpart using the command line from your XP install media, get to a C: prompt, type diskpart and go from there. On diskpart itself, I cannot remember all the commands but there is a plethora of guides online. In fact, you can probably find some step by step guides for SSD setup for XP from that era as this was definitely one of the top questions people had. XP default offset was (iirc) 63KB requiring the read/write to 2 pages, Vista and later the offset went to 4096KB. As long as your offset is divisible by (again...iirc) 4KB you are fine. I used to set mine to 1024KB.
 
Jul 30, 2024
4
0
10
If the SSD is SATA or PATA you should not need any extra drivers. The easiest way to set the offset is to format the drive(s) using a modern OS. Otherwise it can be done with diskpart using the command line from your XP install media, get to a C: prompt, type diskpart and go from there. On diskpart itself, I cannot remember all the commands but there is a plethora of guides online. In fact, you can probably find some step by step guides for SSD setup for XP from that era as this was definitely one of the top questions people had. XP default offset was (iirc) 63KB requiring the read/write to 2 pages, Vista and later the offset went to 4096KB. As long as your offset is divisible by (again...iirc) 4KB you are fine. I used to set mine to 1024KB.

Thank you! The board uses SATA 6gb/s intel controllers as well as a few 3rd party ports. Is there a benefit to making the partition with windows 7 or windows 10/11 or are they both similar? I read in a previous post that Vista (and i'd assume 7) does 2048 byte blocks though i'm not sure if this is accurate. From my observation it appears windows 10/11 uses 1024 byes.
If you can obtain the drivers, you would then need to supply them during setup either via a 3.5 disk, or by creating a slipstream CD or thumb drive.

I will have the motherboard drivers ready during install on a separate folder of the boot drive, I don't plan on letting this machine go onto the internet as XP is highly insecure by now so I'll have to get everything manually, lots of work but hopefully worth it for the retro experience!
 
Thank you! The board uses SATA 6gb/s intel controllers as well as a few 3rd party ports. Is there a benefit to making the partition with windows 7 or windows 10/11 or are they both similar? I read in a previous post that Vista (and i'd assume 7) does 2048 byte blocks though i'm not sure if this is accurate. From my observation it appears windows 10/11 uses 1024 byes.


I will have the motherboard drivers ready during install on a separate folder of the boot drive, I don't plan on letting this machine go onto the internet as XP is highly insecure by now so I'll have to get everything manually, lots of work but hopefully worth it for the retro experience!
Use either really. And you are on track. Have everything you think you may need on hand on a flash drive. There was an article recently, can't remember if it was on Tom's or somewhere else, that showed even allowing ACCESS to the internet on a fresh, fully patched XP install to become infested with dozens of different malware. So resist any urges you may have. Otherwise have fun with it, hopefully it goes smoothly.
 

ImWolf

Honorable
Mar 18, 2019
198
22
10,615
"I will have the motherboard drivers ready during install on a separate folder of the boot drive"

This is a confusing statement. What boot drive? Boot to which OS? Your OP sounded like you wanted to install XP, while partitioning and formatting an SSD drive during the setup?

And with all due respect to CelicaGT, I don't agree with his opinion on the drivers, because I've been through this process a few times. Windows XP came out before Sata, Pata, or SSD drives existed. Microsoft did not supply drivers on the setup media that would detect drives invented in the future.

There is an F6 option you have to hit during setup process where you would need to supply 3rd party drivers. If you don't have them on either a floppy, or a slipstreamed medium, the setup will halt and you will see a message something like "No Fixed Disc Detected".
 
  • Like
Reactions: stuff and nonesense
"I will have the motherboard drivers ready during install on a separate folder of the boot drive"

This is a confusing statement. What boot drive? Boot to which OS? Your OP sounded like you wanted to install XP, while partitioning and formatting an SSD drive during the setup?

And with all due respect to CelicaGT, I don't agree with his opinion on the drivers, because I've been through this process a few times. Windows XP came out before Sata, Pata, or SSD drives existed. Microsoft did not supply drivers on the setup media that would detect drives invented in the future.

There is an F6 option you have to hit during setup process where you would need to supply 3rd party drivers. If you don't have them on either a floppy, or a slipstreamed medium, the setup will halt and you will see a message something like "No Fixed Disc Detected".
I believe -most- SATA devices are able to be accessed natively in the installer with some niche products being the exception, especially in the later revisions. Pre SP1 was a wild safari and I doubt that's what OP is installing (I sure hope not). The only boards I recall needing drivers for was VIA chipsets for AMD (3 in 1 driver), maybe Nforce as well? The rest I did natively. PATA (Or IDE, or straight ATA if you will) DEFINATELY existed before XP, Mid 80's I think? And XP doesn't care about the device, only its interface. SSD, HDD doesn't matter, that is the reason one needed to do the partition offset manually. The OS was agnostic and wrote to it like it was a magnetic disk. Regardless, OP should have the drivers on hand (they said as much), and I'm sure they can figure it out. Besides Tom's there's an entire internet out there with older guides to do this. In a low risk area such as this, the best way to learn is by trial and error.

Anyways, I'm happy to be wrong on this stuff, it WAS a long time ago and I may be remembering things selectively.
 
I do not recommend multiple boot using the same disk, now that disks are so cheap. Inevitably you will want to erase or change one of the OSes and you will either have to edit boot manager entries or the later installed OS will wipe out the boot manager used to select which OS. It's much better to use a separate disk for each OS and use the BIOS boot priority to decide which disk to boot from / will be C: so put XP and XP64 on separate disks.

Just install each OS with only one disk connected, and after installation you can plug back in all of the other disks so all data on every disk can be accessed by any OS, just with different drive letters for each. The problem is of course each OS uses a slightly different flavor of NTFS so for all XP disks used in multi-boot I recommend disabling the "dirty bit Autochk" which is the automatic chkdsk on boot when dirty bit is set, otherwise they will attempt to chkdsk any Win 7 or Win 10 drives and corrupt them irreparably.

In Win 9x it was possible to disable automatic chkdsk on boot when dirty bit is set, with just a tick box

In NT-based 2k and XP it is not, which is inconvenient because XP chkdsk will destroy the filesystem of 7 or 10 NTFS and of course those later OS cannot install to FAT32. Worse, simply rearranging drive letters by selecting a different drive to boot from in the BIOS is often enough to set the dirty bit.

So to permanently disable it in XP you can delete both instances of autochk.exe from the XP disk, from
Windows\ServicePackFiles\i386 and
Windows\System32
Autochk is what calls chkdsk on bootup so you will see a message "autochk program not found-skipping autocheck" if the dirty bit is set and the drive needs to be chkdsk-ed manually. Problem then is you cannot ever chkdsk C: while using it so the only way to do it (including if XP disk is so corrupt it cannot boot) is to boot to other OS to do the chkdsk there if you see this message.

Alternate solution is to exclude only the 7 or 10 disk from XP chkdsk using the command prompt from within XP:

chkntfs /x e: f: g:

for example is the command that tells XP autochk to always ignore dirty bit set on 7 or 10 disks E, F and G. What this does is set the
HKLM\SYSTEM\CurrentControlSet\Control\Session Manager key "BootExecute" to "autocheck autochk /k:EFG*"
If this setting gets corrupted you will also see the message "autochk program not found-skipping autocheck" so if you ever need to, reset it back to the default value "autocheck autochk" either manually or by using

chkntfs /d

I have to complain about the stupidity of Microsoft here allowing the fsutil to set a dirty bit (To set the dirty bit on drive C, syntax is: fsutil dirty set C:) but not to clear it. After all chkdsk doesn't always clear it either.



Note that none of this will actually prevent the dirty bit from being set in the first place--dual booting to XP will set the bit so when you next boot into 10 or 7, they will automatically run the chkdsk too which is annoying but OK--as that won't destroy the filesystem.
 
Jul 30, 2024
4
0
10
So if I install on separate disks, I don't have to worry about this dirty bit thing? OK I can avoid it altogether. That being said...do you guys have a recommendation for XP 32 or 64? If I have to choose one (I can always buy another SSD later I suppose) which do you recommend starting with?
 
No, the dirty bit thing is also a problem with separate disks, if you will ever have a Windows 7 or Windows 10 drive installed while booting to XP. If you only have XP disks then it won't be a problem. If you have a laptop using drive sleds where only one drive can be inserted in a time then it also obviously can't be a problem.

As previously pointed out, to ensure your not-512b disk is properly aligned in XP, use any modern Windows or Linux OS to partition and format it before you go installing XP. 9x and XP partition tools are designed for 512b sector and will align partitions on the 65th block rather than the correct 64th for 4k drives. This does not affect sequential transfer rates but misalignment greatly affects random and iops because each cluster then may overlap with two blocks. For SSD both blocks will also need to be block erased and rewritten too, slowing writes.

If you already have a disk that may have been partitioned using XP you can do a 4k alignment check by opening command prompt and pasting: wmic partition get Name, StartingOffset
divide the number for the SSD by 4,096. If there are no decimals in the result, the partition is aligned
If not, an alignment tool like the free MiniTool Partition Wizard can fix it (it's not too intuitive, rightclick partition and pick Align, then in the dropdown menu commit changes. Or rightclick disk and pick Align all partitions) by essentially resizing the partition almost a megabyte smaller to start at LBA 2048 (512b x 2048 is 1MB, which is exactly how Vista+ formats things). This involves moving all the data on the drive so lots of writes for a SSD.

Note that using Fat32 isn't a solution either because all Microsoft tools for that will misalign partitions on non-512b disks. That's right, even the Win 10 or Win 11 partitioning tools will misalign Fat32 partitions on non-512b disks.

If you want to run most XP programs or 16-bit stuff then choose 32-bit. If you have more than 4GB RAM installed and want to use that then only 64-bit can access it.