Friday, July 6, 2007

Installing Oracle 10g on an Intel-based MacBook Pro using Parallels

I was switching to a new client this month, so I decided to treat myself to a top-of-the-line 17" Apple MacBook Pro. I've seen a lot of co-workers at AOL walking around the building with the MBP and I was hit with Mac-envy.

After a few days...Although I still love the machine, my first week did not go smoothly.

My original goal was to install Oracle 10g, and eclipse to emulate the Unix development environment on my MacBook Pro. So I started by downloading Oracle 10g from the Oracle site itself:

Oracle Download Site

There is a link on this page for "Oracle Database 10g Release 1 (10.1.0.3) for Mac OS X Server". If you have an Intel-based MacBook Pro like me (Core Duo 2), THIS WILL NOT WORK! I spent hours working through the pre-install documentation over and over again to find out where I was doing wrong.... It turns out that Oracle 10g (as of v10.1.0.3 which was the latest version for OS X on Mac as of July 2007), does not work on Intel-based Macs!

So since I can't run 10g on Mac OS X natively -- I thought I'd use Apple's Boot Camp to run 10g under XP or Vista.

And knowing that the Core Duo 2 chips are 64-bit chips - I purchased a copy of Vista 64-bit Home Premium. That was the start of my second mistake.

Apple Boot Camp

Although Windows Vista 64-bit Home Premium was booting on my MacBook Pro, I had no networking support, no sound, and no ATI exhanced graphics support. After struggling with Boot Camp for another few hours, I discovered, that Boot Camp v1.3 (the latest as of July 2007) does not work with 64-bit Windows operating systems! Well, it actually does, but you won't have audio drivers, network drivers, camera, extended keyboard, or extended USB support.

After more research, I stumbled upon this link which describes how to install a Red-Hat clone using Parallels in Mac OS X in order to run Oracle 10g.

Install Oracle 10g on an Intel Mac

If I found this link first, I might have been willing to try it. But at this point, I was exhausted. So I took the easy route.

This is the solution I eventually settled upon:

  1. Install Apple Boot Camp (free). Be sure to the read the Boot Camp documentation, you will need a blank CD-R and a real installation disk of some variant of a 32-bit Windows operating system (XP, or Vista).


  2. Partition your drive via Boot Camp. I chose NTFS for my file-system.


  3. Install Windows XP via Boot Camp


  4. After the full XP installation is completed, you will need to run the Boot Camp CD that was burned by Boot Camp while in the fresh-Windows installation in order to install Windows drivers for all the MacBook Pro devices.


This all worked perfectly -- and now I could dual-boot my MacBook Pro and have a true Windows environment or true OS X environment.

Random Mac Tips:

  • Hold the "Option" key to choose which partition you want to use while booting.

  • Press the TrackPad while booting to eject the CD


Next I installed "Oracle Database 10g Release 2 (10.2.0.1.0) for Microsoft Windows" from the Oracle download page.

Oracle download page

Important Note! If you do not have a fixed IP address, you will need to install the Microsoft Loopback Adapter and choose a fixed IP address. Do this BEFORE installing Oracle, or else you will most likely have to remove and re-install Oracle.

KnowledgeBase article about installing the Microsoft Loopback Adapter

Now Oracle 10g should install without a problem.

Then, I decided to push my luck, and try out Parallels. Parallels gives me a virtual Windows machine within a running Mac OS X environment. There is a 15-day free trial available.

Parallels Desktop for Mac

Parallels installed flawlessly, and identified my BootCamp parition and created its own variant of the BootCamp launch configuration.

Once completed - Windows XP was running within a window on my Mac OS X desktop!

One last piece was missing though, the Mac could not communicate to Oracle within Parallels Desktop. By default, XP Home installs a Windows Firewall. What Parallels does is create two separate virtual machines running on the same MacBook Pro. So although they are on the same desktop and same machine, they cannot talk to each other because Windows has its own Firewall.

Visit the Windows Control Panel / Firewall Settings, and add Oracle-friendly-ports such as 1158, 1521, and 5560.

Now - within a single desktop environment - I can build applications in Java on OS X while accessing Oracle 10g on Windows.

No comments: