Re: [SR-Users] Mediaproxy do not work well with Kamailio SIP server issue
|-+- | | dong-ming.li@mail.| | | foxconn.com | | | | | | 2014/12/24 上午 | | | 11:54 | |-+- --| | | | To: alfred...@foxconn.com | | cc: | | Subject:Mediaproxy do not work well with Kamailio SIP server issue | --| Secret Level: || | ( ) 1.Non-Confidential | | ( ) 2.Confidential | | ( ) 3.Secret | | ( ) 4.Top Secret | || Priority Level: || | ( ) 1.Normal | | ( ) 2.Urgent | | ( ) 3.Extra Urgent | || - Hi, sir, We try to setup Mediaproxy on CentOS 6.6 with kamailio-4.2.1 SIP server. We use Linphone android version as SIP client to test. attached kamailio.cfg.txt is our kamailio-4.2.1 SIP server config file. pls help to rename kamailio.cfg.txt to kamailio.cfg. kamailio-4.2.1 SIP server is run on public IP server,and Linphone SIP client is run behind NAT. The problem is that only callee can hear caller's rtp audio data. caller can not hear callee's audio data. And the call will auto disconnect after about 30s time out. Below's our modification regarding the kamailio.cfg file,pls help to check if this is OK or not ? #foxconn gallice add start MediaProxy module loadmodule mediaproxy.so modparam(mediaproxy, disable, 0) modparam(mediaproxy, ice_candidate, high-priority) modparam(mediaproxy, mediaproxy_socket, /var/run/mediaproxy/dispatcher.sock) modparam(mediaproxy, mediaproxy_timeout, 500) modparam(mediaproxy, signaling_ip_avp, $avp(nat_ip)) modparam(mediaproxy, media_relay_avp, $avp(media_relay)) #foxconn gallice add end # account only INVITEs if (is_method(INVITE)) { setflag(FLT_ACC); # do accounting use_media_proxy(); #foxconn gallice add } # Manage incoming replies onreply_route[MANAGE_REPLY] { xdbg(incoming reply\n); if(status=~[12][0-9][0-9]) { #foxconn gallice add #route(NATMANAGE); #foxconn gallice delete use_media_proxy(); #foxconn gallice add } #foxconn gallice add } For mediaproxy,we can see the media related processes are already run. 31212 ?SL 0:01 python ./media-dispatcher start 31218 ?SL 0:16 python ./media-relay start * dong-ming / 李東明 Foxconn Electronics Inc. HH Precision Ind. Co., Ltd. CNSBG NSDI TIPBU RD Dept. LH Office 地址:深圳市龍華新區龍華東環二路二號富士康科技集團 分機 : +86-0755-2812-9588 #26109 Mobile : 13510123670 Mail : dong-ming...@mail.foxconn.com, * 溫馨提醒﹕入廠人員須遵守富士康出入管制,請勿攜帶手提電腦、各種攝像、U盤、MP3 等存儲設備 本電子郵件及附件所載信息均為保密信息,受合同保護或依法不得洩漏。其內容僅供 指定收件人按限定範圍或特殊目的使用。未經授權者收到此信息均無權閱讀、 使用、 複製、洩漏或散佈。若您因為誤傳而收到本郵件或者非本郵件之指定收件人,請即刻 回覆郵件或致電Super Notes郵件客服熱線 560-104,並永久刪除此郵件及其附件和銷 毀所有複印件。謝謝您的合作! This e-mail message together with any attachments thereto (if any) is confidential, protected under an enforceable non-disclosure agreement, intended only for the use of the named recipient(s) above and may contain information that is privileged, belonging to professional work products or exempt from disclosure under applicable laws.Any unauthorized review, use, copying, disclosure, or distribution of any information contained in or attached to this transmission is STRICTLY PROHIBITED and may be against the laws. If you have received
Re: [SR-Users] [sr-dev] Missing accounting events in ACC table
See attached SIP trace. Note, i have obfuscated source and destination number and IPs etc. due to privacy reasons. Thank you. On Wed, Dec 24, 2014 at 10:36 AM, Muhammad Shahzad shaherya...@gmail.com wrote: OK, i will upgrade my staging server and do some testing. The acc module does not post records anywhere, neither syslog nor db. The problem is happening to all calls (not any specific call). Regarding the FROM header, the only change done is to add + to callerid (after replacing 00 if present), this is extensively tested feature in past 6 months. I have analyzed all the SIP packets in call using ngrep, they all seem perfectly fine. All packets (request + reply) are correctly received and forwarded by kamailio. Unfortunately i deleted them and need to get new trace. I will send it to you in the afternoon. Thank you. On Tue, Dec 23, 2014 at 10:10 PM, Daniel-Constantin Mierla mico...@gmail.com wrote: Hello, you can try with latest git branch 4.2 and see the results. At a quick look between the version you reported to work and the new version you run, I couldn't spot a commit that could be the reason. Do you get the acc record in syslog for INVITE? How do you set the values for replacing From header? If you load from database, be sure the values are valid. I see the uac module complains about restoring operation. It might be the reason for the issues -- config could be ok, but the subscriber data wrong. You should save the traffic for a while and check the packets for missing records -- you can use tools such as tcpdump, sipgrep, ngrep to store the traffic in a file for later analysis. When you find a missing record, search in the file with the sip traffic and see if something is broken there. Cheers, Daniel On 23/12/14 21:45, Muhammad Shahzad wrote: Hi, About 3 weeks ago i upgraded one of my production server with latest stable kamailio version 4.2.1-fad00a. Now i am getting a lot of complaints about missing CDR events in ACC table. I observe following problems, 1. There are only BYE records in acc table, no record for INVITE or ACK. 2. In kamailio logs when ACK is received against 200 OK response for INVITE, i see following errors, -- ERROR: core [parser/parse_from.c:113]: parse_from_uri(): failed to parse From uri ERROR: pv [pv_core.c:434]: pv_get_xto_attr(): cannot parse From URI NOTICE: script: [udp:null@1.0.0.127:5060]: Call from ' y...@kamailio.org' to 'y...@kamailio.org' has been hanged up by 'null' at '1419364717.255484' -- Of course all these errors are bogus, I have checked all headers in ACK (not just FROM header), they all seem perfectly fine and valid. 3. Then the dialog times out, -- WARNING: dialog [dlg_handlers.c:1440]: dlg_ontimeout(): timeout for dlg with CallID '6D8BD23CAC65AE3C1DE1D0B531F87B8CFEAA9CB9' and tags '1D3ECD34F5731AB845BA3064AC95BB2D' '7f55e81e0630-17f-13c4-6009-2440a4-5fa31570-2440a4' -- 4. Any further sequential requests complain about unable to find dialog, e.g. -- NOTICE: script: Sequencial 'BYE' request received from caller ERROR: uac [replace.c:591]: restore_uri(): new URI [] shorter than old URI [sip:00xxx...@sip.domain.com] WARNING: dialog [dlg_handlers.c:1174]: dlg_onroute(): unable to find dialog for BYE with route param '5ae1.d595' [7845:22877] -- 5. However the acc record for BYE is written to db and log file, -- NOTICE: acc [acc.c:318]: acc_log_request(): ACC: transaction answered: timestamp=1419364760;method=BYE;from_tag=7f55e81e0630-17f-13c4-6009-2440a4-5fa31570-2440a4;to_tag=1D3ECD34F5731AB845BA3064AC95BB2D;call_id=6D8BD23CAC65AE3C1DE1D0B531F87B8CFEAA9CB9;code=200;reason=OK;src_user=00xx;src_domain= sip.domain.com ;src_ip=xx.xx.xx.xx;dst_ouser=+1xx;dst_user=1xx;dst_domain=yy.yy.yy.yy -- The same config was working fine with older version 4.2.0-97cab8. The kamailio config i am using is pretty much standard, -- #!define FLT_ACC 1 #!define FLT_ACCMISSED 2 #!define FLT_ACCFAILED 3 #!define FLT_DLG 4 ... modparam(acc, early_media, 1) modparam(acc, report_ack, 1) modparam(acc, report_cancels, 1) modparam(acc, detect_direction, 1) modparam(acc, log_flag, FLT_ACC) modparam(acc, log_missed_flag, FLT_ACCMISSED) modparam(acc, failed_transaction_flag, FLT_ACCFAILED) # log to db modparam(acc, db_flag, FLT_ACC) modparam(acc, db_missed_flag, FLT_ACCMISSED) modparam(acc, db_url, DBURL) ... request_route { # per request initial checks route(REQINIT); # NAT detection route(NATDETECT); # handle requests within SIP dialogs route(WITHINDLG); # CANCEL processing if (is_method(CANCEL)) { if (t_check_trans()) { t_relay(); }; exit; }; only initial requests (no To tag) t_check_trans(); # account only INVITEs if (is_method(INVITE)) { setflag(FLT_DLG); # create dialog
[SR-Users] Dispatcher weight nor working
Hello. We use kamailio 4.3 and dispatcher with 9 algorithm. We use db instanse for dispatcher and at attrs column for our backend servers set WEIGHT=40 and 60 for first and second server, but packets sended only at first server ignoring weight ___ SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
Re: [SR-Users] [sr-dev] Missing accounting events in ACC table
Looking at log level 3 logs, i see when INVITE has been authenticated ACC module creates the dialog, -- DEBUG: acc [acc_cdr.c:726]: cdr_on_create(): dialog '0xa5936e70' created! -- But acc callback is only triggered AFTER 200 OK of BYE request, -- DEBUG: acc [acc_logic.c:644]: tmcb_func(): acc callback called for t(0xa591d840) event type 2, reply code 200 -- Between these two log lines there is no log from acc module. Thank you. On Wed, Dec 24, 2014 at 11:04 AM, Muhammad Shahzad shaherya...@gmail.com wrote: See attached SIP trace. Note, i have obfuscated source and destination number and IPs etc. due to privacy reasons. Thank you. On Wed, Dec 24, 2014 at 10:36 AM, Muhammad Shahzad shaherya...@gmail.com wrote: OK, i will upgrade my staging server and do some testing. The acc module does not post records anywhere, neither syslog nor db. The problem is happening to all calls (not any specific call). Regarding the FROM header, the only change done is to add + to callerid (after replacing 00 if present), this is extensively tested feature in past 6 months. I have analyzed all the SIP packets in call using ngrep, they all seem perfectly fine. All packets (request + reply) are correctly received and forwarded by kamailio. Unfortunately i deleted them and need to get new trace. I will send it to you in the afternoon. Thank you. On Tue, Dec 23, 2014 at 10:10 PM, Daniel-Constantin Mierla mico...@gmail.com wrote: Hello, you can try with latest git branch 4.2 and see the results. At a quick look between the version you reported to work and the new version you run, I couldn't spot a commit that could be the reason. Do you get the acc record in syslog for INVITE? How do you set the values for replacing From header? If you load from database, be sure the values are valid. I see the uac module complains about restoring operation. It might be the reason for the issues -- config could be ok, but the subscriber data wrong. You should save the traffic for a while and check the packets for missing records -- you can use tools such as tcpdump, sipgrep, ngrep to store the traffic in a file for later analysis. When you find a missing record, search in the file with the sip traffic and see if something is broken there. Cheers, Daniel On 23/12/14 21:45, Muhammad Shahzad wrote: Hi, About 3 weeks ago i upgraded one of my production server with latest stable kamailio version 4.2.1-fad00a. Now i am getting a lot of complaints about missing CDR events in ACC table. I observe following problems, 1. There are only BYE records in acc table, no record for INVITE or ACK. 2. In kamailio logs when ACK is received against 200 OK response for INVITE, i see following errors, -- ERROR: core [parser/parse_from.c:113]: parse_from_uri(): failed to parse From uri ERROR: pv [pv_core.c:434]: pv_get_xto_attr(): cannot parse From URI NOTICE: script: [udp:null@1.0.0.127:5060]: Call from ' y...@kamailio.org' to 'y...@kamailio.org' has been hanged up by 'null' at '1419364717.255484' -- Of course all these errors are bogus, I have checked all headers in ACK (not just FROM header), they all seem perfectly fine and valid. 3. Then the dialog times out, -- WARNING: dialog [dlg_handlers.c:1440]: dlg_ontimeout(): timeout for dlg with CallID '6D8BD23CAC65AE3C1DE1D0B531F87B8CFEAA9CB9' and tags '1D3ECD34F5731AB845BA3064AC95BB2D' '7f55e81e0630-17f-13c4-6009-2440a4-5fa31570-2440a4' -- 4. Any further sequential requests complain about unable to find dialog, e.g. -- NOTICE: script: Sequencial 'BYE' request received from caller ERROR: uac [replace.c:591]: restore_uri(): new URI [] shorter than old URI [sip:00xxx...@sip.domain.com] WARNING: dialog [dlg_handlers.c:1174]: dlg_onroute(): unable to find dialog for BYE with route param '5ae1.d595' [7845:22877] -- 5. However the acc record for BYE is written to db and log file, -- NOTICE: acc [acc.c:318]: acc_log_request(): ACC: transaction answered: timestamp=1419364760;method=BYE;from_tag=7f55e81e0630-17f-13c4-6009-2440a4-5fa31570-2440a4;to_tag=1D3ECD34F5731AB845BA3064AC95BB2D;call_id=6D8BD23CAC65AE3C1DE1D0B531F87B8CFEAA9CB9;code=200;reason=OK;src_user=00xx;src_domain= sip.domain.com ;src_ip=xx.xx.xx.xx;dst_ouser=+1xx;dst_user=1xx;dst_domain=yy.yy.yy.yy -- The same config was working fine with older version 4.2.0-97cab8. The kamailio config i am using is pretty much standard, -- #!define FLT_ACC 1 #!define FLT_ACCMISSED 2 #!define FLT_ACCFAILED 3 #!define FLT_DLG 4 ... modparam(acc, early_media, 1) modparam(acc, report_ack, 1) modparam(acc, report_cancels, 1) modparam(acc, detect_direction, 1) modparam(acc, log_flag, FLT_ACC) modparam(acc, log_missed_flag, FLT_ACCMISSED) modparam(acc, failed_transaction_flag, FLT_ACCFAILED) # log to db modparam(acc, db_flag, FLT_ACC) modparam(acc, db_missed_flag, FLT_ACCMISSED) modparam(acc, db_url,
Re: [SR-Users] [sr-dev] Missing accounting events in ACC table
After upgrade to version 4.2.1-a2aa22, result is same. Thank you. On Wed, Dec 24, 2014 at 1:32 PM, Muhammad Shahzad shaherya...@gmail.com wrote: Looking at log level 3 logs, i see when INVITE has been authenticated ACC module creates the dialog, -- DEBUG: acc [acc_cdr.c:726]: cdr_on_create(): dialog '0xa5936e70' created! -- But acc callback is only triggered AFTER 200 OK of BYE request, -- DEBUG: acc [acc_logic.c:644]: tmcb_func(): acc callback called for t(0xa591d840) event type 2, reply code 200 -- Between these two log lines there is no log from acc module. Thank you. On Wed, Dec 24, 2014 at 11:04 AM, Muhammad Shahzad shaherya...@gmail.com wrote: See attached SIP trace. Note, i have obfuscated source and destination number and IPs etc. due to privacy reasons. Thank you. On Wed, Dec 24, 2014 at 10:36 AM, Muhammad Shahzad shaherya...@gmail.com wrote: OK, i will upgrade my staging server and do some testing. The acc module does not post records anywhere, neither syslog nor db. The problem is happening to all calls (not any specific call). Regarding the FROM header, the only change done is to add + to callerid (after replacing 00 if present), this is extensively tested feature in past 6 months. I have analyzed all the SIP packets in call using ngrep, they all seem perfectly fine. All packets (request + reply) are correctly received and forwarded by kamailio. Unfortunately i deleted them and need to get new trace. I will send it to you in the afternoon. Thank you. On Tue, Dec 23, 2014 at 10:10 PM, Daniel-Constantin Mierla mico...@gmail.com wrote: Hello, you can try with latest git branch 4.2 and see the results. At a quick look between the version you reported to work and the new version you run, I couldn't spot a commit that could be the reason. Do you get the acc record in syslog for INVITE? How do you set the values for replacing From header? If you load from database, be sure the values are valid. I see the uac module complains about restoring operation. It might be the reason for the issues -- config could be ok, but the subscriber data wrong. You should save the traffic for a while and check the packets for missing records -- you can use tools such as tcpdump, sipgrep, ngrep to store the traffic in a file for later analysis. When you find a missing record, search in the file with the sip traffic and see if something is broken there. Cheers, Daniel On 23/12/14 21:45, Muhammad Shahzad wrote: Hi, About 3 weeks ago i upgraded one of my production server with latest stable kamailio version 4.2.1-fad00a. Now i am getting a lot of complaints about missing CDR events in ACC table. I observe following problems, 1. There are only BYE records in acc table, no record for INVITE or ACK. 2. In kamailio logs when ACK is received against 200 OK response for INVITE, i see following errors, -- ERROR: core [parser/parse_from.c:113]: parse_from_uri(): failed to parse From uri ERROR: pv [pv_core.c:434]: pv_get_xto_attr(): cannot parse From URI NOTICE: script: [udp:null@1.0.0.127:5060]: Call from ' y...@kamailio.org' to 'y...@kamailio.org' has been hanged up by 'null' at '1419364717.255484' -- Of course all these errors are bogus, I have checked all headers in ACK (not just FROM header), they all seem perfectly fine and valid. 3. Then the dialog times out, -- WARNING: dialog [dlg_handlers.c:1440]: dlg_ontimeout(): timeout for dlg with CallID '6D8BD23CAC65AE3C1DE1D0B531F87B8CFEAA9CB9' and tags '1D3ECD34F5731AB845BA3064AC95BB2D' '7f55e81e0630-17f-13c4-6009-2440a4-5fa31570-2440a4' -- 4. Any further sequential requests complain about unable to find dialog, e.g. -- NOTICE: script: Sequencial 'BYE' request received from caller ERROR: uac [replace.c:591]: restore_uri(): new URI [] shorter than old URI [sip:00xxx...@sip.domain.com] WARNING: dialog [dlg_handlers.c:1174]: dlg_onroute(): unable to find dialog for BYE with route param '5ae1.d595' [7845:22877] -- 5. However the acc record for BYE is written to db and log file, -- NOTICE: acc [acc.c:318]: acc_log_request(): ACC: transaction answered: timestamp=1419364760;method=BYE;from_tag=7f55e81e0630-17f-13c4-6009-2440a4-5fa31570-2440a4;to_tag=1D3ECD34F5731AB845BA3064AC95BB2D;call_id=6D8BD23CAC65AE3C1DE1D0B531F87B8CFEAA9CB9;code=200;reason=OK;src_user=00xx;src_domain= sip.domain.com ;src_ip=xx.xx.xx.xx;dst_ouser=+1xx;dst_user=1xx;dst_domain=yy.yy.yy.yy -- The same config was working fine with older version 4.2.0-97cab8. The kamailio config i am using is pretty much standard, -- #!define FLT_ACC 1 #!define FLT_ACCMISSED 2 #!define FLT_ACCFAILED 3 #!define FLT_DLG 4 ... modparam(acc, early_media, 1) modparam(acc, report_ack, 1) modparam(acc, report_cancels, 1) modparam(acc, detect_direction, 1) modparam(acc, log_flag, FLT_ACC) modparam(acc, log_missed_flag, FLT_ACCMISSED)
Re: [SR-Users] Media trouble with kamailio/rtpengine
On Fri, Dec 19, 2014 at 12:31 PM, Richard Fuchs rfu...@sipwise.com wrote: You've caught the same thing as Juha did just earlier, Firefox is doing something new called Trickle ICE, which at the moment breaks communications with endpoints not supporting it (such as rtpengine). I figured out the issue. It was totally client related. Are there plans for rtpengine support trickle ICE anytime soon? My (limited) understand is that without it I can't support Firefox WebRTC clients. Thanks, Marc ___ SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
[SR-Users] Merry Christmas!
Another year getting slowly to the end, an excellent opportunity to thank to all old and new friends of Kamailio project, from contributing code to using it, helping on mailing lists and other places online, or advertising it across the world! Merry Christmas and Happy Winter Holidays! Daniel -- Daniel-Constantin Mierla http://twitter.com/#!/miconda - http://www.linkedin.com/in/miconda ___ SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
Re: [SR-Users] [sr-dev] Merry Christmas!
Thank you very much and Merry Christmas! 2014-12-24 23:04 GMT+03:00 Daniel-Constantin Mierla mico...@gmail.com: Another year getting slowly to the end, an excellent opportunity to thank to all old and new friends of Kamailio project, from contributing code to using it, helping on mailing lists and other places online, or advertising it across the world! Merry Christmas and Happy Winter Holidays! Daniel -- Daniel-Constantin Mierla http://twitter.com/#!/miconda - http://www.linkedin.com/in/miconda ___ sr-dev mailing list sr-...@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-dev ___ SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
Re: [SR-Users] [sr-dev] Merry Christmas!
Hi Daniel Thanks so much and Happy Holidays to you and yours also. All the best from me. Will On Wed, Dec 24, 2014 at 5:53 PM, Konstantin M. evilz...@gmail.com wrote: Thank you very much and Merry Christmas! 2014-12-24 23:04 GMT+03:00 Daniel-Constantin Mierla mico...@gmail.com: Another year getting slowly to the end, an excellent opportunity to thank to all old and new friends of Kamailio project, from contributing code to using it, helping on mailing lists and other places online, or advertising it across the world! Merry Christmas and Happy Winter Holidays! Daniel -- Daniel-Constantin Mierla http://twitter.com/#!/miconda - http://www.linkedin.com/in/miconda ___ sr-dev mailing list sr-...@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-dev ___ SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users ___ SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
Re: [SR-Users] [sr-dev] Merry Christmas!
Thanks to entire Kamailio community, especially to Daniel for excellent and to-the-point help and support. Happy holidays of birth of Jesus and Muhammad to everyone. Thank you. On Thu, Dec 25, 2014 at 1:58 AM, Will Ferrer will.fer...@switchsoft.com wrote: Hi Daniel Thanks so much and Happy Holidays to you and yours also. All the best from me. Will On Wed, Dec 24, 2014 at 5:53 PM, Konstantin M. evilz...@gmail.com wrote: Thank you very much and Merry Christmas! 2014-12-24 23:04 GMT+03:00 Daniel-Constantin Mierla mico...@gmail.com: Another year getting slowly to the end, an excellent opportunity to thank to all old and new friends of Kamailio project, from contributing code to using it, helping on mailing lists and other places online, or advertising it across the world! Merry Christmas and Happy Winter Holidays! Daniel -- Daniel-Constantin Mierla http://twitter.com/#!/miconda - http://www.linkedin.com/in/miconda ___ sr-dev mailing list sr-...@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-dev ___ SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users ___ SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users ___ SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users