[jadmin] jabberd2 / mysql / freebsd difficulties
Matthew Anderson
manders2k.lists at gmail.com
Wed Jun 14 16:21:42 CDT 2006
Hi --
I've been tasked with writing a jabber component for work, and I've
been trying to get a jabberd2 server set up to use as a development /
testing environment. I have the server up and running, mostly, but I
am unable to fully connect to it with a client. The client (I've
tried both "Fire" and "iChat" under OS X) gives me a "would I like to
register this account" message, but then is unable to connect. I've
dumped the mysql database table that the jabber server should be
writing to, and it doesn't appear to change at all through the process.
The server is running FreeBSD 6.1, and both 'jabberd2.0s11' and
'mysql41-server' are installed from the ports tree.
I don't have a great deal of experience with the installation or
administration of either a mysql server or a jabberd server (though
I'm an old hand at other unix / service administration tasks), but I
believe that I've got things set up as per the documentation.
MySQL is set up thusly:
(1) add to rc.conf:
mysql_enable="YES"
(2) start the mysql daemon:
/usr/local/etc/rc.d/mysql-server start
(3) set the mysql root password:
mysqladmin -u root password NEWPASSWORDTEXT
(4) set up the jabberd2 tables in the mysql database:
cd /usr/local/share/jabberd/
mysql -u root -p
mysql>\. db-setup.mysql
mysql>GRANT select,insert,delete,update ON jabberd2.* to
jabberd2 at localhost IDENTIFIED by 'SOMEPASSWORD';
and the jabber server is set up like so:
(1) add to rc.conf:
jabberd_enable="YES"
(2) edit: /usr/local/etc/jabberd/sm.xml
change <mysql/><pass/> to SOMEPASSWORD
change <id/> to hostname
have tried both <user/><auto-create/> commented and uncommented
(3) edit: /usr/local/etc/jabberd/c2s.xml
change <mysql/><pass/> to SOMEPASSWORD
change <id/> to hostname
(4) start with one of:
/usr/local/etc/rc.d/jabberd start
sudo -u jabber /usr/local/bin/jabberd
sudo -u jabber /usr/local/bin/jabberd -D
I hope that's everything.
I'm not getting any error messages during the normal jabber server
startup sequence, nothing of note in /var/log/messages, and nothing I
find helpful when I start the server manually with a -D flag (though
there is copious amounts of logging to wade through). When I try to
connect with a client in debug (-D) mode, the server reports
information about the connection attempt (including XML messages from
the client complete with JID "me at hostname/fire" for the Fire IM
client). I don't see anything that looks like an attempt to write to
the database though, only a couple of SELECT statements.
Finally, I did initially have a jabber1.4.4 server set up on the same
machine (I was learning jabber technology from the O'Reilly
Programming Jabber book, and it seemed like possibly a good choice),
and I did have it mostly working (I could send IM messages back and
forth between two clients). I compiled it from source as jabber1
didn't seem to be easily obtainable through the ports tree. Some
strangeness was happening though, that the first time the jabber
server tried to connect to a port for whatever reason, it worked
fine, but if the server was shut down and started up again, it failed
to connect to the port (5222, for example). If I rebooted the
machine, it could connect again. I figured switching to jabber2 was
the better approach than debugging that oddness.
So, I'm not sure how to proceed in figuring out what's wrong with my
setup. Any wisdom / suggestions? Any additional information I
should share to make troubleshooting easier?
Thanks a lot!
--
Matt Anderson
More information about the JAdmin
mailing list