Installing Mono on SuSE Linux with Red Carpet
In this article I'll provide the step by step instructions for installing Mono on SuSE Linux Professional 9.1 using Red Carpet 2.2.3. After reading, you should have a clear idea of how to get through the installation, and hopefully avoid some of the snags I ran into. In the end, with this article, setting up Red Carpet will be as easy as using it to install Mono.
This article will not provide any explanation about Mono itself. It assumes that the reader knows what Mono is, otherwise, why would you be interested in completing the installation?
Step One - Obtaining Red Carpet Enterprise
Well the first thing to understand is that since Novell's purchase of Ximian, Red Carpet is no longer available as a separate download. As mentioned on the Mono Project download project, it is now available as the ZENWorks Suite 6.5.
Once you get to the ZENWorks download page from Novell, the file required is ZEN65_LinuxMgmt.iso. This provides management for Linux desktops and servers, but it is essentially Red Carpet Enterprise. Be forewarned, the only way to get the necessary installation RPMs are from a 474.2 MB iso image. In addition, according to the Novell web site, this is a 90-day evaluation license of Red Carpet.
I believe that Novell is well positioned to benefit from the growth of LInux and open source software. However, I question their restrictive licensing of a technology that is necessary to download and install what may become the predominant open source software development platform. I'm really not sure if this license will apply to Red Carpet, so I'll let you know in 88 days. In addition, why not break up the iso image into the individual components? Why should I have to download 474 MB when I only need 3 files that are less than 2 MB?
Step Two - Installing Red Carpet Enterprise
Once you have downloaded the iso image and have burned it onto a CD, then mount the CD and look for the redcarpet2 directory. For SuSE Linux Professional 9.1, the RPMs necessary were found in the suse-91-i586 subdirectory. The critical files are:
This is the Red Carpet Daemon. It is absolutely necessary for getting Red Carpet to work correctly as I'll explain later.
This package contains the graphical user interface for Red Carpet.
This package contains the command graphical user interface for Red Carpet.
Install these packages and we are almost done. First, the GUI application should appear in the KMenu in the System -> Configuration folder as Red Carpet. You can further verify the successful installation by using YaST. Check in the Install and Remove Software -> Package Groups -> System Environment where you will find the newly installed software in the the Applications and Deamons groups.
With the software installed, the next step requires starting the Red Carpet Deamon. To start the deamon from the graphical user interface, you need to return to YaST. Select System -> Runlevel Editor, and then click on the rcd service. Click on the Enable button and the service should change status and show Enabled is now equal to Yes.
To start the Red Carpet Deamon from the command line, use the following quick command. Enter:
You will need the root password, in order to complete this transaction. Once complete, you should receive the prompt "Starting Red Carpet Daemon." Now that the deamon is running you are ready to begin the Mono installation.
Step Three - Installing Mono Graphically
I'll assume that you are not currently using the root account, so the first thing to do is be sure and start the Red Carpet GUI application using the root account. Enter:
If the connect to deamon dialog appears as illustrated in Figure 1, then the red carpet deamon is not currently enable. Return to the previous step and start the rcd deamon. Click on the Available Software tab, then click on the Channel drop down list selection button. This should produce a list of available channels. Select the mono-1.1 channel and then all available packages from the channel should appear. Slect Edit -> Select All or press Ctrl A to select all of the available packages. Select Actions -> Mark for Installation or right click the selected packages and select Mark for Installation. Click on the Run Now icon from the tool bar, select Actions -> Run Now, or press Ctrl X. This will start the installation process.
Figure 1 - The Connect to deamon Dialog
Step Three - Installing Mono From The Command Line (Alternate)
Issue the following commands as root:
This will download the most current channel information. Next in order to confirm connectivity with the redcarpet servers run:
This should present a list of available channels. The list will also present whether you are currently subscribed to them. The output should resemble the following listing:
To complete the installation, then run the following commands:
The -y option will permit all actions without confirmations. Since there are approximately 50 different packages required for Mono, including all of the dependencies, this option should prove helpful.
Step Four - Testing your installation
After installing Mono, confirm the installation with a simple test. Using a text editor, enter the simple C# program shown in Lilsting 1.
Listing 1: Save this simple program as hellopr.
To compile the program, enter:
This should produce a response of "Compilation succeeded." If the compilation fails, then check whether the system class starts with a capital "S", the console class starts with a capital "C", and the write line method uses a capital letter for both write and line. Remember, that in C#, classes and all methods and properties are case sensitive.
Successfully compiling the hellopr program should produce a hellopr.exe executable. To run the program, enter
This should produce the output "Hello, from Gurabo, Puerto Rico".
In this article you have seen how to install and verify Mono. This process includes obtaining Red Carpet Enterprise, installing Mono, and finally creating, compiling and running a simple test program. I hope this provides a simple to follow procedure and eases your way on the road to developing Mono applications.
Kevin Shockey is an emerging high technology entrepreneur.
Comments on this weblog
1 to 4 of 4
2004-12-27 13:42:10 dan_young [View]
1 to 4 of 4
Return to weblogs.oreilly.com.