Glarbl_Blarbl
February 16th, 2006, 02:18 AM
I originally posted this in response to a question in the general section, but it totally belongs here.
Ejabberd has more recommendations that I can find than any other open source IM server, as it will do encryption and web-based administration. I installed it a couple of days ago after trying jabberd briefly.
sudo apt-get install ejabberd
It works with only a couple of hacks, you need to edit the /etc/ejabberd/ejabberd.cfg and put your hostname in where it tells you in the comments, like this:
% Host(s) name: (replace for your hostname(s))
% Old {host, "localhost"}. option is equivalent to {hosts, ["localhost"]}.
{hosts, ["gps"]}.
My server is called gps. You'll also want to sudo and use "ejabberdctl register" to make yourself an account which you'll add into the same file for admin access.
sudo ejabberdctl register screen-name password
and then:
% Users that have admin access. Add line like one of the following after you
% will be successfully registered on server to get admin access:
{acl, admin, {user, "g"}}.
Gotta love the one-character login, I use it whenever I can.
Once this is done issue the command:
sudo /etc/init.d/ejabberd restart
and to double-check it's running:
sudo ejabberdctl status
Then fire up your favorite web browser and point it to
http://192.168.0.2:5280/admin/
replacing 192.168.0.2 with the IP or hostname of your new ejabberd server. For username, enter "user@server" where user is the account you made earlier with ejabberdctl and server is the hostname you inserted into the ejabberdctl.cfg file. Hopefully you still remember the password you set from earlier.
In the web admin panel you can set access controls and add users, it doesn't look like you can add or configure modules from here though. There's also a nodes page which is probably part of the fault-tolerance/rollover mechanism. I don't have another server to test this aspect yet, maybe I will investigate and write further later.
The biggest bugaboo I encountered, though, was getting GAIM 1.5.0 to connect ... After a bunch of tries, I found that the only way to make it work was an account set up like this:
change protocol to Jabber
screen name is user from before
server is the hostname from ejabberdctl.cfg
resource can be anything you want, if you use different resources you can log in more than once with the same screen name!
password from before
alias is probably the name that shows up when you type a message
(open "show more options")
check BOTH TLS and SSL
port 5223
Connect Server is IP or FQDN of your ejabberd server
No Proxy, unless you know that you need it.
Of course, now that you have the right settings you can actually just register a user from GAIM (unless you changed the acl to prevent this already)... It's nice to know how to do it from the command line though.
To add a buddy, make sure to do the full "user@server" formula, mine is g@gps ..
Ejabberd has more recommendations that I can find than any other open source IM server, as it will do encryption and web-based administration. I installed it a couple of days ago after trying jabberd briefly.
sudo apt-get install ejabberd
It works with only a couple of hacks, you need to edit the /etc/ejabberd/ejabberd.cfg and put your hostname in where it tells you in the comments, like this:
% Host(s) name: (replace for your hostname(s))
% Old {host, "localhost"}. option is equivalent to {hosts, ["localhost"]}.
{hosts, ["gps"]}.
My server is called gps. You'll also want to sudo and use "ejabberdctl register" to make yourself an account which you'll add into the same file for admin access.
sudo ejabberdctl register screen-name password
and then:
% Users that have admin access. Add line like one of the following after you
% will be successfully registered on server to get admin access:
{acl, admin, {user, "g"}}.
Gotta love the one-character login, I use it whenever I can.
Once this is done issue the command:
sudo /etc/init.d/ejabberd restart
and to double-check it's running:
sudo ejabberdctl status
Then fire up your favorite web browser and point it to
http://192.168.0.2:5280/admin/
replacing 192.168.0.2 with the IP or hostname of your new ejabberd server. For username, enter "user@server" where user is the account you made earlier with ejabberdctl and server is the hostname you inserted into the ejabberdctl.cfg file. Hopefully you still remember the password you set from earlier.
In the web admin panel you can set access controls and add users, it doesn't look like you can add or configure modules from here though. There's also a nodes page which is probably part of the fault-tolerance/rollover mechanism. I don't have another server to test this aspect yet, maybe I will investigate and write further later.
The biggest bugaboo I encountered, though, was getting GAIM 1.5.0 to connect ... After a bunch of tries, I found that the only way to make it work was an account set up like this:
change protocol to Jabber
screen name is user from before
server is the hostname from ejabberdctl.cfg
resource can be anything you want, if you use different resources you can log in more than once with the same screen name!
password from before
alias is probably the name that shows up when you type a message
(open "show more options")
check BOTH TLS and SSL
port 5223
Connect Server is IP or FQDN of your ejabberd server
No Proxy, unless you know that you need it.
Of course, now that you have the right settings you can actually just register a user from GAIM (unless you changed the acl to prevent this already)... It's nice to know how to do it from the command line though.
To add a buddy, make sure to do the full "user@server" formula, mine is g@gps ..