Wednesday 14 March 2012

IBM ThinkPad X40 Compact Flash hard drive

The IBM ThinkPad X40 has proven to be a stalwart system. Both compact and with reasonable specification it can handle most programming tasks I throw at it. However, of late it has been suffering the slow painful stuttering process of its hard disk aging.

After doing some research it seems there are a number of people who have decided to replace the hard drive with a Compact Flash card. This is something I've been interested in trying for a while.

Components

ThinkWiki provides the starting point for the research along with various blogs. The following components have been selected for the upgrade.

PA-CF18H Adapter - Initially I had selected the Addonics adapter mentioned on the wiki, but it was only available from the US. Instead I found that Amazon UK sold a similar adapter by Sintech. It turns out that this is a product intended to be a replacement for 1.8" drives and is sized to fit into the same space and there was plenty of evidence to indicate that it worked successfully.
Transcend 16 GB 400x TS16GCF400 - This was a much more tricky a choice to make. Importantly for a Windows based Compact Flash installation, it must report to be a fixed drive. All Transcend cards do this automatically which was why I selected this card. Then it was a balance between speed and cost. There is the 600x series, but at almost double the price that put it outside my budget.
Sintech 2.5" to 3.5" adapter ST4044A - This component is not needed for the drive replacement, but it was essential in order for me to get an operating system onto the Compact Flash card. The X40 has no CD Drive so another system will be used to install and test the drive before replacing the laptop hard drive.

Proceedure

The following steps cover the replacement:

Format & Install

I connected the Compact Flash card and adapter to my main PC and ran through the standard Windows XP installation. The BIOS and Windows recognised the card as a hard disk and I was able to start the installation.

Note: I noticed that formatting the drive as NTFS seemed to cause the installation to take a very long time complete. Instead I reverted to FAT32 and found that the process was much faster. It seems the Compact Flash card is better suited to FAT32.

Configure Boot Loader

Once installation is complete, I encountered the somewhat dreaded "NTLDR is Missing" error message which occurs just after the BIOS completes its POST and tries to load the Operating System. Googling for this brings up various results until I found this page.

The reason the NTLDR error appears is because NTLDR looks at the drive geometry of the Compact Flash card, and finds it does not match what it was expecting. To solve this problem I followed the instructions from the article above and replaced the NTLDR boot loader with GRUB4DOS.

In order to complete this, I connected the Compact Flash card to a PC with a Card Reader. This will allow us access to the drive, to put the new bootloader onto it.

  1. Connect the Compact Flash drive a PC using a card reader.
  2. Download MBR Installer
  3. Download GRUB4DOS
  4. Using the Disk Management control to work out which drive the Compact Flash drive is. This is via Start -> Run -> "diskmgmt.msc" then look for the disk number of the Compact Flash drive.
  5. Extracted the grubinst executable from the "grubinst_1.0.1_bin_win.zip" and then from the command line, executed grubinst --pause (hd2) (where hd2 was the Compact Flash card drive number). This completed successfully.
  6. Copy "grldr" from the "grub4dos-0.4.4.zip" to the root folder of the Compact Flash card.
  7. Created a file called "menu.lst" in the root folder of the Compact Flash drive with the contents "chainloader /ntldr".

After these modifications, the Compact Flash drive would successfully boot and allow me to finish off the Windows installation and subsequent configuration.

Installation Into Laptop

The installation of the adapter is fairly straight forward. From the underside of the laptop, the hard drive is located on the left hand side towards the front.

The hard drive has a cover which is clipped onto the drive. This cover is screwed onto the chassis. Remove the marked screw and then carefully use the cover to extract the hard drive from the chassis. The hard drive slides out quite smoothly.

The hard drive screw mounted onto a tray which we will use to hold the Compact Flash adapter as the PA-CF18H fits exactly into the tray and this gives us a bit of extra purchase when slotting it back into the chassis. On my system there was some glue holding the hard drive into the tray, this comes apart with a little persuasion.

Place the adapter into the tray, and reinsert the tray into the chassis. Carefully guide the pins of the adapter into the corresponding connector being careful not to bend any pins. The tray should fit neatly inside the chassis.

Reattach the cover

References

I found the following blogs very useful:

The following articles were helpful:

Adapter Manufacturers:

No comments:

Post a Comment