Hi,
we are trying to setup a Kamailio as a SIP/SIMPLE presence server for chat based on the guide published in SIP SIMPLE Presence Made Simple with Kamailio 3.1.x on the site: http://kb.asipto.com/kamailio:presence:k31-made-simple.
The OS we are using is Linux RHEL 5.6 x64 and MYSQL as Database.
We found some strange behaviors of the Kamailio basic presence, presence rules functionalities. As suggested in the guide we created 2 users (Alice and Bob) and both the latest jitsi (SIP communicator) to test it. The test scenario is following by using either UDP or TCP protocol:
- Alice add the Bob as a contact
- Bob add the Alice as a contact
- Alice change presence status
- Bob change presence status
- Alice send IM to Bob
- Bob send IM to
- Alice put the status offline
- Bob put the status offlice
First, test the configuration without XCAP server load:
- WITH_XCAPSRV is not defined
- Use implicit presence rule modparam("presence_xml", "force_active", 1) (from my understanding, without xcap we can only use implicit presence rule without any authorization for the subscription
Result:
- Add contact is ok and the presence status is immediately visible (because force_active = 1)
- The change status of the presentity is immediately visible by watcher with the only exception, when the user goes offline, the presentity keeps online in the watcher buddy list, any idea? Can you help me?
Second, test the configuration with XCAP server load and the configuration is the same of the guide:
- WITH_XCAPSRV is defined
- Use implicit presence rule modparam("presence_xml", "force_active", 0)
- modparam("presence_xml", "integrated_xcap_server", 1)
Result:
- When Alice add the Bob as a contact, there is no popup to ask the Bob authorization immediately.
- When Bob change the presence status, Alice dosen’t see the change(offline), but they can exchange IM.
- When Alice goes offline, the popup of the authorization request of the Alice is appear to Bob, Bob accept the request
- When Alice come on line again, the same behavior, Alice always see Bob is online even Bob change his status.
- When Alice goes offline again, the Authorization Request come up again to Bob just like Bob even Bob has accepted the request before. Very strange
When we configured the kamailio with XCAPSRV and enable the xcap also in the SIP communicator as suggested by the guide, we got the following error in /var/log/messages when alice goes online:
Apr 18 16:35:01 kamailio3p1 /usr/sbin/kamailio[7561]: ERROR: <script>: ===== xhttp: resource-lists : sip:alice@10.10.5.214
Apr 18 16:35:01 kamailio3p1 /usr/sbin/kamailio[7561]: ERROR: <script>: ===== xhttp: get sip:alice@10.10.5.214 => /xcap-root/resource-lists/users/sip:alice@10.10.5.214/index
Apr 18 16:35:01 kamailio3p1 /usr/sbin/kamailio[7562]: ERROR: <script>: ===== xhttp: pres-rules : sip:alice@10.10.5.214
Apr 18 16:35:01 kamailio3p1 /usr/sbin/kamailio[7562]: ERROR: <script>: ===== xhttp: get sip:alice@10.10.5.214 => /xcap-root/pres-rules/users/sip:alice@10.10.5.214/presrules
The xcap table is empty. Do I need to configure also the xcap table? Or it’s automically done by kamailio presence server?
Any idea? Maybe we have wrong configuration or is it a bug of kamailio?