From MattWiki
Jump to: navigation, search
Developer(s) Process One
Stable release
18.01 / January 12, 2018; 3 months ago (2018-01-12)[1]
Repository github.com
Written in Erlang
Operating system Cross-platform
Type XMPP server
License MIT License[2]
Website ejabberd.im
XMPP Portal
XMPP Servers: Servers Category
XMPP Clients: Clients Category
User Guides: User Guide Category

ejabberd is an XMPP application server, written mainly in the Erlang programming language. It can run under several Unix-like operating systems such as Mac OS X, GNU/Linux, FreeBSD, NetBSD, OpenBSD and OpenSolaris. Additionally, ejabberd can run under Microsoft Windows. The name ejabberd stands for Erlang Jabber Daemon (Jabber being a former name for XMPP) and is written in lowercase only, as is common for daemon software.

ejabberd has been in development since 2002 and is used all over the world to power the largest XMPP deployments. This project is so versatile that you can deploy it and customize it for very large scale, no matter what is your use case.

This incredible power comes with a price. You need to learn how to leverage it. Fortunately, the goal of this website is to get you started on your path to mastery. Whether you are a sysadmin, an architect, a developer planning to extend it, or even a simple XMPP user, we have something for you here.

Installing on Ubuntu

noteThis Page was written with Ubuntu 16.04 LTS in mind, and may not work correctly with other versions or distributions.

Start out by adding the `ejabberd` user and install needed dependencies.

adduser --system --group --home /var/lib/ejabberd --disabled-login ejabberd -q
apt update && apt install -y gcc autoconf automake make clang git erlang expat \
    libyaml-dev libexpat-dev libssl-dev

Download the ejabberd git.

mkdir -p /var/src/; cd /var/src/; rm -rf ejabberd
git clone https://github.com/processone/ejabberd.git

Compile and install ejabberd.

cd /var/src/ejabberd/ && ./autogen.sh && \
./configure --prefix="" --enable-user=ejabberd && \
make && make install

Next, update ejabberdctl with the systems hostname.

sed -i "s/^ERLANG_NODE=.*/ERLANG_NODE=ejabberd@` hostname -f`/g" /sbin/ejabberdctl

And once complete, start ejabberd.

ejabberdctl start && echo $?

Configuring PostgreSQL

Start by creating a new user named ejabberd

$ sudo -u postgres createuser --interactive
Enter name of role to add: ejabberd
Shall the new role be a superuser? (y/n) n
Shall the new role be allowed to create databases? (y/n) n
Shall the new role be allowed to create more new roles? (y/n) n

Next, create a database named ejabberd

sudo -u postgres createdb ejabberd

Managing eJabberd

Adding a new user

ejabberdctl register <user> <domain> <password>
ejabberdctl register alice example.com S3cure9assw0rd


  1. "ejabberd 18.01 Release Notes". Github.com. 2018-01-12. Retrieved 2018-01-12. 
  2. "Github GPLv2 License". Github.com. 2014-02-22. Retrieved 2017-07-31.