powered by Jive Software

Presence not working on clients


I installed openfire on a linux box and racked it. Its using a static IP. I point the clients to, and I can connect (do I need to use a domain name).

I set the server name to refipal.com (which is our website), but should it be im.refipal.com (I have a dedicated IM server) ?

My question is does the presence work off of DNS settings. My web-base client works fine detecting when someone comes online, but my desktop client apps can connect, but cant detect presence at all.

Sorry for the fashionably late response, but here goes:

First of all, it’s important to understand that there are two types of ‘network names’ that come into play: the first one is the hostname of the server that’s running Openfire, the second one is the XMPP domain name of your IM network. For a lot of installations, the two different names match, but there’s nothing that’s requiring this.

As I understand your question, your XMPP domain name should be refipal.com, while the server hostname appears to be im.refipal.com (but basically, that could be anything).

Configure Openfire to use the XMPP domain name: refipal.com

Next, you need a way of telling your clients that if they want to connect to your XMPP domain, they need to connect to your im.refipal.com server. The standard way of doing this is by configuring a DNS SRV record. DNS SRV enable clients to determine what server is providing a particular service (SRV records can also be used to assign multiple servers to one particular service, and do load balancing over them, but that’s a bit besides the point now). You can find more on DNS SRV at Wikepedia: http://en.wikipedia.org/wiki/SRV_record

The record that will queried by clients is : “_xmpp-client._tcp.refipal.com.”

If you’d like to make use of federation, you’ll also have to set an additional record: “_xmpp-server._tcp.refipal.com.”

An older (now obsolete) record was also used. To remain backwards compatible with older clients, it wouldn’t hurt to set this one as well: “_jabber._tcp.refipal.com.”

Additionally: After your client sets up a succesfull connection to the Openfire server, Openfire will take care of all routing of XMPP stanzas (the client will send everything over that single socket to the server, after which the server processes the XMPP headers, applies server-sides routing rules and forwards the stanzas to the intended recipients). Therefor, the delivery of presence stanzas has nothing to do with DNS settings - as long as your clients are connected to the correct server, you’re set.

In XMPP, two end users that would like to see each-others presence should be subscribed to receive each other presence notifications. Section 6 of RFC 3921 describes the details.