Jump to content

[HOWTO] Boot Macs with Intel Chipset in AHCI Win7 Vista XP Linux


  • Please log in to reply
405 replies to this topic

#21
MacAddictG4

MacAddictG4

    InsanelyMac Protégé

  • Just Joined
  • Pip
  • 3 posts
Awesome, that got it! Thanks for the help.

I'm attaching the drivers I used to initially force the AHCI drivers on the controller in XP in case anyone else was having trouble finding them.

Now just need to setup PowerDVD for HD-DVDs and BluRays... ;)

Attached Files



#22
ludacrisvp

ludacrisvp

    InsanelyMac Sage

  • Members
  • PipPipPipPipPip
  • 374 posts
  • Gender:Male
  • Location:USA
Glad I could help you out.
Good luck with HD-DVD and Blu Ray drives, I haven't decided if they are worth the money to buy a drive yet.
I have a PS3 so I can view the HD movies with that drive.

#23
Infrared

Infrared

    InsanelyMac Protégé

  • Members
  • Pip
  • 6 posts
Working very nicely for me, thanks ;)

What I'm thinking about now is a way of simplifying the method
so that less technically inclined people can take advantage of it.

Ideally:

(1) Can be done entirely within Windows
(2) Does not require a linux CD/DVD
(3) Uses as few external tools as possible
(4) Is simple enough to be done very quickly

P.S.

I did it a slightly different way. I had a disk with only Windows
on it (1 partition). I shrank the Windows partition and put GRUB
on a separate FAT partition after that, leaving the MBR intact.
Then I made that second partition active. If I want to boot
without AHCI enabled, I merely make the first partition active
within Windows and reboot.

Note: I nearly wrecked my OS X partition. I got a little careless and
assumed hd0 would be the drive in bay 0. It was not. When I
rebooted OS X was not present in the boot menu. I think the culprit
may have been the 'makeactive' command in 'menu.lst'. I removed
that as it wasn't necessary anyway.

Thanks again!

#24
dancinghenrys

dancinghenrys

    InsanelyMac Protégé

  • Just Joined
  • Pip
  • 1 posts

Well I finally got around to figuring this out and here is how to do it.

The following will enable you to use all 6 SATA ports on the Mac Pro Early 2008
It might enable AHCI on other Mac platforms, however I have none to test with.
There was mention of a MacBook Pro user enabling AHCI for faster drive access in Windows on the OnMac forum.

This will let you add your Blu Ray or DVD SATA drives to your Windows install without losing one of your hard drive bay Sata ports.
This will increase your data transfer speeds in Windows from the 100mb speed of the legacy mode to the native 1.5gbps or 3.0gbps of your SATA drive.

I give credit to pipomolo42 for figuring out that it can be done.
And for the Modified Stage1 file for the GRUB boot loader.

It was done on the OnMac Forums in the middle of 2007 in an attempt to enable RAID 5 in Windows.
However it wasn't easy for the casual user or power user to get done with out having major headaches.

Here are the links to the required files that will be needed.

Download and install rEFIt from inside OS X

Windows XP/Vista x86/x64 Intel Matrix Storage Manager Drivers - Direct from Intel Website

Ubuntu Live 8.04.1 AMD64/EM64T Desktop Version - Download from your nearest location, make sure to choose the desktop version for the 64 bit based systems, this is a CD based version and will therefore fit on a CD-R.

The attachment "boot.zip" contains the Modified Stage1, Stage2 and Menu.lst that are needed for the GRUB installation to work properly on the Mac Pro.
----------------------------------------------------------------------
There are several methods that you can use to setup your system.
I will go through Vista and XP for those that are already installed.
It is possible to install fresh versions of the OS by loading the install disc
through grub and providing the drivers for the AHCI controller via USB
for Vista or slipstreamed in XP or Vista.

1. Load Live CD
- Run Partition Editor
- Create a small FAT32 Partition at the beginning of the drive
- I chose to make a 100mb partition and formatted it to FAT32
- This re-sized and moved my XP partition down the drive by 100mb - this took about 45 mins

2a. Reboot into XP (if using Vista skip this step and use step 2b)
- Force the installation of the AHCI mode driver over the Legacy driver
- Open device manager
- Under IDE / ATA section open properties for the "Intel 631xESB/6321ESB Ultra ATA Storage Controller - 2680"
- Update the driver for 2680 with one labeled 2681 (ESB2 SATA AHCI Controller)
- You will need to uncheck the box that limits you to only known supported drivers for your hardware
- Once installed it will require a restart
- Attempting to restart into XP after this will leave you with a BSOD and instant reboot, this is caused because XP is loading the AHCI driver and it is failing to load because the hardware is still in legacy mode.

2b. Vista only
- Run Regedit
- Navigate to "HKLM\System\CurrentControlSet\Services\msahci"
- edit the "Start" key and change the value from what it is to "0"
- this will tell Vista to check for AHCI on next boot and install the AHCI driver if it is in AHCI mode

3. Load the Live CD again
- Copy the provided stage1, stage2, menu.lst to the following location on the 100mb partition
/boot/grub/
- Time to install GRUB bootloader

4. Open Terminal - enter following commands

sudo grub --device-map=/dev/null
- This will tell GRUB to ignore the built in device map of grub and that you will define a new one.
device (hd0) /dev/sda
- This maps your first hard drive as the device "hd0" in grub - keep in mind that GRUB counts up from 0
- grub will echo the command to confirm it was accepted.
find /boot/grub/stage1
- This will echo the location of the stage1 file - ex: (hd0,2)
-This would translate to hard disk 1 partition 3 for normal people
- You will use the (hdX,Y) for the next step
root (hd0,2)
- This tells grub where to obtain the stage1, stage2, menu.lst files from
setup (hd0)
- installs grub bootloader to MBR of first hard drive in system
- it will echo if the installation has succeeded or had errors
quit
- to quit grub
exit
- to close terminal

5. Restart and remove Live CD

6. From rEFIt Menu choose boot Linux from HD (the Penguin icon)

7. It will load Grub then show a boot menu for
- Windows XP in AHCI Mode
and
- Windows Vista in AHCI Mode

8. Take it from there and enjoy having 6 Sata ports that have the proper performance with NCQ enabled

--------------------------------------------------------
You may need to edit the "menu.lst" file for the appropriate locations of the operating systems on your machine.

On my system I am using an IDE drive for my XP install and that is also where grub is installed to.
I have 4 hard drives installed 1 IDE, 3 SATA.
I have 1 OS installed on each of their own physical drive.
On your system you might not be using /dev/sda because that is most likely going to be your Mac OSX drive
Chances are you will use /dev/sdb for the second sata bay in your case.




Edit reason:
Swapped this post to beginning with the 4th post to have the HOWTO be the beginning for the topic.

For some reason this topic will not notify me via email about replies so if I don't respond to questions right away that is most likely the reason.
I do however check back often.


I'm SO confused, sorry, I'm completely new at command-line stuff on Windows. What is Live CD and how do I load it? I'm trying to boot Vista-32 with AHCI on an Early 2008 Mac Pro with Boot Camp so that my SATA port-connected LG GGW-H20L Internal blu-ray drive will show up in Vista, and I can't seem to understand you're directions because I'm kinda stupid at this stuff! Is Live CD something that came with Vista installation kit, because if so, I'll need a burned copy because I no longer have any disks.

-Chris

#25
ludacrisvp

ludacrisvp

    InsanelyMac Sage

  • Members
  • PipPipPipPipPip
  • 374 posts
  • Gender:Male
  • Location:USA

I'm SO confused, sorry, I'm completely new at command-line stuff on Windows. What is Live CD and how do I load it? I'm trying to boot Vista-32 with AHCI on an Early 2008 Mac Pro with Boot Camp so that my SATA port-connected LG GGW-H20L Internal blu-ray drive will show up in Vista, and I can't seem to understand you're directions because I'm kinda stupid at this stuff! Is Live CD something that came with Vista installation kit, because if so, I'll need a burned copy because I no longer have any disks.

-Chris


Ok,
The Live CD is not something you would get with Vista. It is what you will burn after you download the live cd image of Linux.
Once you download it and burn it then you will boot from it.

All the command-line stuff will be done inside of Linux (from the Live CD) which is very similar to the BSD inside of OSX.

In Windows Vista to get it ready to boot in AHCI you can at any time before doing anything with Linux Live CD open
- Run Regedit.exe
- Navigate to "HKLocalMachine\System\CurrentControlSet\Services\msahci"
- edit the "Start" key and change the value from what it is to "0"

You only have to change this once, Vista will "probe" for AHCI mode at boot each time you boot and once you boot in that mode then it will be ready and install the needed drivers.

Working very nicely for me, thanks ;)

What I'm thinking about now is a way of simplifying the method
so that less technically inclined people can take advantage of it.

Ideally:

(1) Can be done entirely within Windows
(2) Does not require a linux CD/DVD
(3) Uses as few external tools as possible
(4) Is simple enough to be done very quickly


I would love to do that and it would be a great help for people.
I would have to figure out how to do it exactly, the makers of the emulated BIOS Vista activation crack are able to do it so maybe if I can get some help from that area I might be able to get it going.

#26
chipster21

chipster21

    InsanelyMac Protégé

  • Just Joined
  • Pip
  • 3 posts
  • Location:Italy
Hi there,
first of all, sorry for my English, I'm Italian, so please be patient.
I'm trying to follow "ludacrisvp" tip by creating the grub partition but, I'm having trouble on third step "find /boot/grub/stage1", grub is returning this error "Error 15 no file found". Could you please help?.

My config is :
Mac Pro Early 2008 2 Xeon 2.8 Ghz & 10GB Ram, nvidia 8800GT
Bay 1 - 1TB for Time Machine
Bay 2 & 3 Raid 0 for my primary OSX & Data
Bay 4 (3 partitions) OSX (for testing), Vista Ultimate 64 bit and Windows
Data

P.S. I'm new to the Linux staff
BTW, I'm using Ubuntu 8.10 64Bit

Thanks in advance

Ciao

#27
chipster21

chipster21

    InsanelyMac Protégé

  • Just Joined
  • Pip
  • 3 posts
  • Location:Italy

Hi there,
first of all, sorry for my English, I'm Italian, so please be patient.
I'm trying to follow "ludacrisvp" tip by creating the grub partition but, I'm having trouble on third step "find /boot/grub/stage1", grub is returning this error "Error 15 no file found". Could you please help?.

My config is :
Mac Pro Early 2008 2 Xeon 2.8 Ghz & 10GB Ram, nvidia 8800GT
Bay 1 - 1TB for Time Machine
Bay 2 & 3 Raid 0 for my primary OSX & Data
Bay 4 (3 partitions) OSX (for testing), Vista Ultimate 64 bit and Windows
Data

P.S. I'm new to the Linux staff
BTW, I'm using Ubuntu 8.10 64Bit

Thanks in advance

Ciao


I fixed it.... Thanks anyway

Ciao

#28
gibbsj

gibbsj

    InsanelyMac Protégé

  • Just Joined
  • Pip
  • 3 posts
I'm having trouble on third step "find /boot/grub/stage1", grub is returning this error "Error 15 no file found". Could you please help?.


I cant get it to work. I have a 35 mb partition with the folder /boot/grub -- all the files are in there.. like the stage1

#29
chipster21

chipster21

    InsanelyMac Protégé

  • Just Joined
  • Pip
  • 3 posts
  • Location:Italy

I'm having trouble on third step "find /boot/grub/stage1", grub is returning this error "Error 15 no file found". Could you please help?.
I cant get it to work. I have a 35 mb partition with the folder /boot/grub -- all the files are in there.. like the stage1


Just be sure that the grub partition is the first one

Ciao

#30
sebhag

sebhag

    InsanelyMac Protégé

  • Members
  • Pip
  • 45 posts
Big thanks to ludacrisvp!

Did this a couple of month ago, but didn't have time to post till now...

Everything's working great now, but i did have some major problems along the way. All in all it took me three days and i completely screwed up my xp partition even though i had an Acronis image and successfully restored in the past.

I can't remember all the details, but first thing that went wrong was the repartitioning process with gparted. I thought i save some time by just adding a little partition at the end so it wouldn't have to move all the data. But for some reason gparted still took over an hour and screwed up my xp install. After several hours trying to restore XP i gave up, removed the bootcamp partition and started all over. Since bootcamp creates a dummy 200meg partition between OSX and Windows anyway i just ended up using that and formatted as ext2 so it wouldn't show up later. Forced drivers in XP, installed rEFIt and grub, booted Windows in AHCI and installed drivers properly.

Along the way, i also attempted installing grub on a memory stick with the purpose of just booting from the memory stick if i want AHCI which would then point to the partition on the SATA drive, but for some reason it didn't work - can't remember.

In the end i also removed rEFIt as i didn't really see why i would need it, but that might just be with my configuration. Set grub timeout to zero, xp partition as active and windows as startup disk. This was done on a quad-core Mac Pro (pre 2008). Windows with AHCI boots now by default and you only see grub flashing up briefly. If i want OSX i just use bootcamp loader.

The LG super multi is happy and I haven't had a single problem with BD-R or BD-RE. Enable BD-RE FastWrite in ImgBurn to get twice the speed. :soldiers:

Once again thanks - InsanelyMac is the daddy!

#31
ludacrisvp

ludacrisvp

    InsanelyMac Sage

  • Members
  • PipPipPipPipPip
  • 374 posts
  • Gender:Male
  • Location:USA
Thanks, it is nice to see that I have made some peoples lives easier by allowing them to use the hardware they paid for to its real capability.

rEFIt may not be 100% needed but it does make it easier in the beginning so you don't always have to hold the option key when you are booting back and forth between devices. Also it makes it easier for those who have many partitions to choose the right one to boot from. Before I had rEFIt all non Mac disks just showed as windows disks, regardless of it being linux or windows.

I decided not to use the 200mb partition that apple makes to keep the drive formatted to proper guid partitioning because you never know when apple might decide that they want to use that for what it was made for.

@sebhag - I am thinking of getting a Blu-Ray drive soon, what specific model LG do you have and would you recommend it or a different drive?
I too wasn't able to boot from a USB flash drive now that I think more about it, nor was I able to use the Super Grub Disc, this is why I chose the Live CD for Ubuntu.

@gibbsj - Have you tried starting from the beginning again, it is very easy to miss a step and then it just doesn't work.

#32
sebhag

sebhag

    InsanelyMac Protégé

  • Members
  • Pip
  • 45 posts
Here's the drive spec:

Posted Image

I love it, although there's a slightly faster Sony or Panasonic, but they cost considerably more. I picked up my LG for 150 and BD-R's take under half an hour, single layer that is.

Re 200meg partition, apparently it's there for no particular reason. Well ok, not quite correct - as far as i understand the EFI system partition is supposed to be used for bootloaders and other EFI tools but OSX doesn't make any use of it. Vista might - not sure, but will find out soon. :unsure: If Apple would only update to UEFI 2.1...

#33
TallCoolOne

TallCoolOne

    InsanelyMac Protégé

  • Just Joined
  • Pip
  • 3 posts
Thanks for all this info, I finally got AHCI working in my Vista partition after many tries. I was trying with a GPT partition scheme drive and was not able to get it working, anytime i added the grub partition my windows would not boot anymore. Finally I tried with MBR and everything worked!...well almost everything...

Now I have a different problem, my new blu-ray drive (LG BH08LS20) shows up now in Device Manager after getting AHCI working, but has a little exclamation next to it, and in the device status says "This device cannot start. (Code 10)". I searched around and found others with this error having various solutions like removing iTunes, deleting some LowerFilters and UpperFilters from a key in the registry, removing the device from device manager and resetting, etc...but nothing seems to fix it for me. I'm at a loss for what to do now, anyone have any ideas? I do have another DVD-R type device in the machine and that one works fine. I am running Vista Ultimate, and installed SP1 also hoping it would fix it, but nope..

thanks in advance..

#34
ludacrisvp

ludacrisvp

    InsanelyMac Sage

  • Members
  • PipPipPipPipPip
  • 374 posts
  • Gender:Male
  • Location:USA
I don't actually have a Blu-Ray drive in my Mac Pro (I ended up upgrading my laptop to have a blu-ray because I wanted portable blu-ray) but here are some suggestions, try the other ODD_SATA port or try your drive in another machine or another SATA Cable.
Make sure you have the latest Intel AHCI drivers installed (you should see a piece of software called "Intel Matrix Storage Manager" installed with those drivers) because the included with Vista ones really are horrible.

#35
macpionier

macpionier

    InsanelyMac Protégé

  • Just Joined
  • Pip
  • 1 posts
Hello ludacrisvp,

I have a question that is the direct opposite of the topic. B)

I take it that OSX natively use AHCI because the system profiler->S-ATA tells me something about ahci?

Is there any possibility to deactivate AHCI? I want to install an Solid State Disk and I`ve read a lot that disabling AHCI leads to a better performace using an SSD.

I know this is Windows world but I think it should be the same issue on a Mac. At least I want to give it a try and compare it with AHCI enabled.
How can I do this?

Perhaps you have a good idea?

#36
ludacrisvp

ludacrisvp

    InsanelyMac Sage

  • Members
  • PipPipPipPipPip
  • 374 posts
  • Gender:Male
  • Location:USA
Yes, OS X uses AHCI natively.
My best guess would be to use a non-modified grub bootloader (or another legacy loader like Lilo) and boot your machine into that loader then load OS X from that loader, in theory that would keep the system in compatibility mode while booting OS X.
Those in the OSx86 world may be of some help for you because you would most likely need modified kext files that would give you support for non AHCI version of your chipset. What Mac are you using a SSD in?

#37
TallCoolOne

TallCoolOne

    InsanelyMac Protégé

  • Just Joined
  • Pip
  • 3 posts

Make sure you have the latest Intel AHCI drivers installed (you should see a piece of software called "Intel Matrix Storage Manager" installed with those drivers) because the included with Vista ones really are horrible.


Thanks ludacrisvp!!! This did it. I had installed the drivers from the InfInst.zip from your third post, but not the Intel AHCI ones because your directions said to skip that step if using Vista. Maybe update the steps for Vista to mention to make sure to install those drivers also on Vista after getting into AHCI mode. Thanks again for all your help!

#38
TallCoolOne

TallCoolOne

    InsanelyMac Protégé

  • Just Joined
  • Pip
  • 3 posts
Ok so after I got all excited that it now works and I can watch blurays on my mac, I booted back into OS X and tried to start my Windows partition via VMware only to find this no longer works now. It boots into the grub bootloader but just says "GRUB " in the top left and freezes. Anyone know if it's possible to be able to use a Windows partition setup with grub for AHCI in VMware also? I don't need VMware to load the gurb bootloader in this case since it already uses AHCI, but it insists on booting into the grub partition.

thanks.

#39
sebhag

sebhag

    InsanelyMac Protégé

  • Members
  • Pip
  • 45 posts

Ok so after I got all excited that it now works and I can watch blurays on my mac, I booted back into OS X and tried to start my Windows partition via VMware only to find this no longer works now. It boots into the grub bootloader but just says "GRUB " in the top left and freezes. Anyone know if it's possible to be able to use a Windows partition setup with grub for AHCI in VMware also? I don't need VMware to load the gurb bootloader in this case since it already uses AHCI, but it insists on booting into the grub partition.

thanks.


Should be easy, I'm using a seperate partition for the grub bootloader so you can always skip it by booting from the partition with Vista installed using rEFIt. Same under VMWare, if you got grub on a seperate partition there shouldn't be an issue.

#40
thalar

thalar

    InsanelyMac Protégé

  • Just Joined
  • Pip
  • 1 posts
I am apparently missing something because I absolutely can not get grub to load. I have been working on this for the past 4 days following ludacrisvp's instructions as well as some suggestions by others with no success. My setup is as follows:
Early 2008 Mac Pro with two internal hard drives. The drive in bay 1 is Mac OS X only with Mac OS X 10.5.6 and all the most recent updates. The drive in bay 2 is Vista 64-bit only.

The Vista drive has 2 partitions: the 200 MB partition that Bootcamp creates (/dev/sdb1) and the Vista NTFS partition (/dev/sdb2). I have managed to get the boot directory created on /dev/sdb1 with the grub directory inside that and the modified grub files inside that directory. My first command at the grub prompt is 'device (hd0) /dev/sdb' which just echoes the command. However, when I issue the command 'find /boot/grub/stage1' I receive 'Error 15: File not found'. If I proceed with the root command 'root (hd0,0)' the command is echoed. I then enter 'setup (hd0)' and receive "Error 17: Cannot mount selected partition'. I receive this error even if I have manually mounted the /dev/sdb1 partition using Terminal.

Can anyone, please, tell me what I am doing wrong? I am using the 64-bit version of 8.04.2 of Ubuntu. The /dev/sdb1 partition is FAT32 but it does not mount automatically when I boot using the Ubuntu CD. I have to mount it in Terminal and I had to copy the boot directory to it using the 'sudo cp' command in Terminal as well. I don't know if this behavior is normal or not.

I would greatly appreciate any help.

Thanks!





2 user(s) are reading this topic

0 members, 2 guests, 0 anonymous users

© 2014 InsanelyMac  |   News  |   Forum  |   Downloads  |   OSx86 Wiki  |   Mac Netbook  |   PHP hosting by CatN  |   Designed by Ed Gain  |   Logo by irfan  |   Privacy Policy