Monday, October 25, 2010

Railo 3.1 Installation on IIS 6

I've come upon the need for a fast, open-source cfml processor for one of my clients projects.. and it turns out, Railo is fast... very fast, and has a relatively small footprint of ~250Mb of ram when running.

Well, this has been quite the adventure (I prefer my webservers to be already running.. so I can focus on Development) , but it turns out the guide on was mostly correct, but required a slight alteration of the railo/conf file.

For clarity: These notes are for Resin 3.1 and Railo rc to be used with IIS 6.0 as the primary webserver.

1) In the example, resin.conf has an entry added for in which the root-directory attribute is set to "", when it should be set to simply "." in the case of Railo 3.x

2) Also, during my multiple attempts at the installation process, I came across other documents saying that an ISAPI filter was required on the "Web Sites" node of IIS... in my case.. it only worked without doing adding an ISAPI filter.

3) adding a /scripts directory? I added a scripts directory, with a copy of isapi_srun.dll into /InetPub/vhosts/

4) The default cflocation in index.cfm to the railo-context admin was driving me crazy... I had no idea where I actually was~!! Without adding an entry to resin.conf, my site was root-pointing to C:\railo\webapps\ROOT and launching index.cfm ... which I discovered later was redirecting via cflocation to the railo-context admin... so it was working... but I didn't know it! So, to save my sanity until I got everything going, I temporarily edited C:\railo\webapps\ROOT\index.cfm to require a manual click (a href=) instead of cflocation to show me where I was, and where I was going.

5) I also now have a new services entry called "Railo 3.1 Server" set as Automatic, which launches:

"C:\railo\httpd.exe" -service -Xms256M -Xmx512M -conf conf/resin.conf -java_home jre/ -java_exe jre/bin/java

Guide for adding Caucho Resin as a windows service if you don't have it already configured for you:

No comments: