Trustix 2.1 and Jabber

Installing Jabber on a Trustix server.’, ‘NOTE: These instructions are probably wrong. Jabber is such a bitch to get installed and working for beginners that I tried to document all the hoops I jumped through

Ok.. first, let\’s create a jabber user:

# groupadd jabber
# useradd -g jabber jabber
# mkdir -p /usr/local/var/jabberd/db
# mkdir -p /usr/local/var/jabberd/log
# mkdir -p /usr/local/var/jabberd/pid
# chown -R jabber:jabber /usr/local/var/jabberd/

Now, let\’s download the jabber server..

NOTE: Webmin doesn\’t support Jabber 2, so jump to the bottom for the 1.x installation.. but since I wrote all this up, I didn\’t want to just delete it.. 🙁

# wget http://www.jabberstudio.org/projects/jabberd2/releases/download.php?file=jabberd-2.0s3.tar.gz

Now, we need to download libidn.. It should be available at: http://www.gnu.org/software/libidn/ but the server wasn\’t responding, so I got it here:

# wget http://josefsson.org/libidn/releases/libidn-0.4.9.tar.gz
# tar -xvzf libidn-0.4.9.tar.gz
# cd libidn-0.4.9
# ./configure –prefix=/usr
# make
# make install

Now let\’s install Jabber!

# tar -zxvf jabberd-2.0s3.tar.gz
# cd jabberd-2.0s3
# ./configure –enable-db

Hmm.. For some reason, mine is saying my OpenSSL is missing or isn\’t up to date 🙁

So, I tried this:
# ./configure –enable-db –enable-ssl=no

Now it\’s complaining about mysql..

# swup –install mysql-devel

Ok.. now Berkeley.. 🙁

# swup –install db4-devel
# swup –install openssl-devel

—————————— Start Here ———–
DOH! Webmin only works with 1.x right now… 🙁 Let\’s start over.. :\'(

Ok..
# swup –install expat
# swup –install expat-devel

# wget ftp://ftp.gnu.org/gnu/pth/pth-2.0.1.tar.gz
# tar -xvzf pth-2.0.1.tar.gz
# cd pth-2.0.1
# ./configure
# make
# make test
# make install

# wget http://jabberd.jabberstudio.org/1.4/dist/jabberd-1.4.3.tar.gz
# tar -xvzf jabberd-1.4.3.tar.gz
# cd jabberd-1.4.3
# ./configure
# make
# mv jabberd-1.4.3 /opt/jabber
# chown -R jabber.jabber /opt/jabber

Now we need to create a start and stop script

# vi /etc/rc3.d/S99jabber

Insert:

#!/bin/sh
# description: Jabber IM Server
# chkconfig: 2345 99 00
# pidfile: /var/run/jabber.pid

case "$1" in
\'start\')
        cd /opt/jabber
        ./jabberd/jabberd -h cvs.culymail.com &
        touch /var/lock/subsys/Jabber
        ;;
\'stop\')
        rm -f /var/lock/subsys/Jabber
        ;;
*)
        echo "Usage: $0 { start | stop }"
        ;;
esac
exit 0

# chmod 755 /etc/rc.d/rc3.d/S99jabber

# cp /usr/local/lib/libpth.so.20 /usr/lib
# chmod 755 /usr/lib/libpth.so.20
# mkdir /var/spool/jabber
# chown jabber.jabber /var/spool/jabber

Log into Webmin, click on servers, and then Jabber IM Server

Config the following:

Jabber XML config file – /opt/jabber/jabber.xml

Jabber base directory – /opt/jabber
Path to jabber server program – /opt/jabber/jabberd/jabberd
Jabber hosts directory – /var/spool/jabber
Jabber shared libraries directory – None
Command to start jabber – /etc/rc3.d/S99jabber start

Command to stop jabber – Kill process

Click “Here” to install XML::Parser and XML::Generator from CPAN

Click on Server/Jabber IM Server

Click on General Options and set the server name
Click on Messages and change server name and edit messages however you like

http://www.jabberdoc.org/quickstart.html

Leave a Reply