Pages

Wednesday, July 6, 2011

Install Openfire on Linux.

This article describes how to install Openfire IM server onto a Linux platform with a step by step, screen shot assisted guide.

Firstly you need to download the packages. This example uses RedHat packages for Fedora Linux, your system maybe similar and you can still follow the guide, but substistue packaging commands like yum or rpm.

Below is an the first step of downloading the rpm , ready to install. First of all , i use the wget command to retrieve the rpm.

Installing the Openfire RPM on Fedora 11

Now you need to install the rpm, using the rpm program, with the arguments -i for install , -v for verbose , -h hashes for progress.

I also did chkconfig --list to find out if the rpm had properly enabled openfire to start on boot, and it has.

Installing opefire on Fedora using an rpm

Start the service

Start Openfire server

Now the service is started you need to open your web browser and complete the set up in the administrative console. This console is located at http://YOURSERVER:9090

Once you browse to the admin console you will get immediate access without having to use a password, its important to complete the setup and set a password quickly so that your installation of open fire becomes secure.

Here is what the first screen of the administrative console setup looks like:

Openfire admin web console - first stage setup

Choose your language as show above and press the continue button.

Now you will see the next screen which allows your to setup the domain name and ports used, by default openfire will use the servers domain name and ports 9090 and 9091 for http and https services respectivley. This means that once installed you can administer the service in your web browser with or without using SSL/https security, as you wish.

The screen capture below shows the details for my installation server called websrv, which is a node on the local network here. If your Openfire server is out on the internet, you should use a fully qualified domain name (FQDN) like websrv.mycompany.com, instead of the short websrv name I am using.

Unless you have a conflicting service or another reason to change the default port settings, leave them as Openfire suggests.

Domain and Port setup for Openfire Linux Installation

The next step is to setup a database. There are two basic choices to follow, the simplest is to choose a built in HSQL database as this requires little administration or knowledge to achieve, recommended if you already feel out of your depth. For the more experienced user you will need to setup a database either on an external server as Openfire refers to it, or you can install a database locally as your desire.

The HSQL database lacks performance and scalability, backup and restore / administrative ease of use that a full database platform gives you.

In my example I am using the MySQL database which comes included in the Fedora distribution this machine uses, so I choose the standard database connection. Out of the box openfire supports MySQL,Oracle,Microsoft SQL,IBM DB2 databases.

Screenshot of database setup in Openfire Installation on Linux


Next I will installa new database, and then continue setup the configuration for the MySQL database, before I press the continue button I will check the database settings on the command line and make sure it is working.

Because I am installing this server as a quick example, i am going to use the mysql root user. In your server you should use a standard user or restricted database user !

Enter the mysql command (with a user and password most likely , mysql -u user -p password) to get to the mysql prompt:

Screen shot of mysql database create for Openfire install on Linux

Now the database is created, i switch to the browser and complete the setup, filling in the database type and details.

Screen shot of MySQL database config

Once you have succesfully configured the database, you get to the profiles page. In profile settings you get the chance to setup integration with your LDAP or Active Directory services and delegate logins to the local directory. If your company uses Clearspace 2+ you can also use the Clear Space option.

For most users the default option will be the right choice, where users are configured locally on the same Openfire server.

Screen shot of Profiles setup on Openfire installation in Linux

Now we get to the final part of the administrative console setup process. Here you can setup the administrator password , this stepcan be skiped but it is highly recommended to password protect your Openfire server. You will need to enter a valid email address and an admistrative password for the Openfire server.

Screen shot of Admin configuration - Openfire Installation on Linux

Now we are done ! The only thing left to do is to log into the admin interface that we just configured, you will find it at http://YOURSERVER:9090/login.jsp or simply click the login button shown in the screenshot below.

Openfire Install on Linux Completed

This concludes installation of Openfire on Linux.