Natsun Technology Services Pvt. Ltd.

How To's


1: Install Mono 2.4 and mod_mono on RHEL5 with Mysql support
2: To install BIRT runtime on RHEL 5

 

Assumptions

1: You have root access on your RHEL 5 system

2: You are aware of basic sysadmin commands.

Note: This install was tested on a x64 system.

 

1:Install Mono 2.4 and mod_mono on RHEL5 with Mysql support

 

Files to Download

http://ftp.novell.com/pub/mono/sources/libgdiplus/libgdiplus-2.4.2.tar.bz2
http://ftp.novell.com/pub/mono/sources/mono/mono-2.4.2.3.tar.bz2
http://ftp.novell.com/pub/mono/sources/xsp/xsp-2.4.2.tar.bz2
http://ftp.novell.com/pub/mono/sources/mod_mono/mod_mono-2.4.2.tar.bz2

http://mirror.cogentco.com/pub/mysql/Connector-Net/mysql-connector-net-6.0.4-noinstall.zip

 

RPMs

You need the following rpms to compile mod_mono. You should have these on your RHEL CD.
httpd-devel
apr-devel
apr-util
apr-util-devel


All my sources are placed in /opt/downloads

All my sources will be untared in /opt/build

 

To install mono on RHEL5

 

Step 1 : Untar libgdi and build it


tar -jxvf /opt/downloads/libgdiplus-2.4.2.tar.bz2 -C /opt/build
cd /opt/build/libgdiplus-2.4.2
./configure;make;make install

 

Step 2: Untar mono and build


cd /opt/downloads/mono-2.4.2.3/
./configure ;make;make install

 

To install mod mono

 

Step 1: Untar mod_mono package, configure, build & install

 

tar -jxvf /opt/downloads/mod_mono-2.4.2.tar.bz2
./configure ;make;make install

 

Move the mod_mono.conf file to the right location so that it is automatically loaded

 

mv /etc/httpd/conf/mod_mono.conf /etc/httpd/conf.d/

 

Add this line to the mod_mono.conf
MonoServerPath /usr/local/bin/mod-mono-server2

 

Step 2: Untar xsp, configure, build & install

 

tar -jxvf xsp-2.4.2.tar.bz2 -C /opt/build
cd /opt/build/xsp-2.4.2
./configure;make;make install

 

 

Now to test mod_mono
copy xsp files to your document root dir


cp -a /usr/local/lib/xsp/test /var/www/html/

 

Now go to your browser and check out your installation
http://localhost/test/


Now go ahead if you need to install mysql support


cd /opt/build
unzip /opt/downloads/mysql-connector-net-6.0.4-noinstall.zip
mv mysql.data.dll MySql.Data.dll
/usr/local/bin/gacutil -i /opt/build/MySql.Data.dll

 

Common error

 

Object reference not set to an instance of an object

Description: HTTP 500. Error processing request.

 

1: If you do not change the name of the dll you might get this
error below. So make sure your dll is MySql.Data.dll

 

2: Make sure you save these config settings in your web.conf

<system.data>
<DbProviderFactories>
<add name="MySQL Data Provider" invariant="MySql.Data.MySqlClient" description=".Net Framework Data Provider for MySQL" type="MySql.Data.MySqlClient.MySqlClientFactory, MySql.Data, Version=6.0.4.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d" />
</DbProviderFactories>
</system.data>

 

Return to Top

 

2: To install BIRT runtime on RHEL 5

 

Files to download

http://apache.mirrors.hoobly.com/tomcat/tomcat-6/v6.0.20/bin/apache-tomcat-6.0.20.tar.gz

http://www.eclipse.org/downloads/download.php?file=/birt/downloads/drops/R-R1-2_5_0-200906180630/birt-runtime-2_5_0.zip

jre-6u16-linux-amd64.rpm

 

Note: Since you are installing the Web Viewer on Tomcat 6, you will need to download the commons logging library.

 

Install Sun JDK


rpm -ivh /opt/downloads/jre-6u16-linux-amd64.rpm


set your java home


export JAVA_HOME=/usr/java/jre1.6.0_16/

 

Install Apache tomcat


tar -zxvf /opt/downloads/apache-tomcat-6.0.20.tar.gz -C /opt/build/
cd /opt/build/apache-tomcat-6.0.20/bin/
./startup.sh


Test your installation from the browser
http://localhost:8080/

To use the tomcat manager, set manager user for tomcat in tomcat-users.xml
<user username="manager" password="tomcat" roles="manager"/>

Restart tomcat and check the url http://localhost:8080/manager/html

 

 

Install BIRT runtime


cd /opt/build
unzip /opt/downloads/birt-runtime-2.1.3.zip
cd /opt/build/birt-runtime-2_1_3/
cp -a WebViewerExample /opt/build/apache-tomcat-6.0.20/webapps
mv /opt/build/apache-tomcat-6.0.20/webapps/WebViewerExample/ /opt/build/apache-tomcat-6.0.20/webapps/birt-viewer

 

Install Commons Logging Library


tar -zxvf /opt/downloads/used/commons-logging-1.1.1-bin.tar.gz -C /opt/build

 

Copy the jar file into birt-viewer

 

cp /opt/build/commons-logging-1.1.1/commons-logging-1.1.1.jar /opt/build/apache-tomcat-6.0.20/webapps/birt-viewer/WEB-INF/lib/

 

Use the tomcat manager to see whether birt-viewer has been auto deployed.

 

Now you can check your birt-viewer report from your browser http://localhost:8080/birt-viewer/

 

A page confirming that the BIRT viewer has been installed should be displayed.

Click on the link labeled "View Example" to confirm that your installation is working properly.

The BIRT Viewer requires that cookies be enabled.

 

Common Errors:

I tried BIRT with the default install of jre on RHEL5/ Fedora8 and I came across so many errors.

After a lot of google I gave up on those versions and downloaded tomcat 6 and sun jre and it worked fine.

 

Return to Top

 

Disclaimer:

The Company will not be responsible for any losses or damages of any kind incurred by the reader whether directly or indirectly arising from the use of the information found on this website.