What is the difference between IDE and AHCI

What is the difference between IDE and AHCIRecently we got some new machines at work which were very not too different in their hardware configuration from what we already have. The only difference was a setting in the BIOS about SATA emulation being set to either AHCI or IDE (the default was AHCI). It turned out that our computer image blue screened on the new machines unless we changed the BIOS setting to IDE emulation for SATA. The fix was quick and easy, but this did bring up the question What is the difference between IDE and AHCI emulations on a SATA drive and if there was an advantage or disadvantage of choosing one over the other.

As you might be knowing SATA (Serial ATA) has superseded the IDE (Integrated Drive Electronics) as a standard for computer hard drives. The connector looks quite different for SATA on the mother board as well as on the hard drive. SATA and SATA2 drives boast much higher data transfer speeds than IDE (up to 300 Mb / sec). A picture of a SATA connector on the motherboard is shown above.

AHCI (Advanced Host Controller Interface):

AHCI (Advanced Host Controller Interface) is one of the modes SATA drives and controllers can operate in, the other mode for SATA controllers is IDE. AHCI does not provide any speed benefits over IDE, but does have other advantages. 

Prime Advantages of AHCI over IDE:

- Allows for Native Command Queuing (see note about this feature below)

- Allows hot swapping feature. Unlike IDE drives which need to be hooked up and connected before the machine powers on, AHCI capable SATA drives can be hot plugged and unplugged after the machine has booted up and they become available to the operating system. Think of them as a USB thumb drive being plugged and unplugged

What is Native Command Queuing:

Native Command Queuing or NCQ is a great feature of AHCI capable controllers. NCQ checks for requests for data coming to the controller and arranges them such that they are grouped together so that requested data locations are physically located together, reducing seek times.

Most controllers offer backwards compatibility to IDE emulation for SATA hard drives. Windows 7 operating system uses AHCI natively and does not need any drivers to be installed for using the AHCI through the BIOS. For down level operating systems such as Windows XP, you will have to install the Host Controller Interface (AHCI) Drivers from the computer manufacturer

So, in our case, we syspreped a new image that had the Mass Storage Drivers from the vendor (HP) included so that it can support the AHCI mode. Once you install the drivers, you have to reboot, change the SATA emulation in BIOS back to AHCI and restart the machine. Upon logging on, XP will come up with "found new hardware" wizard and automatically install the drivers and ask for another reboot.

If you encounter blue screens on a brand new machine you got, the AHCI setting in BIOS is worth while to investigate!