Save as Word Document | Find | English | Portugues(Brasil)

Installing XMLNuke
Installing XLMNuke CSharp on Ubunto(Gutsy)/Debian/Linux

How to install XMLNuke CSharp on Ubuntu(Gutsy)/Debian/Linux.

Table of contents
1. Installing XMLNuke CSharp on Windows
2. Installing XMLNuke PHP5 on Windows
3. Installing XLMNuke CSharp on Ubunto(Gutsy)/Debian/Linux

On this page
Installing XLMNuke CSharp on Ubunto(Gutsy)
Problem solving
Installing the MySql Connector to .NET on Ubuntu


Installing XLMNuke CSharp on Ubunto(Gutsy)

The installation of XMLNuke CSharp in Linux environments requires that the Mono equivalent of .NET 2.0 be installed. To do this, follow the steps below:

Installing Mono
sudo aptitude install mono-gmcs mono-apache-server2  asp.net2-examples mono-xsp2
sudo aptitude install libapache2-mod-mono apache2-mpm-prefork
Important note: The compilation of apache used in this installation was PreFork. This installation is standard if you run it concurrently with another language, like PHP5. If you already have apache installed, and it is not PreFork, please remove it from the installation.

After installing Mono, open the file /etc/apache2/mods-available/mod_mono.conf and uncomment the line that contains the mono-server2 (reference to ASP.NET 2.0), so that it is more or less like this:

File /etc/apache2/mods-available/mod_mono.conf
AddType application/x-asp-net .aspx .ashx .asmx .ascx .asax .config .ascx
DirectoryIndex index.aspx

# Include the web application definitions generated by
# mono-server-update.conf. If you want to use XSP2, reverse the
# comments.
#Include /etc/mono-server/mono-server-hosts.conf
Include /etc/mono-server2/mono-server2-hosts.conf

Once the mono installation process is completed, XMLNuke must be compiled. If you downloaded a pre-compiled version for .NET, please skip this step.

Compiling XMLNuke CSharp
cd xmlnuke/xmlnuke-csharp-sources
./build.sh

Once the installation/compilation process for XMLNuke is finalized, the apache must be configured. Copy the following lines inside the configuration of your Virtual Host:

Configuring Apache
Alias /xmlnuke-csharp "[YOURDIR]"

AddMonoApplications default "/xmlnuke-csharp:[YOURDIR]"

<Directory [YOURDIR]>
    SetHandler mono
    <IfModule mod_dir.c>
       DirectoryIndex index.aspx default.aspx
    </IfModule>
</Directory>
Remember to substitute [YOURDIR] for the installation directory of your XMLNuke. Next, restart Apache and everything should be working.

Problem solving

  • If the log error for apache shows a code similar to the one described below: Failed running '/usr/lib/pkgconfig/../../bin/mod-mono-server --filename /tmp/mod_mono_server_default --applications /samples:/usr/share/asp.net2-demos --nonstop (null) (null) (null) (null) (null) (null) (null)'. Reason: No such file or directory. This occurs because your installation probably did not correctly treat the selection of the mod-mono-server2 when you used ASP.NET 2.0. To resolve this specific problem:

    ln -s /usr/bin/mod-mono-server2 /usr/bin/mod-mono-server

  • The installation was only successful when the apache configuration described above is defined for the ENTIRE server and not for a Virtual Host. To configure it for the entire server, the configuration file was placed within the mod-enabled.

  • XMLNuke CSharp was tested with the following mono versions: 1.2.4 (Ubuntu) e 1.2.1 (Debian Etch)

  • The following tutorial was followed to install Mono on Apache: https://help.ubuntu.com/community/ModMono. Entretanto não está sendo utilizado o recurso do arquivo .webapp. However, the file resources are not being used. In its place, the AddMonoApplication is being configured.

Installing the MySql Connector to .NET on Ubuntu

The most recent .NET MySql connector must be downloaded (that supports .NET 2.0). You can obtain it at: http://dev.mysql.com/get/Downloads/Connector-Net/mysql-connector-net-5.1.4-noinstall.zip/from/pick#mirrors. (Remeber to select only the "Windows and Binaries" version without the installer). Once downloaded, access the .ZIP file directory and execute the following commands:

Install the .NET connector of MySql
mkdir mysqlconnector
cd mysqlconnector
unzip ../mysql-connector-net-5.1.4-noinstall.zip
cd bin
sudo gacutil -i MySql.Data.dll
cd /usr/lib/mono/2.0/
sudo ln -s ../gac/MySql.Data/5.1.4.0__c5687fc88969c44d/MySql.Data.dll 
Restart apache.

Previous
Installing XMLNuke PHP5 on Windows