With the 8.0.1 update of ColdFusion, OS X 10.5 Leopard is natively supported. To install ColdFusion you simply download the 32-bit or 64-bit version of the OS X installer and walk through the installation screen. The steps I outlined below, getting a custom compiled version of the Apache 2.2.x connector are no longer necessary as CF8 ships with an appropriate connector.


I've had ColdFusion 8 running on OS X 10.5 (Leopard) and hooked to Apache 2.2.6 for a while now. However, two things have occurred that are prompting me to write this blog entry. First, I've gotten several questions on exactly how I got things working - even with the other blog entries that outline a similar process. Second, I ran into an odd issue Friday when configuring everything on my new work MacBook Pro.

This is a small part of an article I'm writing for the Fusion Authority Quarterly Update Volume 2 Issue 4, due out in February. The information is so important I felt it could not wait, and am publishing this with permission from Fusion Authority. In this blog post, I will discuss the installation issue and its resolution, and provide my consolidated, easy steps for getting ColdFusion 8 hooked to Apache 2.2.x on Leopard.

Friday's issue manifested itself during the installation of ColdFusion 8. If you choose to "hook" CF8 to Apache during the install process, to have CF8 start during system startup, or to install the multiserver configuration, the installer will prompt you to enter your OS X password. After entering my password, I received a message stating I could not install CF8 because it appeared I did not have the appropriate permissions. The installer went on to say it determined this by attempting to create a folder in /Library/StartupItems/.

To troubleshoot the issue I performed several tests. First, I entered an incorrect OS X password in the password and password confirm fields. The CF8 installer gave me the same message. That confirmed I was probably dealing with a permissions issue. To double-check, I entered the passwords in again - this time the correct ones - and still received the same message. At this point, I wanted to verify my OS X password by logging out of Leopard and back in again. Before doing that, I decided to change my password to something that didn't include special characters (like $$ signs), thinking these characters could be throwing off the installer commands. After logging out and back in again and trying the installer with my new password, I received the same error message. On a hunch, I decided to check the permissions of the native OS X CF8 installer file. Comparing the permissions of the file to another OS X machine showed a difference, "Staff" and "Everyone" had read only access on my work machine, while the machine that already had ColdFusion 8 installed showed read/write permissions for all users/groups. To change the permissions on my work machine, I clicked the lock icon in the bottom right corner of the File Info window. After giving Staff and Everyone read/write access, I was back in business and the ColdFusion installer worked. So why did this occur on my new machine and not others? It's probably because I dragged the CF8 installer file from a USB drive to my MacBook Pro. I haven't tested this, but I've read OS X handles file permissions differently, depending on whether you actually "copy" a file or drag it from place to place.

Now, for my steps on getting ColdFusion 8 installed and hooked to Apache on Leopard:

1. Download CF8 installer from http://www.adobe.com/go/trycoldfusion

2. Double-click the installer file to launch the wizard.

3. As you progress through the screens, be sure to select Multiserver Configuration (I always multi-instance CF).

4. On the Configure Web Server screen, select the option to configure a Web server. Select Apache in the drop-down.

For Configuration Directory type: "/private/etc/apache2"
NOTE: Other bloggers have mentioned typing "/etc/apache2" here. This is also fine as that directory is a symbolic link to the REAL directory /private/etc/apache2.

For Directory and file name of server binary type: "/usr/sbin/httpd"

For Directory and file name of server control script type: "/usr/sbin/apachectl"

Click Ok.

5. The installer will do its thing and then you'll get a message about successfully installing CF8 BUT that the Web server and/or Web site do not appear to be running. You're directed to start the Web server and then run the Configuration Wizard:

Just click Ok when you see the message above and move to the next step.

6. Download the recompiled, 64-bit Web server connector from Scott Pinkston:

7. Make sure Apache is stopped. In Terminal, navigate to the /usr/sbin directory and type "sudo apachectl stop"

8. Copy mod_jrun22.so from the zip you downloaded and paste it into the following directory:

9. Restart Apache. From /usr/bin in Terminal, type "sudo apachectl start &". The ampersand instructs OS X to start the Apache process in the background. This keeps the process from being attached to your Terminal session.

10. Stop all CF/JRun services (just in case they are running). From /Applications/JRun4/bin/ type "./jrun4 stop cfusion" and "./jrun4 stop admin" and "./jrun4 stop samples". Don't worry about the messages you get from typing the commands.

11. Open Activity Monitor (the OS X app) and look for any services called "jrun." If any are listed (be sure "All processes" is listed in the drop-down at the top of Activity Monitor), quit them by selecting them and pressing the Quit button, then the Force Quit button to confirm.

12. Start CF8 in Terminal: from /Applications/JRun4/bin type: "./jrun4 start cfusion &"

13. Go to your browser and visit http://localhost/CFIDE/administrator/index.cfm. Be sure and type the filename (index.cfm). You will be prompted to enter your CF Admin password, at which point CF will run through the configuration process and direct you to the CF Admin.

Now you can go back to Apache and set up Virtual Hosts or add "index.cfm" to the global DirectoryIndex directive.

For more Apache/CF goodness, check out Cutter's awesome series on setting up your development environment and look for my upcoming article in the Fusion Authority Quarterly Update.

Aaron West's Gravatar
About this post:

This entry was posted by Aaron West on January 14, 2008 at 8:00 AM. It was filed in the following categories: ColdFusion, Apache, Leopard. It has been viewed 27967 times and has 14 comments.

14 Responses to ColdFusion 8, Apache 2.2.x and OS X 10.5 (Leopard)

  1. Works perfectly to get the server up and running, but I've got a weird problem. When I add index.cfm to DirectoryIndex in the httpd.conf file, it doesn't seem to work. I can still access files directly, but if I leave the filename off, it downloads a .class file.

    Any ideas?

  2. That's odd. I've never run into the specific behavior you are describing. By default, index.cfm isn't served up if only a directory is requested, but after adding the template name to the DirectoryIndex directive it does. Are you running virtual hosts or anything? If so, you'll want to add the DirectoryIndex directive to any virtual host blocks as well.

  3. After a bit of Google-ing and some good old fashioned reckoning, I seem to have figured it out.

    I think the problem may be that I'm running 10.5 server on the machine. It's configured a bit differently.

    At the end of /etc/apache2/httpd.conf, there is a line that includes all files in the ./sites directory. In that directory, there is a configuration file created for each Virtual Host. Using a stock install, there is a file in the sites directory called 0000_any_80.conf (meaning accessed via any hostname/ip on port 80). Edit this file, and insert the "index.cfm" to the DirectoryIndex directive in this file.

    I think that my problem was I was adding it to a DirectoryIndex directive in the main httpd.conf file -- which was getting overridden by the included files.

    Hope that help anyone else who might be having this problem.

  4. Sorry, don't mean to multiple-comment, but I forgot one other step I took. I created a new .conf file in the sites directory called "handler.conf", and put this line in:

    AddHandler jrun-handler .cfm .cfml .cfc

  5. Glad you got it working. I figured it had something to do with your sites / virtual hosts not picking up the DirectoryIndex value from the main configuration file.

  6. Kay

    For me all works perfectly now, thanks

  7. I did not know CF could run on MAC

  8. When I try to install the 64-bit ColdFusion 8 on my Mac Pro, I get this error:

    The installer has found the following errors/warnings:
    Error: Unsupported Platform:
    This installer will only run on 64 bit mac-intel. PPC and 32 bit mac-intel are not supported. If this is a 64 bit mac-intel, make sure 64 bit JDK is the default JVM.
    Close this installer and restart installation using a 32 bit installer.

    I then went into Application/Utilities/Java/Java Preferences.app and tried both 64-bit versions of Java. I got the same error.

    Has anyone else encountered this and figured out how to install ColdFusion 8 in 64-bit mode?

  9. @Andrew - What version of OS X are you running? Just because my blog post discusses Leopard I don't want to assume you are running Leopard. ColdFusion 8 64-bit works on Leopard only. If you are running Leopard, then I must admit I've not seen your error before. Trying launching Console (/Applications/Utilities) to see if there are additional error messages.

  10. I've done some more reading and it seems the consensus is that Apple's Java Update 2 for Leopard is incompatible with the ColdFusion installer. If you installed ColdFusion before the Java update you're OK, but not the other way around.

    I'm trying this on a Mac Pro with Leopard that's less than a week old. It does have the Java update though so for now I guess I'll just run ColdFusion on a VM.

  11. @Andrew - That's great info to have. I've been running CF8 64-bit on Leopard for a while, even before it was officially supported and you had to compile your own 64-bit Apache connector.

    I would recommend you downgrade your Java version. You can either do that, or install an older version to a different location on your machine and point ColdFusion to the older version.

  12. I've been trying to figure the Java update 2 for os x and CF8 64-bit too and came to pretty much the same conclusion.

    here's the conclusion I've came to...


  13. @Ciqala Burt - Thanks for posting the comment and the link to your blog post. You have some great information on the latest Java update and how it affects ColdFusion 8. Folks, if you're having similar issues check out Ciqala's blog post and downgrade your JVM. Alternatively, you can install an older (supported) JVM in a different location and simply "point" ColdFusion to that location.

  14. no worries, I've had a bit of a personal vendetta against this problem so I've spent a fair amount of time trying to figure it out (and subsequently having to re-install my machine :( ) so it's good to finally have a pretty certain idea of what the problem was and the more people who might be affected that find out the better.

    It's all a bit rubbish though.

    As an aside if people want to hide the java update in software update I've also blogged how to stop it showing up in the update list. it's an easy thing to do but until just now i had no idea how to do it myself so others might not know either.