Setting up mod_mono (ASP.Net 2.0) on Ubuntu 7.10 (Gutsy Gibbon)

9. February 2008 17:57

After spending a day on this, I figured it would be worthwhile information for anyone that may be interested in configuring mod_mono2 (ASP.Net) for Ubuntu Gutsy.  I'm personally using an Ubuntu JeOS base configuration.  You may want to install your database of choice (mySQL, Firebird SQL, PostgreSQL, etc) in addition to other supported modules for apache2. 

First, you will want to install the necessary software...

sudo aptitude install apache2 mono mono-gmcs mono-utils mono-xsp2 monodoc-http libapache2-mod-mono mono-apache-server2

Second, you will want to use the auto configuration, instead of the default configuration, this will make your life easier.

     cd /etc/apache2/mods-enabled
    rm mod_mono*
    ln -s ../mods-available/mod_mono_auto.* ./ 

Next, you will need to set the config file to use mod_mono2 instead of the default mod_mono...

sudo nano mod_mono_auto.conf

Prepend the following line to the top of the file...

MonoServerPath "/usr/bin/mod-mono-server2"

You will need to restart apache after you have made this edit, in order to actually utilize mod_mono2.

sudo /etc/init.d/apache2 stop
sudo /etc/init.d/apache2 start

Now all you need to do is have a ./bin directory and a web.config file in the root of any ASP.Net 2.0 web application.  It's also worth noting that you will not be using the most current version of mod_mono when you use Gutsy, and you may wish to look at one of the many source installation instructions out there.  Me, I just wanted something simple to be able to get up and going quickly, and acknowledge that I may not have the latest and greatest compatability. 

If you are having any issues make certain that you have Apache2 configured properly, and check /var/log/apache2/error.log for any error notifications.

Comments are closed

Tracker1

Michael J. Ryan aka Tracker1

My name is Michael J. Ryan and I've been developing web based applications since the mid 90's.

I am an advanced Web UX developer with a near expert knowledge of JavaScript.