[SR-Users] pua_usrloc, PUBLISH not send when contact is deleted or expires

Daniel-Constantin Mierla miconda at gmail.com
Wed Jan 18 11:25:26 CET 2012


Hello,

On 1/18/12 10:53 AM, Giacomo Vacca wrote:
>
> Hi all,
>
> I've made a clean installation of kamailio 3.2.0 from 
> 'http://deb.kamailio.org/kamailio32 squeeze main'
>
> repository, on a squeeze debian machine (2.6.32-5-686).
>
can you switch to nightly builds from branch 3.2 just to be sure it is 
not related to something that was fixed since 3.2.0 was released? The 
repo are listed at:

http://www.kamailio.org/wiki/packages/debs#kamailio_32_-_nightly_builds

db_text is not really suitable for dealing with large data and write to 
disk when the sip server is shut down, maybe it is better to use 
db_sqlite for this case, at least you can check the content of the db 
table with sqlite tools.

Cheers,
Daniel


> Installed also kamailio-presence-modules, same version.
>
> I'm just using the default kamailio.cfg that comes with the package, 
> with these minimal additions:
>
> loadmodule "db_text.so"
>
> loadmodule "pua.so"
>
> loadmodule "pua_usrloc.so"
>
> ...
>
> modparam("pua", "db_url", "text:///usr/share/kamailio/dbtext/kamailio")
>
> modparam("pua_usrloc", "default_domain", "192.168.142.130")
>
> Inside the registration management logic I've added pua_set_publish() 
> right before saving the location:
>
> route[REGISTRAR] {
>
>         if (is_method("REGISTER"))
>
>         {
>
> ...
>
>                 pua_set_publish();
>
>                 if (!save("location"))
>
>                         sl_reply_error();
>
>                 exit;
>
>         }
>
> }
>
> When I first register (XLite 4.1 for Windows), pua_usrloc correctly 
> gets the callback and is able to generate a PUBLISH request through pua.
>
> But when there's an un-registration, or when the contact expires, even 
> if the callbacks are correctly fired, the PUBLISH (which I'd expect 
> with status 'closed') is not generated.
>
> From the logs (debug level 4), an un-registration:
>
> 8(7652) DEBUG: usrloc [ul_callback.h:89]: contact=0xb50ae7cc, callback 
> type 4/4, id 3 entered
>
> 8(7652) DEBUG: pua_usrloc [ul_publish.c:216]:DELETE type
>
> 8(7652) DEBUG: pua_usrloc [ul_publish.c:255]: uri= 
> sip:20701090 at 192.168.142.130
>
> 8(7652) DEBUG: pua_usrloc [ul_publish.c:66]: publ:
>
> 8(7652) DEBUG: pua_usrloc [ul_publish.c:67]: uri= 
> sip:20701090 at 192.168.142.130
>
> 8(7652) DEBUG: pua_usrloc [ul_publish.c:68]: 
> id=UL_PUBLISH.NmY5Zjc2YjcwNzEwNTk4YTY1NzA2Y2Y0MWQyMGRhOGY.
>
> 8(7652) DEBUG: pua_usrloc [ul_publish.c:69]: expires= 0
>
> 8(7652) DEBUG: pua [send_publish.c:403]: 
> pres_uri=sip:20701090 at 192.168.142.130
>
> 8(7652) DEBUG: pua [hash.c:121]: core_hash= 444
>
> 8(7652) DEBUG: pua [hash.c:174]: record not found
>
> 8(7652) DEBUG: pua [send_publish.c:444]: insert type
>
> 8(7652) DEBUG: pua [send_publish.c:448]: UPDATE_TYPE and no record found
>
> 8(7652) DEBUG: pua [send_publish.c:454]: request for a publish with 
> expires 0 and no record found
>
> 8(7652) DEBUG: sl [sl.c:278]: reply in stateless mode (sl)
>
> As an additional information, the pua table in
>
> /usr/share/kamailio/dbtext/kamailio/pua has not been populated.
>
> The AOR was correctly displayed with 'ul show' while the registration 
> was valid.
>
> Any suggestion on what am I be doing wrong?
>
> Would it be worth testing the same scenario using mysql as DB?
>
> Thanks in advance for your time.
>
> Giacomo
>
> Truphone Limited is a limited liability company registered in England 
> & Wales, registered office: 5 New Street Square, London EC4A 3TW. 
> Registered No. 04187081. VAT No. GB 851 5278 19.
>
> Truis a brand name of Truphone and is a Truphone Communications 
> Service. Truphone is a trading name for a number of distinct legal 
> entities that operate in combination. www.truphone.com 
> <http://www.truphone.com>.
>
>
> This e-mail, and any attachment(s), may contain information which is 
> confidential and/or privileged, and is intended for the addressee 
> only. If you are not the intended recipient, you may not use, 
> disclose, copy or distribute this information in any manner 
> whatsoever. If you have received this e-mail in error, please contact 
> the sender immediately and delete it.
>
>
> _______________________________________________
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users at lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users

-- 
Daniel-Constantin Mierla -- http://www.asipto.com
http://linkedin.com/in/miconda -- http://twitter.com/miconda

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.sip-router.org/pipermail/sr-users/attachments/20120118/917ccc3b/attachment.htm>


More information about the sr-users mailing list