Home » ejabberd » Basic Ejabberd install/setup on ubuntu

Basic Ejabberd install/setup on ubuntu

In social web appliactions, Jabber chat comes as popular choice for implementing self chat gateway/servers. While there are several chat server are available in market like ejabberd, jabberd2, openfire.
Ejabberd is chat server built in erlang. It provide various recommended features by core/plugins.

Now I am going to give some information for setup ejabberd chat server onto Ubuntu 12.04.

First you need to install ejabberd package. There are two ways.
1. Through ubunty repository. While this option require less work, But you may not get latest package for ejabberd.
2. Download ejabberd package and compile it. This option require more work, But you can get latest package havig more features.

We going through First easy approach.
Here we install ejabberd via

sudo apt-get install ejabberd ejabberd-tools

After installation completion, we will doing some intial setup and configuration.
We need to configure our first chat domain. Here we have config file names ejabberd.cfg at /etc/ejabberd folder.
Open it into your editor, and go for line look like below.

{hosts, ["localhost"]}.

Then change it to add your domain/ip-address as Chat server host.

{hosts, ["localhost","yourhost.com"]}.

Also setup your admin user via change config.

{acl, admin, {user, "", "localhost"}}.

to

{acl, admin, {user, "administrator", "localhost"}}.

Where administrator is admin-name chosen by you. (Ofcourse you can choose any name as admin.)

After save you should also register your admin via command run on shell.


ejabberdctl register administrator localhost password

Now you should restart ejabberd by executing commands

sudo /etc/init.d/ejabberd restart

Open Admin Console via the url – http;//localhost:5280/admin. It ask you the enter admin credentials. enter administrator name and its password, setup via ejabberctl.
Here you can add users via going to virtual hosts -> localhost[yourhost.com] ->  Users.

After register users at here you can start chat by your jabber client example pidgin or spark.

Ejabberd default using it internal database called mnesia to store all kind of information like users, room, logs etc.

In second article of series, I will discuss the external authentication and logging.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s