We use mediaproxy and kamailio and using the init.d script from the Debian package to restart kamailio has no effect on mediaproxy process.
2013/2/8 Eduardo Lejarreta lejarreta.e@sarenet.es:
Good morning Victor.
As you mentioned I've been playing with init.d scripts in case you were right. Nothing to do with this. "media-dispatcher" and "media-relay" are still alive and with the same PID before and after "kamctl restart".
Kamailio gives some order to "media-dispatcher" so this last orders "media-relay" to close media ports.
I'm trying with Kamailio.cfg and code inspection once again.
I'll keep you informed now I know that someone has it working.
Thanks and regards.
Good evening.
Launching "mediaproxy-dispatcher" and "mediaproxy-relay" on the foreground and with "DEBUG" we can see:
mediaproxy-dispatcher log: ------------------------------------------------------------------> Kamctl restart debug: Connection to OpenSIPS lost: Connection was closed cleanly. debug: Connection to OpenSIPS lost: Connection was closed cleanly. debug: Connection to OpenSIPS lost: Connection was closed cleanly. debug: Issuing "remove" command to relay at A.B.C.D debug: Got statistics: {xxxxxxxxxxxxxxxxxxx} debug: Connection to OpenSIPS lost: Connection was closed cleanly.
mediaproxy-relay log: ------------------------------------------------------------------> Kamctl restart debug: removing session xxxxxxxxxxxxxxxxxxx (Port 50000 Closed) (Port 50001 Closed) (Port 50002 Closed) (Port 50003 Closed)
So "mediaproxy-dispatcher" doesn't receive any command from Kamailio, he just detects " Connection was closed cleanly" and then issues a "remove" command to "mediaproxy-relay".
Does anybody know any way to avoid this?
Thanks and regards.
Good morning Vinay.
I had this experience 1 year ago, so maybe Microsoft has improved something or our client has discovered new functionality.
Calling from Lync Server to Outside.
1.- You need to modparam("rr", "enable_full_lr", 0) just to avoid Loose Router parameter in this way "lr=on" and having like this "lr" (RFC3261 compliant). Microsoft denies traffic with "lr=on".
2.- At the time of my trials, our client or Microsoft was not able to authenticate, so we had to validate Lync through "trusted" table (IP auth).
3.- As always avoid ALG support on Lync Server side's Router/FW. You don't have to deal with UDP NAT timeouts as Lync only worked over TCP (you will also have to enable TCP support on Kamailio side).
4.- When detecting NAT on Kamailio side through nathelper module you will find a new issue with regard to nat_uac_test() which doesn't (as it's obvious) recognize "yourmicrosoftdomain.local". You have to deal to recompile nathelper.c introducing this exception or play with "contact header var" to correctly detect NAT.
Calling from the Outside to Lync Server:
1.- As there was no REGISTER from Lync Server you have to map your public IP address on you Router/FW to your Lync Server.
2.- You should send from Kamailio a RURI with DDI and filter this one to proper extension on your Lync Server side.
3.- As Microsoft was not able to REGISTER you also have to create a location entry on Kamailio database like: kamctl ul add <DDI> “sip:<DDI>@<yourLyncpublicIP>:5060;transport=tcp”
Hope this helps you.
I'm sorry Vinay.
I read it quickly so everything I've written is for just SIP calls purpose (no xmpp server experience).
Regards.
Hello once again !
Finally logs were confusing me. Kamailio through "mediaproxy.c" sends a "remove" command before dying.
I've been working with mediaproxy.c and dialog module callbacks but this is stuff for developers forum so I'm writing just to avoid someother to be confused.
There is solution working on mediaproxy.c playing with DLGCB_LOADED event.
Thanks to everyone.