Re: [SR-Users] kamctl fifo command not responding
Hello, do you get anything in kamailio log messages when the fifo is not responding? What version of kamailio do you have? Removing and creating a new one will not help, since kamailio will not reopen, so practically will still use the old file descriptor. Cheers, Daniel On 1/18/11 10:54 AM, Anton Roman wrote: Hi all, I'm having trouble trying to execute fifo commands with kamctl fifo command. Just after restarting Kamailio it works fine, however, sometimes after some days running it doesn't respond. kamailio1:~#*kamctl fifo which* It doesn't respond so I input *Crtl+c* and I get: /usr/local/lib/kamailio//kamctl/kamctl.fifo: line 89: /tmp/kamailio_fifo: Interrupted system call If I delete and create the fifo file again (with rm /tmp/kamailio_fifo and mkfifo /tmp/kamailio_fifo and chmod 660 /tmp/kamailio_fifo) it keeps not responding. Any help is welcome, what can be happening? Below you can find info about the pipe and the running kamailio. Thanks in advance, Best regards Antón kamailio1:~# *ls -hall /tmp/kamailio_fifo * prw-rw 1 root root 0 ene 17 12:01 /tmp/kamailio_fifo After deleting and creating the fifo file again: kamailio1:~# *ls -hall /tmp/kamailio_fifo * prw-rw-r-- 1 root root 0 ene 18 10:28 /tmp/kamailio_fifo kamailio1:~#*ps -ef | grep kama* root 17369 17245 0 10:12 pts/000:00:00 grep kama kamailio 23277 1 0 Jan15 ?00:00:00 /usr/local/sbin/kamailio -P /var/run/kamailio/kamailio.pid -m 512 -u kamailio -g kamailio kamailio 23289 23277 0 Jan15 ?00:00:00 /usr/local/sbin/kamailio -P /var/run/kamailio/kamailio.pid -m 512 -u kamailio -g kamailio kamailio 23291 23277 0 Jan15 ?00:00:00 /usr/local/sbin/kamailio -P /var/run/kamailio/kamailio.pid -m 512 -u kamailio -g kamailio kamailio 23293 23277 0 Jan15 ?00:00:00 /usr/local/sbin/kamailio -P /var/run/kamailio/kamailio.pid -m 512 -u kamailio -g kamailio kamailio 23294 23277 0 Jan15 ?00:00:00 /usr/local/sbin/kamailio -P /var/run/kamailio/kamailio.pid -m 512 -u kamailio -g kamailio kamailio 23295 23277 0 Jan15 ?00:01:14 /usr/local/sbin/kamailio -P /var/run/kamailio/kamailio.pid -m 512 -u kamailio -g kamailio kamailio 23299 23277 0 Jan15 ?00:01:13 /usr/local/sbin/kamailio -P /var/run/kamailio/kamailio.pid -m 512 -u kamailio -g kamailio kamailio 23300 23277 0 Jan15 ?00:01:13 /usr/local/sbin/kamailio -P /var/run/kamailio/kamailio.pid -m 512 -u kamailio -g kamailio kamailio 23303 23277 0 Jan15 ?00:01:13 /usr/local/sbin/kamailio -P /var/run/kamailio/kamailio.pid -m 512 -u kamailio -g kamailio kamailio 23305 23277 0 Jan15 ?00:05:29 /usr/local/sbin/kamailio -P /var/run/kamailio/kamailio.pid -m 512 -u kamailio -g kamailio kamailio 23306 23277 0 Jan15 ?00:05:33 /usr/local/sbin/kamailio -P /var/run/kamailio/kamailio.pid -m 512 -u kamailio -g kamailio kamailio 23309 23277 0 Jan15 ?00:05:30 /usr/local/sbin/kamailio -P /var/run/kamailio/kamailio.pid -m 512 -u kamailio -g kamailio kamailio 23311 23277 0 Jan15 ?00:05:31 /usr/local/sbin/kamailio -P /var/run/kamailio/kamailio.pid -m 512 -u kamailio -g kamailio kamailio 23312 23277 0 Jan15 ?00:00:02 /usr/local/sbin/kamailio -P /var/run/kamailio/kamailio.pid -m 512 -u kamailio -g kamailio kamailio 23313 23277 0 Jan15 ?00:00:39 /usr/local/sbin/kamailio -P /var/run/kamailio/kamailio.pid -m 512 -u kamailio -g kamailio kamailio 23315 23277 0 Jan15 ?00:00:00 /usr/local/sbin/kamailio -P /var/run/kamailio/kamailio.pid -m 512 -u kamailio -g kamailio kamailio 23320 23277 0 Jan15 ?00:00:00 /usr/local/sbin/kamailio -P /var/run/kamailio/kamailio.pid -m 512 -u kamailio -g kamailio kamailio 23321 23277 0 Jan15 ?00:00:00 /usr/local/sbin/kamailio -P /var/run/kamailio/kamailio.pid -m 512 -u kamailio -g kamailio kamailio 23322 23277 0 Jan15 ?00:00:05 /usr/local/sbin/kamailio -P /var/run/kamailio/kamailio.pid -m 512 -u kamailio -g kamailio kamailio 23323 23277 0 Jan15 ?00:00:00 /usr/local/sbin/kamailio -P /var/run/kamailio/kamailio.pid -m 512 -u kamailio -g kamailio ___ 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 -- Daniel-Constantin Mierla Kamailio (OpenSER) Advanced Training Jan 24-26, 2011, Irvine, CA, USA http://www.asipto.com ___ 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] Return code after fr_inv_timer hit
Do you have failed transaction accounting enabled? Can you watch the sip traffic (ngrep, wireshark), is the 408 sent to caller as well? Cheers, Daniel On 1/18/11 10:54 AM, Mino Haluz wrote: So failure_route[FAIL_ONE] { ... if (t_check_status(408)) { t_reply(480,Temporarily Unavailable); exit; } } Thank you, but I am encountering particular problem, that there are 2 messages stored in the radius, the original 408 and my 480 Temporarily unavailabe. Can I force to do not write that original 408 to radius? On Fri, Jan 14, 2011 at 10:39 AM, Klaus Darilion klaus.mailingli...@pernau.at wrote: Am 14.01.2011 10:28, schrieb Mino Haluz: Hi, I would like to force kamailio to send another code as Request timeout when fr invite timeout is hit. Is there some nice way how to achieve it, or I have to edit the code ? :( activate a failure route: t_on_failure(foo) then in failure route check for the status (e.g. 408): failure_route[foo] { ... if (t_check_status(487)) { t_reply(499,or what ever you want); exit; } ... } regards klaus ___ 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 -- Daniel-Constantin Mierla Kamailio (OpenSER) Advanced Training Jan 24-26, 2011, Irvine, CA, USA http://www.asipto.com ___ 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] ACK problem with FreeSwitch-Kamailio SBC implementation.
___ 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 -- Daniel-Constantin Mierla Kamailio (OpenSER) Advanced Training Jan 24-26, 2011, Irvine, CA, USA http://www.asipto.com ___ 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] kamctl fifo command not responding
Hello, do you have ctl module loaded? If yes, you can connect with sercmd and get the pid of the fifo listener: sercmd ps Then connect with gdb: gdb /path/to/kamailio pidoffifolistener and get the backtrace. That should show what the fifo process is doing. Also, you can get the pid of fifo process at startup, with kamctl ps, store it for the time when it blocks in order to use it with gdb. I haven't encountered this issue, do you have lot of communication over fifo file? How many commands and how often are sent through fifo file? Cheers, Daniel On 1/18/11 11:52 AM, Anton Roman wrote: Hi, my reply is inline 2011/1/18 Daniel-Constantin Mierla mico...@gmail.com mailto:mico...@gmail.com Hello, do you get anything in kamailio log messages when the fifo is not responding? No, I didn't find anything regarding the fifo command in the logs. What version of kamailio do you have? kamailio-3.0.2, the last time we updated the code was on August 1st, since then it is in production. Removing and creating a new one will not help, since kamailio will not reopen, so practically will still use the old file descriptor. It makes all the sense. Cheers, Daniel Thank you very much, regards, Anton On 1/18/11 10:54 AM, Anton Roman wrote: Hi all, I'm having trouble trying to execute fifo commands with kamctl fifo command. Just after restarting Kamailio it works fine, however, sometimes after some days running it doesn't respond. kamailio1:~#*kamctl fifo which* It doesn't respond so I input *Crtl+c* and I get: /usr/local/lib/kamailio//kamctl/kamctl.fifo: line 89: /tmp/kamailio_fifo: Interrupted system call If I delete and create the fifo file again (with rm /tmp/kamailio_fifo and mkfifo /tmp/kamailio_fifo and chmod 660 /tmp/kamailio_fifo) it keeps not responding. Any help is welcome, what can be happening? Below you can find info about the pipe and the running kamailio. Thanks in advance, Best regards Antón kamailio1:~# *ls -hall /tmp/kamailio_fifo * prw-rw 1 root root 0 ene 17 12:01 /tmp/kamailio_fifo After deleting and creating the fifo file again: kamailio1:~# *ls -hall /tmp/kamailio_fifo * prw-rw-r-- 1 root root 0 ene 18 10:28 /tmp/kamailio_fifo kamailio1:~#*ps -ef | grep kama* root 17369 17245 0 10:12 pts/000:00:00 grep kama kamailio 23277 1 0 Jan15 ?00:00:00 /usr/local/sbin/kamailio -P /var/run/kamailio/kamailio.pid -m 512 -u kamailio -g kamailio kamailio 23289 23277 0 Jan15 ?00:00:00 /usr/local/sbin/kamailio -P /var/run/kamailio/kamailio.pid -m 512 -u kamailio -g kamailio kamailio 23291 23277 0 Jan15 ?00:00:00 /usr/local/sbin/kamailio -P /var/run/kamailio/kamailio.pid -m 512 -u kamailio -g kamailio kamailio 23293 23277 0 Jan15 ?00:00:00 /usr/local/sbin/kamailio -P /var/run/kamailio/kamailio.pid -m 512 -u kamailio -g kamailio kamailio 23294 23277 0 Jan15 ?00:00:00 /usr/local/sbin/kamailio -P /var/run/kamailio/kamailio.pid -m 512 -u kamailio -g kamailio kamailio 23295 23277 0 Jan15 ?00:01:14 /usr/local/sbin/kamailio -P /var/run/kamailio/kamailio.pid -m 512 -u kamailio -g kamailio kamailio 23299 23277 0 Jan15 ?00:01:13 /usr/local/sbin/kamailio -P /var/run/kamailio/kamailio.pid -m 512 -u kamailio -g kamailio kamailio 23300 23277 0 Jan15 ?00:01:13 /usr/local/sbin/kamailio -P /var/run/kamailio/kamailio.pid -m 512 -u kamailio -g kamailio kamailio 23303 23277 0 Jan15 ?00:01:13 /usr/local/sbin/kamailio -P /var/run/kamailio/kamailio.pid -m 512 -u kamailio -g kamailio kamailio 23305 23277 0 Jan15 ?00:05:29 /usr/local/sbin/kamailio -P /var/run/kamailio/kamailio.pid -m 512 -u kamailio -g kamailio kamailio 23306 23277 0 Jan15 ?00:05:33 /usr/local/sbin/kamailio -P /var/run/kamailio/kamailio.pid -m 512 -u kamailio -g kamailio kamailio 23309 23277 0 Jan15 ?00:05:30 /usr/local/sbin/kamailio -P /var/run/kamailio/kamailio.pid -m 512 -u kamailio -g kamailio kamailio 23311 23277 0 Jan15 ?00:05:31 /usr/local/sbin/kamailio -P /var/run/kamailio/kamailio.pid -m 512 -u kamailio -g kamailio kamailio 23312 23277 0 Jan15 ?00:00:02 /usr/local/sbin/kamailio -P /var/run/kamailio/kamailio.pid -m 512 -u kamailio -g kamailio kamailio 23313 23277 0 Jan15 ?00:00:39 /usr/local/sbin/kamailio -P /var/run/kamailio/kamailio.pid -m 512 -u kamailio -g kamailio kamailio 23315 23277 0 Jan15 ?00:00:00 /usr/local/sbin/kamailio -P /var/run/kamailio/kamailio.pid -m 512 -u kamailio -g kamailio kamailio 23320 23277 0 Jan15 ?00:00:00 /usr/local/sbin/kamailio -P /var/run/kamailio/kamailio.pid -m 512 -u kamailio -g kamailio kamailio
Re: [SR-Users] Merging nathelper modules
Hello, On 1/13/11 7:38 PM, Ovidiu Sas wrote: Hello all, The nathelper module in modules_k was split in two: - nathelper (dealing with signaling); - rtpproxy (dealing with rtpproxy protocol). I would like to move the rtpproxy module from modules_k into modules and remove rtpproxy functionality from nathelper (s). This will give to (s) and (k) users: - rtpproxy: a single module for dealing with rtpproxy servers; - nathelper: two variants for dealing with NAT signaling. Next step, will be to merge the two nathelper modules into a single one. Thoughts? it is fine with me. Thanks, Daniel -- Daniel-Constantin Mierla Kamailio (OpenSER) Advanced Training Jan 24-26, 2011, Irvine, CA, USA http://www.asipto.com ___ 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] avp_db_query() question
Hello, maybe is better to use sqlops module, it more suitable for queries with many records in result. http://kamailio.org/docs/modules/stable/modules_k/sqlops.html Cheers, Daniel On 1/19/11 2:58 PM, Klaus Darilion wrote: looks fine. try to increase debug level - then you should see the query and the results in syslog regards klaus Am 18.01.2011 12:07, schrieb ??: Hello |avp_db_query(query[,dest]) can get a database query and store the results in the avps.| |But what if the results returns many rows,and how can I get all the results? How to set the [dest] parameter ?| |I've tried the method describered in http://www.kamailio.org/docs/avp_db_query.html,but it doesn't work.| |like below| |mysqlselect mem_user from tgroup where grp_name='1234';| |+--+| || mem_user || |+--+| || 1013 || || 2013 || |+--+| |2 rows in set (0.00 sec)| |kamailio.cfg| |if(avp_db_query(select mem_user from tgroup where grp_name='1234',$avp(name)))| |{| |||xlog(L_INFO,query results[1] :$avp(name[1])\n);| |xlog(L_INFO,query results[2] :$avp(name[2])\n);| |}| |syslog| |INFO query results[1] :null| |INFO query results[2] :null| |version: kamailio 3.0.2 MySQL 5.0| || |thank you very much!| ___ 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 -- Daniel-Constantin Mierla Kamailio (OpenSER) Advanced Training Jan 24-26, 2011, Irvine, CA, USA http://www.asipto.com ___ 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] Float Comparison
On 1/19/11 7:50 AM, Klaus Darilion wrote: Am 18.01.2011 21:26, schrieb Brandon Armstead: Hello, Is there anything special that needs to be done for float comparison? For example: if([5.5 = 4.3]) ^^^ this format is no longer supported starting with 3.0, just skip the square brackets, now it is working like in C. or if(5.5 4.3) The conditional does not seem to be coming back as true like it should? I have no idea if floating point comparison is supported, but you could multiple the values (e.g. * 1) before comparison The pseudo-variables can hold integer or strings. Do you do comparison with static values or you load the values in some variables and then compare? Cheers, Daniel -- Daniel-Constantin Mierla Kamailio (OpenSER) Advanced Training Jan 24-26, 2011, Irvine, CA, USA http://www.asipto.com ___ 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] Handling call transfer in the Asterisk Realtime setup.
On 1/16/11 7:32 PM, David J. wrote: I am trying to add support for call transfer in the Asterisk realtime tutorial on Asipto; I am not sure what I would have to do to get this feature working; Perhaps I have to handle refer messages; but I am not sure how I send that to Asterisk; Any advice would be greatly appreciated. Kamailio has only the role of the proxy in this case. The REFER should be just forwarded to asterisk like any other request intended for callee. Cheers, Daniel -- Daniel-Constantin Mierla Kamailio (OpenSER) Advanced Training Jan 24-26, 2011, Irvine, CA, USA http://www.asipto.com ___ 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] Refer Using UAC.
private mails are simply ignored after first advise in this regard, please CC the mailing list always. If you read the config from the tutorial, you see how the invite is relayed to asterisk. Refer should go to asterisk in the same way if it is an out of dialog request, or follow record route/contact address for within dialog requests. Cheers, Daniel On 1/20/11 11:37 AM, David J. wrote: could you point me to the docs? just use forward() or rewritehostport()? On 1/20/11 5:15 AM, Daniel-Constantin Mierla wrote: If asterisk is in the path of the call, then just forward the REFER to it, there is no need to generate a new one. Also, note that REFER is many times part of a dialog, uac_req_send() creates requests out of the dialog. Cheers, Daniel On 1/16/11 11:37 PM, David J. wrote: I realize that kamailio is not a b2bua; But because we are using Asterisk in the path; To extend the Asterisk Realtime Tutorial; I was wondering if I could do something like this... Kind of like how we use UAC to send a register to Asterisk; Could we do the same and modify the method to use REFER instead? I know it is more complex; but I am not sure where to handle this case; Thanks for any pointers. if(is_method(REFER)){ $var(rip) = $sel(cfg_get.asterisk.bindip); $uac_req(method)=REFER; $uac_req(ruri)=sip: + $var(rip) + : + $sel(cfg_get.asterisk.bindport); $uac_req(furi)=sip: + $au + @ + $var(rip) + ;tag= + $ft; $uac_req(turi)=sip: + $au + @ + $var(rip) + ;tag= + $tt; $uac_req(hdrs)=Contact: sip: + $au + @ + $sel(cfg_get.kamailio.bindip) + : + $sel(cfg_get.kamailio.bindport) + \r\n; if($sel(contact.expires) != $null) $uac_req(hdrs)= $uac_req(hdrs) + Expires: + $sel(contact.expires) + \r\n; else $uac_req(hdrs)= $uac_req(hdrs) + Expires: + $hdr(Expires) + \r\n; uac_req_send(); } ___ 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 -- Daniel-Constantin Mierla Kamailio (OpenSER) Advanced Training Jan 24-26, 2011, Irvine, CA, USA http://www.asipto.com ___ 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] Problem with parallel forking
Hello, the problem is that lookup(location) is handling only R-URI, so if ruri is for user XYZ and that is offline, then will return false. Since you create many branches with avp_pushto(), other destinations added as extra branches will be not attempted because of lookup(location) condition. The best is to relay the call after the avp_pushto(), so you will get two branches (or more) coming back via loopback and then you do lookup location for each: if(src_ip!=myself) { if(avp_db_load($ru/username,$avp(s:fork))) { avp_pushto($ru/username,$avp(s:fork)/g); t_relay(); exit; } } if(!lookup(location)) Be sure you skip authentication or other checks when the requests comes back due to such loop, using if(src_ip==myself) conditions. Cheers, Daniel On 1/21/11 11:10 AM, Daniel Grotti wrote: Hi all, I'm using kamailio 3.1 and I have some problems with parallel forking. I need to implement parallel forking to different users registered on kamailio. So, when call arrives with R-URI= sip:003912345678@IP_server, I need to fork te call to (for example) 2 users: 1001 and 1001. To do that, I've created my usr_preferences table like this: ++--+--++---+--+---+-+ |/ id | uuid | username | domain | attribute | type | value |/last_modified | ++--+--++---+--+---+-+ |/ 1 | |/003912345678/ || fork |0 | 1001 | | /|/ 2 | |/003912345678/ || fork |0 | 1002 | | /++--+--++---+--+---+-+ and I've added a code to my kam.cfg like this: if (is_method(INVITE)) { xlog(L_INFO, REQUEST Invite - M=$rm RURI=$ru F=$fu T=$tu IP=$si ID=$ci\n); if(avp_db_load($ru/username,$avp(s:fork))) { avp_pushto($ru/username,$avp(s:fork)/g); } if(!lookup(location)) { xlog(L_INFO, Local user offline - M=$rm RURI=$ru F=$fu T=$tu IP=$si ID=$ci\n); sl_send_reply(404, User Offline); exit; } else { xlog(L_INFO, Local user online - M=$rm RURI=$ru F=$fu T=$tu IP=$si ID=$ci\n); t_relay(); } } If 1001 and 1002 are registered everything works fine (1001 Ringing and 1002 ringing). Ifonly 1001 registered everything works fine (1001 ringing and 1002 is offline.). But when 1002 is registered and 1001 in offline, kamailio try to call 1001, find that it's offline ( and I get 404 User Offline) but no call to 1002 is attempted. What's wrong ? Regards, Daniel ___ 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 -- Daniel-Constantin Mierla Kamailio (OpenSER) Advanced Training Jan 24-26, 2011, Irvine, CA, USA http://www.asipto.com ___ 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] avp_db_query() question
please keep the mailing list cc-ed all the time. Thanks, Daniel On 1/20/11 1:49 PM, ?? wrote: many thanks I've fixed the problem. http://problem.Your Using $(avp(s:name)) instead of $avp(s:name) Your http://problem.your/ solution is OK too. At 2011-01-20 18:10:40??Daniel-Constantin Mierla mico...@gmail.com wrote: Hello, maybe is better to use sqlops module, it more suitable for queries with many records in result. http://kamailio.org/docs/modules/stable/modules_k/sqlops.html Cheers, Daniel On 1/19/11 2:58 PM, Klaus Darilion wrote: looks fine. try to increase debug level - then you should see the query and the results in syslog regards klaus Am 18.01.2011 12:07, schrieb ??: Hello |avp_db_query(query[,dest]) can get a database query and store the results in the avps.| |But what if the results returns many rows,and how can I get all the results? How to set the [dest] parameter ?| |I've tried the method describered in http://www.kamailio.org/docs/avp_db_query.html,but it doesn't work.| |like below| |mysqlselect mem_user from tgroup where grp_name='1234';| |+--+| || mem_user || |+--+| || 1013 || || 2013 || |+--+| |2 rows in set (0.00 sec)| |kamailio.cfg| |if(avp_db_query(select mem_user from tgroup where grp_name='1234',$avp(name)))| |{| |||xlog(L_INFO,query results[1] :$avp(name[1])\n);| |xlog(L_INFO,query results[2] :$avp(name[2])\n);| |}| |syslog| |INFO query results[1] :null| |INFO query results[2] :null| |version: kamailio 3.0.2 MySQL 5.0| || |thank you very much!| ___ 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 -- Daniel-Constantin Mierla Kamailio (OpenSER) Advanced Training Jan 24-26, 2011, Irvine, CA, USA http://www.asipto.com -- Daniel-Constantin Mierla Kamailio (OpenSER) Advanced Training Jan 24-26, 2011, Irvine, CA, USA http://www.asipto.com ___ 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] $ua in on_reply route not set?
Hello, On 1/24/11 9:46 AM, Bernhard Suttner wrote: Hi, found the problem. The device does sometimes use User-Agent and sometimes Server. Is it better to use $hdr() or the Search() function? $hdr() should be faster and more accurate result, working as well with short names for headers -- e.g., $hdr(Call-Id) will match both long and short versions: Call-ID: i: ... We search, be sure you do the expression in the way you won't match the value in another header or body. Cheers, Daniel I use this to check for the User-Agent and then to do a fix_nated_sdp() (in route[] and onreply[]) because I am not really sure, if the fix_nated_sdp() could break something. Or should kamailio break nothing here? Sometimes the User-Agent/Server is missing in Session-Progress 183. Therefore a global fix_nated_sdp() would be nice to have. Best regards, Bernhard - Original Message - From: Daniel-Constantin Mierla [mailto:mico...@gmail.com] To: Bernhard Suttner [mailto:bernhard.sutt...@winet.ch] Cc: sr-users@lists.sip-router.org Sent: Mon, 24 Jan 2011 17:09:12 +0100 Subject: Re: [SR-Users] $ua in on_reply route not set? Hello, On 1/24/11 5:03 PM, Bernhard Suttner wrote: Hi, could it be, that the $ua pseudo variable is not set within in a onreply route? (Version 3.1). no, should be set, there was no change in this regard for quite long time. Can you sent the sip reply plus log with debug=3? What is the best alternative for that? Search()? The alternative is $hdr(User-Agent) which is practically returning the same value as $ua, using generic header search mechanism. Cheers, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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 -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] [kamailio-users] kamailio on amazon
Hello, if everything is working fine with the audio, then just ignore the tcpdump warning, since it may capture the packets before the checksum was actually computed in the system. With some network cards you'd have to disable hardware checksum to get rid of those warnings. again, afaik, it is harmless if everything works. I recommend using version 3.1 for running kamailio in amazon instances, it does it far more better than older versions. I was even running kamailio and asterisk on same ec2 instance, but with some tricks to record routing. For rtp relaying I was using rtpproxy. Cheers, Daniel On 1/24/11 12:42 AM, Chandrakant Solanki wrote: Hi I have installed Kamailio with MediaProxy and asterisk on Amazon Server.. While kamailio/MediaProxy and Asterisk both running on different amazon's instance. Kamailio : 1.5.0-notls MediaProxy : 2.3.8 Asterisk : 1.6.2.6 Firewall port is opened for mediaproxy from 1-2 (UDP), 5060 (UDP) etc on both amazon machine.. while I tried to play an audio... it plays sound file but unable to found audio on device. when I put tcpdump on asterisk machine it gives following error... # tcpdump -i eth0 udp portrange 1-2 -w test1.pcap 01:39:52.850279 IP (tos 0xb8, ttl 64, id 59, offset 0, flags [DF], proto: UDP (17), length: 60) ip-W.X.Y.Z.compute.internal.15246 xyz.com.10010: [bad udp cksum 3cfd!] UDP, length 32 01:39:52.870279 IP (tos 0xb8, ttl 64, id 60, offset 0, flags [DF], proto: UDP (17), length: 60) ip-W.X.Y.Z.compute.internal.15246 xyz.com.10010: [bad udp cksum 97fe!] UDP, length 32 01:39:52.890281 IP (tos 0xb8, ttl 64, id 61, offset 0, flags [DF], proto: UDP (17), length: 60) ip-W.X.Y.Z.compute.internal.15246 xyz.com.10010: [bad udp cksum 75c0!] UDP, length 32 Any Idea..!! -- Regards, Chandrakant Solanki ___ 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 -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] ACC error | failed to insert into database
Hello, On 1/27/11 7:37 AM, alex pappas wrote: Hi all, Hve anyone seen before the following error? *Kamailio acc [acc.c:398]: failed to insert into database* After a Kamailio restart it is ok but it start again afetr x time. what version are you using? Is mysql restarted? Any chance to reproduce it with higher debug level? Cheers, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] Kamailio as a routing engine
Hello, On 1/28/11 3:40 AM, Gang Liu wrote: Hello, I wrote a H.323/SIP IWF program before, it was based on B2BUA framework. Currently I am planning to use Kamailio as internal routing server and let IWF become a class 4 soft switch.That is Inbound H.323/ SIP -- SIP routing request- Kamailio IWF/SBC | Outbound --- H.323/SIP -- --- SIP - Is it ok to store all voip provider's information at database of Kamailio and pass all to IWF at private SIP headers and let IWF as a outbound proxy? you can store in database and use sqlops module to retrieve it for routing purposes. Is Kamailio as a SIP redirect server or it is better to stay at call signaling path until call session ended? It is great to share any information about this. Using redirect or proxy mode is a matter of your needs, proxy is when you want to track the call (e.g., accounting), redirect server is more lightweight (i.e., send 3xx for each call and forget about it). Cheers, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] planning release of v3.1.2
Hello, I think it is time to release v3.1.2, first date that comes in my mind is next Thursday if everyone feels it is enough time to take care of backporting any fix he/she did and it is not yet there. That will provide us a fresh release for the FOSDEM event. If not, then maybe the other week, Tuesday, so the participants at the Kamailio Devel training in Barcelona can practice on it. Soon after we should plan also a release for previous stable, branch 3.0. Anyone having other options? Thanks, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] Kamailio Devel Training, Barcelona - update
Hello, a quick update about the next training in Barcelona, Feb 10-11, 2011, focusing on Kamailio development. We got a bigger room (for second time :-) ), so we increased the capacity to 28 seats. We are already 23 people in the class and several more joining the dinner Thursday evening, so there is going to be a great time. If you plan to come, register asap, there is no time to get a bigger room, so once we are full booked this time, we close the participants list. You can see more details at: http://www.kamailio.org/w/2011/01/kamailio-development-training-barcelona-feb-10-11-2011/ Also, do not forget Fosdem next weekend, it is a bunch of us going there, two talks about Kamailio, come and say hi: http://www.kamailio.org/w/2011/01/social-networking-event-brussels-belgium/ Cheers, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] Joining strings
Hello, On 1/29/11 6:26 AM, Lee Archer wrote: Hi, is it possible to join strings? I'd like toprepend a number to a string prior to processing it to an int? using + with variables/values holding strings results in concatenation: $var(x) = 123; $var(y) = abc + $var(x); Then the $var(y) will be abc123; Cheers, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] t_local_replied() ?
Hello, On 2/1/11 12:08 PM, Bernhard Suttner wrote: Hi, I am using the dispatcher module and want to check within the failure_route if the 408 was internally generated from kamailio or it was received from the dispatcher gateway. There was previously a function called t_local_replied() in the TM-module but I could not find this function in the current documentation. Was it removed? Is there a alternative to check if the 408 was local generated or if it was received from the peer (= from the dispatcher gateway)? see the example of: http://kamailio.org/docs/modules/stable/modules/tm.html#t_branch_replied Cheers, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] Trunk connection asterisk-kamailio
Hello, On 1/31/11 1:25 PM, Mino Haluz wrote: Hi, I have a question about kamailio-asterik interconnection. I'd like to connect 1000 numbers with a trunk, but it would be painful to add 1000 trunks on asterisk. Do you have some idea how could I group those numbers into one trunk connected to kamailio? asterisk and kamailio configuration settings. see mtree (or pdt) or dialplan modules. You can map these numbers to an unique id (trunk). The using permissions you can have restrictions for who can use/call these numbers (matching trunk id with tag attribute). Cheers, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] t_local_replied() ?
Hello, not sure if you ask about the options, or you tried them and don't give you the needed feature, since there are some improper true/false return codes in your email. t_branch_replied() will return false if the 408 is generated locally. Cheers, Daniel On 2/1/11 8:25 PM, Bernhard Suttner wrote: Hi, just to be sure: - If the gateway does send back a 100 Trying and then a 408 is detected within failure_route the method t_branch_replied does return false (means: gateway is up and running) - dont go to next gateway (dispatcher) - If the gateway does not respond and a 408 is detected within failure_route (= 408 was generated from kamailio) t_branch_replied does return true (means: gateway is down) - go to the next gateway (dispatcher) Is that correct or am I wrong? Best regards, Bernhard - Original Message - From: Daniel-Constantin Mierla [mailto:mico...@gmail.com] To: Bernhard Suttner [mailto:bernhard.sutt...@winet.ch] Cc: sr-users@lists.sip-router.org Sent: Tue, 01 Feb 2011 13:30:54 +0100 Subject: Re: [SR-Users] t_local_replied() ? Hello, On 2/1/11 12:08 PM, Bernhard Suttner wrote: Hi, I am using the dispatcher module and want to check within the failure_route if the 408 was internally generated from kamailio or it was received from the dispatcher gateway. There was previously a function called t_local_replied() in the TM-module but I could not find this function in the current documentation. Was it removed? Is there a alternative to check if the 408 was local generated or if it was received from the peer (= from the dispatcher gateway)? see the example of: http://kamailio.org/docs/modules/stable/modules/tm.html#t_branch_replied Cheers, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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 -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] Proposal to extend acc/dialog modules in order to log CDRs
some inter-module api. The benefit is that even sip server crashes suddently, there is an acc start event to indicate a call - such functionality is independent of dlg module or any new call tracking extension in the future, also writing full CDR can be achieved from config file by tracking INVITE and BYE, calling acc_start()/acc_stop() from cfg Therefore if I would do it: - enhance acc module to export via cfg exports and inter-module api three functions: - acc_start() - write the initial call record at start - acc_stop() - update the call record at stop, based on a matching condition specified as parameter - acc_cdr() - write a full CDR Data to be written in db (or other backend) is going to be taken from PVs, independent of who (cfg, dialog, or other module) is calling the function, specified in a similar form like db_extra. First two functions will work for db only. Third can work also without dialog, e.g., I can store the start of a call, a.s.o. in hash table and get it at BYE time to build the full cdr. Your needs seem to fit in 3, so if you can (wish to) work on that only, I will take care of the first two when I can. Cheers, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] Proposal to extend acc/dialog modules in order to log CDRs
Hello, On 2/2/11 12:52 PM, Timo Reimann wrote: Hey Daniel, On 01.02.2011 21:15, Daniel-Constantin Mierla wrote: On 2/1/11 8:18 PM, Timo Reimann wrote: [...] Apart from this very minimum CDR content, however, one can think of a number of CDR fields that cannot be filled easily. For instance, caller identity isn't always contained in the From header (think of CLIR calls) but need to be determined from other headers depending on the type of call, possibly even involving a database lookup. From header URI is not accounted automatically, you can specify any variable that can contain caller id as you need (e.g., it can be an AVP that you previously set for in config) -- see *_extra parameters of acc module. I initially thought about having a cdr_extra parameter similar to log_extra. However, I see a problem with AVPs which live in single transactions to work with dialogs that span multiple transactions. well, some of the avps are transaction persistent, but there are also global avps which are available as long as kamailio runs. None of these should be used, I gave avp just as generic PV example. The idea was to make new PV available with the data stored by dlg module. Say you want to have a CDR field that contains combined or concatenated data from multiple transactions, e.g., all Kamailio flags set in the INVITE, ACK, and BYE transaction. How could that be accomplished with a log_extra-like module parameter? At what times would AVP be parsed? IMHO, you will need to keep such data per dialog which is why I came up with the idea of storing CDR-specific data in the dialog. It is not about where the data is store, it is about how acc accesses that data. I would like to avoid acc module being aware of dialog module internals. In the future might be different call tracking extensions, I don't want to change acc each time. That's why we have PVs, if I want to record something from XYZ module, acc is not going to be changed and understand what xyz stores internally, but XYZ should export some PVs for that. For example, if I want to record something from a HTABLE, there is nothing to do in acc, just specify $sht(x=mykey) to some of acc parameters. That's why I'd like to provide a way to pass additional, CDR-specific data from the configuration file to the dialog structure associated with the call. When the dialog is about to terminate, the extended acc module would make sure that the added CDR data associated to the dialog is included in the CDR. Not sure what you mean here with acc module will make sure ..., but I hope is not going to be cross reference/dependency, so that acc has to walk through dlg structures. If I get you right, by cross reference/dependency you mean that A requires B and vice versa, i.e., cyclic dependency. I do not intend to let that happen. Instead, the acc module would use getter functions attached to the dialog interface (which is what I mean by acc module will make sure). dialog would never touch the acc module or even know about the fact that the acc module is using it. But then acc has to know the dialog internals, what the getter function will return and how to access those structures. PV framework is exactly the same, but available for all components/modules, no need to develop specif ones each time. With your solution, dialog module has to know acc api to call the recording function, and acc has to know dialog module to know its exported structures. This is cross dependency imo. In order to accomplish this, the dialog module would need to be extended such that dialog-specific data may be stored for the duration of a dialog (which is not possible to this day AFAICS). Carsen committed some code in this regard in his IMS branch, as I could see from commit log, check: http://lists.sip-router.org/pipermail/sr-dev/2011-January/010197.html Missed that one. Will take a look at it. Regarding the acc module, a couple of new features need to be implemented: First, the introduction of another module parameter called something like cdr_fields that comprises the set of key names designated for CDR inclusion. Hence, a line like modparam(acc, cdr_fields, caller, callee, foo, bar) The db_extra has the format of 'key=variable', where the 'key' is the db column name and the 'variable' is the name of PV holding the value to be stored. I think the format is better than just providing the names of the dialog keys. See my comment above for why binding PVs to CDR fields does not seem appropriate in this case. I still don't see your point. Third, the CDR is persisted to either log file, database, or both. If this new thing is not going to support what acc module API has for backends (radius is missing), then will not make sense to tie the two. dialog module can do its accounting alone. Of course, I would want to take advantage of acc's existing backend connectors. There's no need to re-invent the wheel, acc will still be responsible for writing
Re: [SR-Users] Weird IPv6 Registration Issue
Hello, On 2/2/11 2:11 PM, Jon Farmer wrote: Hi I am experimenting with a dual homed (IPv4 and IPv6) Openser 1.1.0-tls server. 1.1.0 is way too old :-) . If you try it right now, I recommend using 3.1.x, I have tested it a SIPit and location was working fine. Core and SIP routing are also ok. To my knowledge the permissions module has a too small column size in database address table (on my todo list to fix in this devel cycle). Probably the same is with lcr module. If I register using a IPv6 address then the initial registration works and the details are saved in the location table. However when the UA trys to re-register on expiry the SIP returns a 200 OK but the location data is not updated in the table. Looking at the syslog it is reporting that it didn't save the data as there was an existing entry on index with key 1. This is referring I presume to the primary index on username, domain, contact) on the location table. So what happens is the first location entry expires and gets deleted from the table and thus there is no record for the subsequent register and thus openser thinks the UA has dropped off until the next re-register when because there is no longer a location record the data gets saved correctly. This doesn't happen if I register the same UA on IPv4 on the same openser server. Anyone got any ideas why this is happening? Being that old, I cannot remember if there were other issues. If you want to continue with this one, run it in debug mode, also enable mysql query logs and try to figure out what was wrong there. Then maybe there was a fix for that. Anyhow, iirc, there was an issue with storage of ipv6 address in one of the location fields, probably not done in 1.1.x at all since was done more recently. Cheers, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] topoh, angle brackets and Contact URI params interpretation
Hello, On 2/3/11 1:36 PM, Andrew Pogrebennyk wrote: On 03.02.2011 10:26, Andrew Pogrebennyk wrote: I think the topoh module should force the angle brackets. BTW it seems that parameter needs to be urlencoded, see rule 'other-param' in RFC 3261 section 25.1: From what I understand the valid form is: Contact: sip:192.168.0.107;line=sr-N6IAzB3AWxyfz.stM.quOBFZMJZfWxj7W.y-MljAWBy* or Contact: sip:192.168.0.107;line=sr-N6IAzB3AWxyfz.stM.quOBFZMJZfWxj7W.y-MljAWBy* so it should be enclosed by angle brackets or double quote, otherwise most implementations would treat ;line as header parameter and the parsing would fail since @ is not allowed as header parameter value if it's not enclosed by double quotes. I will check the sources and fix if the contact address is not between . However, I do not undeerstand where you got the @, is none there or am I missing something? Thanks, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] authentication is not working
What version of kamailio are you using? If it is 3.1, then load debugger module and enable cfg trace. Then you will see what lines in the configuration file are executed. For older versions (also for 3.1), you can add xlog() lines in your config to troubleshoot it. Cheers, Daniel On 2/3/11 3:46 PM, Klaus Darilion wrote: Restart Kamailio. Make sure that it is it really restarts: /etc/init.d/kamailio stop ps aux|grep kamailio # if there are some processes left, kill them killall kamailio ps aux|grep kamailio # if there are still some processes left, kill them harder! killall -9 kamailio /etc/init.d/kamailio start make sure Kamailio is really using your configuration file klaus Am 03.02.2011 11:12, schrieb Danny Dias: Hello my friends, I'm trying to configure authentication on my Kamailio and is not working at all :( I've added the following to the script to make it work: (but it doesn't) ... loadmodule auth.so loadmodule auth_db.so ... modparam(usrloc, db_url, mysql://kamailio:kamailiorw@localhost/kamailio) modparam(auth_db, calculate_ha1, yes) modparam(auth_db, password_column, password) modparam(auth_db, db_url, mysql://kamailio:kamailiorw@localhost/kamailio) modparam(auth_db, load_credentials, ) ... if (!(method==REGISTER) from_uri==myself) /*no multidomain version*/ { if (!proxy_authorize(, subscriber)) { proxy_challenge(, 0); exit; } if (!db_check_from()) { sl_send_reply(403,Forbidden auth ID); exit; } consume_credentials(); } ... if (is_method(REGISTER)) { # authenticate the REGISTER requests (uncomment to enable auth) if (!www_authorize(, subscriber)) { www_challenge(, 0); exit; } ## if (!db_check_to()) { sl_send_reply(403,Forbidden auth ID); exit; } if (!save(location)) sl_reply_error(); exit; } But is not working at all...take a look: # U 2011/02/03 09:31:04.402891 172.30.140.22:48752 - 172.30.140.8:5060 REGISTER sip:172.30.140.8 SIP/2.0 Via: SIP/2.0/UDP 172.30.140.22:48752 ;branch=z9hG4bK-d87543-9a54af22967ae417-1--d87543-;rport Max-Forwards: 70 Contact:sip:1000@172.30.140.22:48752;rinstance=fcade2df86ce0ab8 To: 1000sip:1000@172.30.140.8sip%3A1000@172.30.140.8 From: 1000sip:1000@172.30.140.8sip%3A1000@172.30.140.8;tag=cd3e2323 Call-ID: MmU0YjM1NThiNTg0ZjhiNGM4ODA4ZmU1YWFiYjBmNTc. CSeq: 1 REGISTER Expires: 3600 Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, NOTIFY, MESSAGE, SUBSCRIBE, INFO User-Agent: X-Lite release 1011s stamp 41150 Content-Length: 0 # U 2011/02/03 09:31:04.404039 172.30.140.8:5060 - 172.30.140.22:48752 SIP/2.0 200 OK Via: SIP/2.0/UDP 172.30.140.22:48752 ;branch=z9hG4bK-d87543-9a54af22967ae417-1--d87543-;rport=48752 To: 1000sip:1000@172.30.140.8sip%3A1000@172.30.140.8 ;tag=c97b4d1cb1f3d0da549e06a8d482ef63.34dc From: 1000sip:1000@172.30.140.8sip%3A1000@172.30.140.8;tag=cd3e2323 Call-ID: MmU0YjM1NThiNTg0ZjhiNGM4ODA4ZmU1YWFiYjBmNTc. CSeq: 1 REGISTER Contact:sip:1000@172.30.140.22:48752 ;rinstance=fcade2df86ce0ab8;expires=3600 Content-Length: 0 Am i missing something in my configuration? Thanks in advance!!! ___ 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 -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] dispatcher - ds_mark_dst(i); is inactive only few seconds
Hello Thomas, On 2/4/11 6:21 PM, Thomas Baumann wrote: Hello Daniel, I have checked the behavior again, without any load on the system I can see the 408 responses: OPTIONS-Request was finished with code 408 I guess this is the standard behavior if no answer is received from the gateway. yes, it is a local generated 408 (timeout). This one is not seen on the network. If you want to enable back for some 4xx code but not for 408, then you have to use a list of code=4xx instead of class=4 in the dispatcher ds_ping_reply_codes parameter. Cheers, Daniel regards, Thomas -Ursprüngliche Nachricht- Von: Daniel-Constantin Mierla Gesendet: 03.02.2011 21:38:49 An: Thomas Baumann Betreff: Re: [SR-Users] dispatcher - ds_mark_dst(i);is inactive only few seconds Hello, On 2/3/11 7:07 PM, Thomas Baumann wrote: Hi Daniel, thanks for the hints, with debug_level they are some hints what happened. Normal Operation: 5(20410) DEBUG: dispatcher [dispatch.c:2305]: probing set #1, URI sip:10.12.19.31:5060 5(20410) DEBUG: dispatcher [dispatch.c:2305]: probing set #1, URI sip:10.12.19.21:5060 4(20409) DEBUG: dispatcher [dispatch.c:2250]: OPTIONS-Request was finished with code 200 (to sip:10.12.19.21:5060, group 1) 3(20407) DEBUG: dispatcher [dispatch.c:2250]: OPTIONS-Request was finished with code 200 (to sip:10.12.19.31:5060, group 1) Service is stopped at 10.12.19.21, the next INVITE with timeout will trigger ds_mark_dst(i); This event will enable the Gateway again: 5(20410) DEBUG: dispatcher [dispatch.c:2250]: OPTIONS-Request was finished with code 408 (to sip:10.12.19.21:5060, group 1) But the funny part is that this 408 does not belong to a OPTION-Request. It was an reply to an INVITE. it is very unlikely that a reply for an INVITE will match a keepalive OPTIONS request. Can you grap SIP trace for such case, along with debug messages? I disabled the parameter modparam(dispatcher, ds_ping_reply_codes, class=2;class=4) in the config, now the gateway remains inactive until a 200 ok is received for an option. I don't understand why this 408 matched. Why I need to trigger always ds_mark_dst(i); , OPTIONS are send out anyway. Disabling the gateway could be done in the background, or maybe I missed something in the documentation. You have to trigger ds_marck_dst(i) if you want that the gw becomes inactive immediately, otherwise will be set inactive at next keepalive round. Cheers, Daniel regards, Thomas ___ Empfehlen Sie WEB.DE DSL Ihren Freunden und Bekannten und wir belohnen Sie mit bis zu 50,- Euro! https://freundschaftswerbung.web.de -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] SIP Router 3.03 topoh
/msg_parser.c:353]: ERROR: bad header field [CSeq: 1 REGISTER ACK] Feb 4 16:19:09 proxy1 kernel: [1853342.057429] kamailio[20506]: segfault at 18 ip b7064220 sp bf9c3370 error 4 in topoh.so[b7061000+d000] Feb 4 16:19:09 proxy1 sip[20505]: ERROR: core [parser/parse_cseq.c:97]: ERROR: CSeq EoL expected Feb 4 16:19:09 proxy1 sip[20505]: ERROR: core [parser/parse_cseq.c:100]: ERROR: parse_cseq: bad cseq Feb 4 16:19:09 proxy1 sip[20505]: ERROR: core [parser/msg_parser.c:158]: ERROR: get_hdr_field: bad cseq Feb 4 16:19:09 proxy1 sip[20505]: INFO: core [parser/msg_parser.c:353]: ERROR: bad header field [CSeq: 1 REGISTER ACK] Feb 4 16:19:09 proxy1 kernel: [1853342.139751] kamailio[20505]: segfault at 18 ip b7064220 sp bf9c3370 error 4 in topoh.so[b7061000+d000] Feb 4 16:19:09 proxy1 sip[20499]: ERROR: core [parser/parse_cseq.c:97]: ERROR: CSeq EoL expected Feb 4 16:19:09 proxy1 sip[20499]: ERROR: core [parser/parse_cseq.c:100]: ERROR: parse_cseq: bad cseq Feb 4 16:19:09 proxy1 sip[20499]: ERROR: core [parser/msg_parser.c:158]: ERROR: get_hdr_field: bad cseq Feb 4 16:19:09 proxy1 sip[20499]: INFO: core [parser/msg_parser.c:353]: ERROR: bad header field [CSeq: 1 REGISTER ACK] Feb 4 16:19:09 proxy1 kernel: [1853342.149429] kamailio[20499]: segfault at 18 ip b7064220 sp bf9c3370 error 4 in topoh.so[b7061000+d000] Feb 4 16:19:09 proxy1 sip[20502]: ERROR: core [parser/parse_cseq.c:97]: ERROR: CSeq EoL expected Feb 4 16:19:09 proxy1 sip[20502]: ERROR: core [parser/parse_cseq.c:100]: ERROR: parse_cseq: bad cseq Feb 4 16:19:09 proxy1 sip[20502]: ERROR: core [parser/msg_parser.c:158]: ERROR: get_hdr_field: bad cseq Feb 4 16:19:09 proxy1 sip[20502]: INFO: core [parser/msg_parser.c:353]: ERROR: bad header field [CSeq: 1 REGISTER ACK] Feb 4 16:19:09 proxy1 kernel: [1853342.156097] kamailio[20502]: segfault at 18 ip b7064220 sp bf9c3370 error 4 in topoh.so[b7061000+d000] Feb 4 16:19:09 proxy1 sip[20501]: ERROR: core [parser/parse_cseq.c:97]: ERROR: CSeq EoL expected Feb 4 16:19:09 proxy1 sip[20501]: ERROR: core [parser/parse_cseq.c:100]: ERROR: parse_cseq: bad cseq Feb 4 16:19:09 proxy1 sip[20501]: ERROR: core [parser/msg_parser.c:158]: ERROR: get_hdr_field: bad cseq Feb 4 16:19:09 proxy1 sip[20501]: INFO: core [parser/msg_parser.c:353]: ERROR: bad header field [CSeq: 1 REGISTER ACK] Feb 4 16:19:09 proxy1 kernel: [1853342.160097] kamailio[20501]: segfault at 18 ip b7064220 sp bf9c3370 error 4 in topoh.so[b7061000+d000] Feb 4 16:19:09 proxy1 sip[20500]: ERROR: core [parser/parse_cseq.c:97]: ERROR: CSeq EoL expected Feb 4 16:19:09 proxy1 sip[20500]: ERROR: core [parser/parse_cseq.c:100]: ERROR: parse_cseq: bad cseq Feb 4 16:19:09 proxy1 sip[20500]: ERROR: core [parser/msg_parser.c:158]: ERROR: get_hdr_field: bad cseq Feb 4 16:19:09 proxy1 sip[20500]: INFO: core [parser/msg_parser.c:353]: ERROR: bad header field [CSeq: 1 REGISTER ACK] Feb 4 16:19:09 proxy1 kernel: [1853342.163561] kamailio[20500]: segfault at 18 ip b7064220 sp bf9c3370 error 4 in topoh.so[b7061000+d000] Feb 4 16:19:09 proxy1 sip[20504]: ERROR: core [parser/parse_cseq.c:97]: ERROR: CSeq EoL expected Feb 4 16:19:09 proxy1 sip[20504]: ERROR: core [parser/parse_cseq.c:100]: ERROR: parse_cseq: bad cseq Feb 4 16:19:09 proxy1 sip[20504]: ERROR: core [parser/msg_parser.c:158]: ERROR: get_hdr_field: bad cseq Feb 4 16:19:09 proxy1 sip[20504]: INFO: core [parser/msg_parser.c:353]: ERROR: bad header field [CSeq: 1 REGISTER ACK] Feb 4 16:19:09 proxy1 kernel: [1853342.168357] kamailio[20504]: segfault at 18 ip b7064220 sp bf9c3370 error 4 in topoh.so[b7061000+d000] Feb 4 16:19:13 proxy1 sip[20497]: ALERT: core [main.c:741]: child process 20507 exited by a signal 11 Regards, Brian Regards Brian ___ 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 -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] Problem with load_gws()
On Sat, Feb 5, 2011 at 7:50 AM, Juha Heinanen j...@tutpro.com wrote: Amit Nepal writes: modparam(lcr,db_url,DBURL) modparam(lcr, gw_uri_avp, $avp(i:709)) modparam(lcr, ruri_user_avp, $avp(i:500)) modparam(lcr, flags_avp, $avp(i:712)) route[LCR] { if(!load_gws()){ xlog(yes); }; This gives me error : loading modules under /usr/local/lib/kamailio/modules_k/:/usr/local/lib/kamailio 0(1265) : core [cfg.y:3412]: parse error in config file routes/route-lcr.cfg unknown command, missing loadmodule? for load_gws() ERROR: bad config file (1 errors) Any guidance please ? check that you have loaded lcr module with loadmodule script command. most probably the error is because the function is missing lcr_id parameter: http://kamailio.org/docs/modules/stable/modules/lcr.html#id2945977 Cheers, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] planning release of v3.1.2
Hello, I plan to release 3.1.2 later today, if you have backport to this branch, please do it before 14:00 UTC, Thanks, Daniel On 1/28/11 8:15 PM, Daniel-Constantin Mierla wrote: Hello, I think it is time to release v3.1.2, first date that comes in my mind is next Thursday if everyone feels it is enough time to take care of backporting any fix he/she did and it is not yet there. That will provide us a fresh release for the FOSDEM event. If not, then maybe the other week, Tuesday, so the participants at the Kamailio Devel training in Barcelona can practice on it. Soon after we should plan also a release for previous stable, branch 3.0. Anyone having other options? Thanks, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] Kamailio v3.1.2 Released
Hello, Kamailio SIP Server v3.1.2 stable release is out. This is a maintenance release of latest stable branch, 3.1, that includes fixes since release of v3.1.1. There is no change to database or configuration file required to upgrade to 3.1.2 from 3.1.0 or 3.1.1 versions, therefore it is strongly recommended to upgrade to v3.1.2. For more details about version 3.1.2, visit: http://www.kamailio.org/w/2011/02/kamailio-v3-1-2-released/ Cheers, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] Fosdem2011 presentation: SIP Web20 Lua
Hello, the presentation I did during Fosdem in Brussels last weekend is available at: http://www.kamailio.org/events/2011-fosdem/dcm-sip-web-lua.pdf The focus was to show how to interact with Kamailio via HTTP and how Kamailio can interact with Web services via HTTP, using Lua to make it easier. There are slides for a demo config of sending asynchronous notifications to Twitter on missed calls (using modules app_lua, mqueue, sqlops and rtimer). Cheers, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] module postgres SER
Hello, On 2/9/11 2:19 PM, Bruno Bresciani wrote: Hi, I've seen the problem in a postgres module (SER-0.8.1.4), if the connection fails and module tries to reparse url it fails as CON_SQLURL(_h) is corrupted by the function aug_free() after some reconnect attempts . When the postgres database back to work, some modules doesn't get reconnect because the db_url is corrupted. Why this is happening? There are some solution for this problem? ser 0.8.1.4 is s old and I cannot fully remember, but I think postgres module had no reconnect functionality at all by that time. However, version 3.1.x of SER (as well as Kamailio flavour) has db reconnect functionality for postgres. You can try it and report if something is not working, it will be fixed in 3.x, but I think nobody is still developing on 0.8.x to backport anything there. Cheers, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] fosdem 2011 presentation about p_usrloc
On 2/9/11 10:42 AM, Henning Westerholt wrote: On Tuesday 08 February 2011, Klaus Darilion wrote: this year the FOSDEM developer conference was a again a really nice event, the first time with an own room dedicated completely to open source telephony solutions! If you're interested in our presentation about the new p_usrloc module and how to scale location services with Kamailio, you can find it at the usual place on our webserver: Are videos available of the presentation? Hi Klaus, afaik not, sorry. There were only limited coverage of the development rooms and i also did not noticed a camera during the talk. Only the Lighting Talks and main tracks were officially recorded. None of the dev rooms were recorded unless someone in particular did it. In the VoIP dev room was no recording. Anyhow, live is better always :-). Cheers, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] Multiple call accounting from an IP
Hello, On 2/7/11 8:13 PM, Amit Nepal wrote: Hi everyone, I am sure someone have been working with this scenario, how about accounting multiple calls from same account or ip address while using ip auth ? I don't understand what you want exactly to achieve. Kamailio doesn't set any limitation on number of active calls from same user/ip -- but you can implement such limitations with dialog module or custom config logic using htable or a database table with sqlops. If you look for something else, provide more details. Cheers, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] problem with bye using rtpproxy
Hello, On 2/7/11 8:12 PM, Amit Nepal wrote: I have been trying to figure this out While using kamailio and rtpproxy, the caller is not receiving the bye when callee hangs up but audio is two way and everything seems to be working fine, any one had this issue ? are you doing record-routing in your config? The best for providing further hints is to get the SIP trace for such call, from the starting INVITE to the end -- ngrep is recommended to use for sending on this list since it prints out text, following command can be used on your sip server: ngrep -d any -qt -W byline port 5060 Cheers, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] module postgres SER
please keep the mailing list cc-ed, sending private messages is not in the spirit of public mailing lists. Others may want to follow up the discussion now or later. Thanks, Daniel On 2/9/11 5:01 PM, Bruno Bresciani wrote: Daniel, thanks for your reply, really ser-0.8.1.4 is too old but i need to solve this problem on that version. My great doubt is Why the aug_free function corrupt the url of database after some attemps to reconnect. Well, I'll try to understand this question... Best Regards 2011/2/9 Daniel-Constantin Mierla mico...@gmail.com mailto:mico...@gmail.com Hello, On 2/9/11 2:19 PM, Bruno Bresciani wrote: Hi, I've seen the problem in a postgres module (SER-0.8.1.4), if the connection fails and module tries to reparse url it fails as CON_SQLURL(_h) is corrupted by the function aug_free() after some reconnect attempts . When the postgres database back to work, some modules doesn't get reconnect because the db_url is corrupted. Why this is happening? There are some solution for this problem? ser 0.8.1.4 is s old and I cannot fully remember, but I think postgres module had no reconnect functionality at all by that time. However, version 3.1.x of SER (as well as Kamailio flavour) has db reconnect functionality for postgres. You can try it and report if something is not working, it will be fixed in 3.x, but I think nobody is still developing on 0.8.x to backport anything there. Cheers, Daniel -- Daniel-Constantin Mierla http://www.asipto.com -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] After upgrade from openser 1.3.4 to kamailio 1.5.5 the same crash set
Hello, from the subject I don't understand exactly: did you get this crash also with 1.3.4? Is it reproducible? Looks like there is a buffer overflow. Can you recompile/reinstall with memory debug on (in 1.5.x, see Makefile.vars)? The watch the logs and see if you get any error related to buffer overwritten ops. Cheers, Daniel On 2/10/11 7:37 AM, Andrew O. Zhukov wrote: [root@ tmp]# /usr/local/sbin/kamailio -V version: kamailio 1.5.5-notls (x86_64/linux) flags: STATISTICS, EXTRA_DEBUG, USE_IPV6, USE_TCP, DISABLE_NAGLE, USE_MCAST, SHM_MMAP, PKG_MALLOC, F_MALLOC, FAST_LOCK-ADAPTIVE_WAIT ADAPTIVE_WAIT_LOOPS=1024, MAX_RECV_BUFFER_SIZE 262144, MAX_LISTEN 16, MAX_URI_SIZE 1024, BUF_SIZE 65535, PKG_SIZE 4194304 poll method support: poll, epoll_lt, epoll_et, sigio_rt, select. svnrevision: unknown @(#) $Id: main.c 5608 2009-02-13 16:48:17Z henningw $ main.c compiled on 12:38:36 Feb 2 2011 with gcc 4.1.2 - Core was generated by `/usr/local/sbin/kamailio -P /var/run/openser/openser.pid -m 32 -u openser -g op'. Program terminated with signal 11, Segmentation fault. #0 0x0046b0e3 in fm_malloc (qm=0x72dc00, size=32) at mem/f_malloc.c:354 354 if ((*f)-size=size) goto found; (gdb) backtrace #0 0x0046b0e3 in fm_malloc (qm=0x72dc00, size=32) at mem/f_malloc.c:354 #1 0x2b30f2803087 in build_rr (_l=0x76f110, _l2=0x76fe80, user=0x7fffe9c5a500, tag=0x777a58, params=0x0, _inbound=0) at record.c:176 #2 0x2b30f2802b7a in record_route (_m=0x76e0e0, params=0x0) at record.c:322 #3 0x2b30f28047db in w_record_route (msg=0x76e0e0, key=0x0, bar=0x0) at rr_mod.c:212 #4 0x0040ed9b in do_action (a=0x73f5a0, msg=0x76e0e0) at action.c:874 #5 0x0040c03a in run_action_list (a=0x73f5a0, msg=0x76e0e0) at action.c:145 #6 0x0040e6a7 in do_action (a=0x73f810, msg=0x76e0e0) at action.c:746 #7 0x0040c03a in run_action_list (a=0x73e418, msg=0x76e0e0) at action.c:145 #8 0x0040c2a9 in run_actions (a=0x73e418, msg=0x76e0e0) at action.c:120 #9 0x0040c357 in run_top_route (a=0x73e418, msg=0x76e0e0) at action.c:195 #10 0x0043bda4 in receive_msg ( buf=0x70c980 NOTIFY sip:XX.com SIP/2.0\r\nVia: SIP/2.0/UDP XX.XXX.101.68:5060;branch=z9hG4bK-6ee3865\r\nFrom: VTHome sip:101...@xx.com;tag=129d73a13db8ec7fo0\r\nTo: sip:X.com\r\nCall-ID: e3fd1da9-142a0a17..., len=373, rcv_info=0x7fffe9c5ae90) at receive.c:175 #11 0x00467eeb in udp_rcv_loop () at udp_server.c:449 #12 0x0042097b in main_loop () at main.c:774 #13 0x004228b0 in main (argc=11, argv=0x7fffe9c5b118) at main.c:1321 (gdb) print size $1 = 32 (gdb) quit Core was generated by `/usr/local/sbin/kamailio -P /var/run/openser/openser.pid -m 32 -u openser -g op'. Program terminated with signal 11, Segmentation fault. #0 0x0046bf7b in fm_status (qm=0x72dc00) at mem/f_malloc.c:609 609 size+=f-size,f=f-u.nxt_free,i++,j++){ (gdb) backtrace #0 0x0046bf7b in fm_status (qm=0x72dc00) at mem/f_malloc.c:609 #1 0x0041feb3 in sig_usr (signo=15) at main.c:563 #2 signal handler called #3 0x0039d8cd4a51 in __recvfrom_nocancel () from /lib64/libc.so.6 #4 0x00467bf4 in udp_rcv_loop () at udp_server.c:408 #5 0x0042097b in main_loop () at main.c:774 #6 0x004228b0 in main (argc=11, argv=0x7fffe9c5b118) at main.c:1321 (gdb) print i $1 = 402 (gdb) print j $2 = 1 (gdb) print size $3 = 7234295468789601279 (gdb) print f $4 = (struct fm_frag *) 0x3738656435393838 (gdb) print f-size Cannot access memory at address 0x3738656435393838 --- Andrew O. Zhukov ___ 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 -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] After upgrade from openser 1.3.4 to kamailio 1.5.5 the same crash set
On 2/10/11 8:12 AM, Andrew O. Zhukov wrote: Couple month ago I sent whole set of crash-es from 1.3.4 to this maillist. Nobody respond me. Probably they were forgotten in the history, if most of devs were offline at the moment you sent. Do you have a link to the thread, it may help reading what you sent at that time, as well. Cheers, Daniel On 02/10/2011 08:53 AM, Daniel-Constantin Mierla wrote: Hello, from the subject I don't understand exactly: did you get this crash also with 1.3.4? Is it reproducible? This crash-es from 1.5.5. I rise it up on this weekend. I do not shutdown server with 1.3.4 yet. I still keep all crashes there. Looks like there is a buffer overflow. Can you recompile/reinstall with memory debug on (in 1.5.x, see Makefile.vars)? The watch the logs and see if you get any error related to buffer overwritten ops. Ok. I'll do it. Cheers, Daniel On 2/10/11 7:37 AM, Andrew O. Zhukov wrote: [root@ tmp]# /usr/local/sbin/kamailio -V version: kamailio 1.5.5-notls (x86_64/linux) flags: STATISTICS, EXTRA_DEBUG, USE_IPV6, USE_TCP, DISABLE_NAGLE, USE_MCAST, SHM_MMAP, PKG_MALLOC, F_MALLOC, FAST_LOCK-ADAPTIVE_WAIT ADAPTIVE_WAIT_LOOPS=1024, MAX_RECV_BUFFER_SIZE 262144, MAX_LISTEN 16, MAX_URI_SIZE 1024, BUF_SIZE 65535, PKG_SIZE 4194304 poll method support: poll, epoll_lt, epoll_et, sigio_rt, select. svnrevision: unknown @(#) $Id: main.c 5608 2009-02-13 16:48:17Z henningw $ main.c compiled on 12:38:36 Feb 2 2011 with gcc 4.1.2 - Core was generated by `/usr/local/sbin/kamailio -P /var/run/openser/openser.pid -m 32 -u openser -g op'. Program terminated with signal 11, Segmentation fault. #0 0x0046b0e3 in fm_malloc (qm=0x72dc00, size=32) at mem/f_malloc.c:354 354 if ((*f)-size=size) goto found; (gdb) backtrace #0 0x0046b0e3 in fm_malloc (qm=0x72dc00, size=32) at mem/f_malloc.c:354 #1 0x2b30f2803087 in build_rr (_l=0x76f110, _l2=0x76fe80, user=0x7fffe9c5a500, tag=0x777a58, params=0x0, _inbound=0) at record.c:176 #2 0x2b30f2802b7a in record_route (_m=0x76e0e0, params=0x0) at record.c:322 #3 0x2b30f28047db in w_record_route (msg=0x76e0e0, key=0x0, bar=0x0) at rr_mod.c:212 #4 0x0040ed9b in do_action (a=0x73f5a0, msg=0x76e0e0) at action.c:874 #5 0x0040c03a in run_action_list (a=0x73f5a0, msg=0x76e0e0) at action.c:145 #6 0x0040e6a7 in do_action (a=0x73f810, msg=0x76e0e0) at action.c:746 #7 0x0040c03a in run_action_list (a=0x73e418, msg=0x76e0e0) at action.c:145 #8 0x0040c2a9 in run_actions (a=0x73e418, msg=0x76e0e0) at action.c:120 #9 0x0040c357 in run_top_route (a=0x73e418, msg=0x76e0e0) at action.c:195 #10 0x0043bda4 in receive_msg ( buf=0x70c980 NOTIFY sip:XX.com SIP/2.0\r\nVia: SIP/2.0/UDP XX.XXX.101.68:5060;branch=z9hG4bK-6ee3865\r\nFrom: VTHome sip:101...@xx.com;tag=129d73a13db8ec7fo0\r\nTo: sip:X.com\r\nCall-ID: e3fd1da9-142a0a17..., len=373, rcv_info=0x7fffe9c5ae90) at receive.c:175 #11 0x00467eeb in udp_rcv_loop () at udp_server.c:449 #12 0x0042097b in main_loop () at main.c:774 #13 0x004228b0 in main (argc=11, argv=0x7fffe9c5b118) at main.c:1321 (gdb) print size $1 = 32 (gdb) quit Core was generated by `/usr/local/sbin/kamailio -P /var/run/openser/openser.pid -m 32 -u openser -g op'. Program terminated with signal 11, Segmentation fault. #0 0x0046bf7b in fm_status (qm=0x72dc00) at mem/f_malloc.c:609 609 size+=f-size,f=f-u.nxt_free,i++,j++){ (gdb) backtrace #0 0x0046bf7b in fm_status (qm=0x72dc00) at mem/f_malloc.c:609 #1 0x0041feb3 in sig_usr (signo=15) at main.c:563 #2 signal handler called #3 0x0039d8cd4a51 in __recvfrom_nocancel () from /lib64/libc.so.6 #4 0x00467bf4 in udp_rcv_loop () at udp_server.c:408 #5 0x0042097b in main_loop () at main.c:774 #6 0x004228b0 in main (argc=11, argv=0x7fffe9c5b118) at main.c:1321 (gdb) print i $1 = 402 (gdb) print j $2 = 1 (gdb) print size $3 = 7234295468789601279 (gdb) print f $4 = (struct fm_frag *) 0x3738656435393838 (gdb) print f-size Cannot access memory at address 0x3738656435393838 --- Andrew O. Zhukov ___ 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 -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] After upgrade from openser 1.3.4 to kamailio 1.5.5 the same crash set
On 2/11/11 6:23 PM, Andrew O. Zhukov wrote: Here is it with MEMDBG=1 Did you get in syslog any error (bug) message mentioning overwriting tail/head for memory operations? If yes, send the syslog messages here. I will try to look over it soon, being offline for some traveling... Cheers, Daniel -- Core was generated by `/usr/local/sbin/kamailio -P /var/run/openser/openser.pid -m 32 -u openser -g op'. Program terminated with signal 6, Aborted. #0 0x0039d8c30265 in raise () from /lib64/libc.so.6 (gdb) backtrace #0 0x0039d8c30265 in raise () from /lib64/libc.so.6 #1 0x0039d8c31d10 in abort () from /lib64/libc.so.6 #2 0x0046c397 in qm_debug_frag (qm=0x733c00, f=0x7ca950) at mem/q_malloc.c:137 #3 0x0046d99a in qm_free (qm=0x733c00, p=0x7ca980, file=0x4e4d30 parser/digest/digest.c, func=0x4e4da0 free_credentials, line=95) at mem/q_malloc.c:439 #4 0x00495fac in free_credentials (_b=0x2ba07046a7b8) at parser/digest/digest.c:95 #5 0x00471a36 in clean_hdr_field (hf=0x2ba07046a788) at parser/hf.c:116 #6 0x2ba06cec58de in clean_msg_clone (msg=0x2ba0704697b8, min=0x2ba0704697b8, max=0x2ba07046add0) at sip_msg.h:54 #7 0x2ba06cec57b7 in run_trans_callbacks (type=2, trans=0x2ba07045b3f0, req=0x2ba0704697b8, rpl=0x7c0eb8, code=200) at t_hooks.c:245 #8 0x2ba06cecc39d in t_reply_matching (p_msg=0x7c0eb8, p_branch=0x7fff8a7202c8) at t_lookup.c:888 #9 0x2ba06cecc997 in t_check (p_msg=0x7c0eb8, param_branch=0x7fff8a7202c8) at t_lookup.c:964 #10 0x2ba06cedb79b in reply_received (p_msg=0x7c0eb8) at t_reply.c:1395 #11 0x0041c6db in forward_reply (msg=0x7c0eb8) at forward.c:576 #12 0x0043ccf0 in receive_msg ( buf=0x712980 SIP/2.0 200 OK\r\nVia: SIP/2.0/UDP XXX.XX.XXX.13;branch=z9hG4bKb01c.8ffe0f62.0;received=XXX.XX.XXX.13\r\nVia: SIP/2.0/UDP XXX.XX.XXX.236:5060;received=XXX.XX.XXX.236;branch=z9hG4bK20b12a8d;rport=5060\r\nRec..., len=576, rcv_info=0x7fff8a720420) at receive.c:212 #13 0x004692e3 in udp_rcv_loop () at udp_server.c:449 #14 0x00420ecb in main_loop () at main.c:774 #15 0x00422e0f in main (argc=11, argv=0x7fff8a7206a8) at main.c:1321 -- Core was generated by `/usr/local/sbin/kamailio -P /var/run/openser/openser.pid -m 32 -u openser -g op'. Program terminated with signal 6, Aborted. #0 0x0039d8c30265 in raise () from /lib64/libc.so.6 (gdb) backtrace #0 0x0039d8c30265 in raise () from /lib64/libc.so.6 #1 0x0039d8c31d10 in abort () from /lib64/libc.so.6 #2 0x0046c397 in qm_debug_frag (qm=0x733c00, f=0x83a818) at mem/q_malloc.c:137 #3 0x0046d99a in qm_free (qm=0x733c00, p=0x83a848, file=0x4e4d30 parser/digest/digest.c, func=0x4e4da0 free_credentials, line=95) at mem/q_malloc.c:439 #4 0x00495fac in free_credentials (_b=0x2b95e9de8758) at parser/digest/digest.c:95 #5 0x00471a36 in clean_hdr_field (hf=0x2b95e9de8728) at parser/hf.c:116 #6 0x2b95e687e8de in clean_msg_clone (msg=0x2b95e9de7758, min=0x2b95e9de7758, max=0x2b95e9de8d70) at sip_msg.h:54 #7 0x2b95e687e7b7 in run_trans_callbacks (type=2, trans=0x2b95e9fe5150, req=0x2b95e9de7758, rpl=0x7c0eb8, code=200) at t_hooks.c:245 #8 0x2b95e688539d in t_reply_matching (p_msg=0x7c0eb8, p_branch=0x7fff77e144b8) at t_lookup.c:888 #9 0x2b95e6885997 in t_check (p_msg=0x7c0eb8, param_branch=0x7fff77e144b8) at t_lookup.c:964 #10 0x2b95e689479b in reply_received (p_msg=0x7c0eb8) at t_reply.c:1395 #11 0x0041c6db in forward_reply (msg=0x7c0eb8) at forward.c:576 #12 0x0043ccf0 in receive_msg ( buf=0x712980 SIP/2.0 200 OK\r\nVia: SIP/2.0/UDP XXX.XX.XXX.13;branch=z9hG4bK2cb3.224aa3e4.0;received=XXX.XX.XXX.13\r\nVia: SIP/2.0/UDP XXX.XX.XXX.236:5060;received=XXX.XX.XXX.236;branch=z9hG4bK3ca41325;rport=5060\r\nRec..., len=576, rcv_info=0x7fff77e14610) at receive.c:212 #13 0x004692e3 in udp_rcv_loop () at udp_server.c:449 #14 0x00420ecb in main_loop () at main.c:774 #15 0x00422e0f in main (argc=11, argv=0x7fff77e14898) at main.c:1321 Loaded symbols for /lib64/ld-linux-x86-64.so.2 Core was generated by `/usr/local/sbin/kamailio -P /var/run/openser/openser.pid -m 32 -u openser -g op'. Program terminated with signal 11, Segmentation fault. #0 0x0046bf7b in add_avp_galias_str (alias_definition=0x46de56 ) at usr_avp.c:680 680LM_ERR(parse error in %s around pos %ld\n, (gdb) backtrace #0 0x0046bf7b in add_avp_galias_str (alias_definition=0x46de56 ) at usr_avp.c:680 #1 0x in ?? () On 02/10/2011 09:14 AM, Daniel-Constantin Mierla wrote: On 2/10/11 8:12 AM, Andrew O. Zhukov wrote: Couple month ago I sent whole set
Re: [SR-Users] Error running kamailio 3.1.0
Hello, looks like you installed 3.1 over 3.0. sl module is now in modules/ folder. In 3.0 was in modules_k folder, so it finds the old version first. Delete the content of /usr/local/lib/kamailio/ and then install again. Cheers, Daniel On 2/11/11 6:09 PM, Lucas Alvarez wrote: Hi, I have compiled kamailio 3.1.0 without any error and I having this error when running kamailio: ERROR: core [sr_module.c:523]: ERROR: load_module: could not open module /usr/local/lib/kamailio/modules_k/sl.so: /usr/local/lib/kamailio/modules_k/sl.so: undefined symbol: fm_malloc Any will be appreciated. Regards, Lucas ___ 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 -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] Issue with avp
On 2/14/11 8:40 PM, Amit Nepal wrote: could someone help me on this please ? Can you watch the mysql query logs and see if the rpid column is selected along with the password for authentication from subscriber table? Also, if you can run kamailio with debug=4 and send then output here for such case would help troubleshooting. This part was not changed for quite some time, so might be something missing in the config or so. Cheers, Daniel I have been trying to load rpid while loading credentials. modparam(auth_db, load_credentials, $avp(i:123)=rpid) Now, I am trying to do a check in my routing logic. xlog(L_NOTICE,The avp is :$avp(i:123)); (I dont get the value here either, i can't see the value when i do avp_print() if($avp(i:123)5) { sl_send_reply(408,Message Here); } I dont get the value of avp at that place. And this is after successful www/proxy_authenticate() Thank you Amit On 2/10/2011 11:46 AM, Amit Nepal wrote: Yes it is after successful www/proxy_authenticate() Thank You Amit Nepal Systems Administrator Phoenix Internet Phone: 602-385-0731 602-234-0917#112 http://www.phoenixinternet.net On 2/9/2011 11:54 PM, Daniel-Constantin Mierla wrote: Hello, On 2/9/11 10:35 PM, Amit Nepal wrote: Hi, I have been trying to load rpid while loading credentials. modparam(auth_db, load_credentials, $avp(i:123)=rpid) Now, I am trying to do a check in my routing logic. xlog(L_NOTICE,The avp is :$avp(i:123)); (I dont get the value here either, i can't see the value when i do avp_print() if($avp(i:123)5) { sl_send_reply(408,Message Here); } I dont get the value of avp at that place. Any guidance please. Is this piece of config after a successful www/proxy_authenticate()? Cheers, Daniel ___ 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 -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] CORE postgres module
Hello, first, for postgres users i recommend to use version 3.1.2, since it has the reconnect part solved. As for 1.5.0, you should try with 1.5.5, since between 1.5.0 and 1.5.5 were many fixes (the config and db structure are the same so you don't need to change anything to update to 1.5.5) Cheers, Daniel On 2/14/11 8:23 PM, Bruno Bresciani wrote: Hi, During my tests with kamailio 1.5.0 a core is generated when postgres is disconnected and I try register a user or make a call in kamailio. Analising the module postgres source code I notice that core is generated by the PQescapeStringConn located in db_postgres_val2str function. Someone know why this core is generated? Best Regards ___ 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 -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] AVP Error in version 3.1.0
Hello, it is not clear for me what you tried to do. Can you paste here the parts of the config file that are relevant for the case? Do you relay the REGISTER? Cheers, Daniel On 2/16/11 1:17 AM, Jijo wrote: Hi All, On register we store the contact in an avp variable and do a t_relay(). After t_relay() the $avp variable becomes null. I printed the value before after t_relay() to determine this behavior. This happens only on registration load test around 2000 subcribers with ( 4 REGISTER/sec). This happens only for one subscriber out of 2000 subscribers. I did the similar test with $var and its working fine. Anybody observed similar behavior with avp? This was working in kamailio 1.4 version. We did the upgrade recently to 3.1.0 and started observing this issue. How do we debug this issue.? Thanks Jijo ___ 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 -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] Failover with UCARP and Monit
An option is to use in the UCARP VIP up/down scripts the commands: monit start kamailio monit stop kamailio Then monit will stop kamailio and no longer do options ping when the server is standby. Cheers, Daniel On 2/17/11 2:05 PM, Klaus Feichtinger wrote: Hi, I have built a similar solution with only one difference: I am using HEARTBEAT instead of ucarp. In heartbeat it is possible moving haresources from one active host to another. So, I activate MONIT (and mysql + kamailio) only when the resources (e.g. virtual IP address) are switched from one host to the other. A sample config of heartbeat looks like: [...] Srv1 drbddisk::dbdata \ Filesystem::/dev/drbd0::/mnt/drbdfiles::ext3 \ 10.0.0.1 mysql kamailio start-monit [...] Maybe you can use a pendant to these 'resources' in ucarp, too. I do not know any details. regard, Klaus Hello, I am setting up a high-availablilty kamailio system using UCARP to failover between active and standby instances. To detect failure, we intend to use Monit. Monit can monitor the kamailio PID and start the process when needed (Example on the wiki http://www.kamailio.org/dokuwiki/doku.php/install:configure-initd-script) and it can also do OPTIONS pings to verify it is working. If the pings fail we will initiate a ucarp swap. However if the server is currently in standby, it does not have the V-IP address, so I don't want to run the OPTIONS pings (I think). Does anyone use a similar system and can provide an example of how ucarp, monit and kamailio can work together? Many thanks, Hugh Waite ___ 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 -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] ACC og ACC_RADIUS module
Hello, On 2/16/11 9:33 PM, Morten Isaksen wrote: Hi, We have a OpenSER 1.1 platform running with radius accounting and I am in the progress of updating it to Kamailio 3.1. I am trying to decide if I should do accounting via Radius or directly to MySQL on the new platform. The only benefits a can see with Radius is that you can build some redundancy into your radius client. If one Radius server is failing then try the next and you can configure radius to log to a file if the DB is down. But i think you can get the same level of redundancy with a replicated DB setup with heartbeat/pacemaker. If I choose to do the accounting direct to MySQL I will skip the Radius layer (and one error source). Are there any other pros and cons? saying it from beginning, I haven't really used RADIUS very much so far, so I am pro-MySQL. Yes, you can use shared IP Active-Standby MySQL pair with cross replication, Kamailio will reconnect automatically when the connection is lost. I haven't gone for radius so far since the end storage was sql database anyhow, therefore I prefer to go directly there, for the reason you mentioned: one less point of failure in the platform. Cheers, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] Mediaproxy 2.4.4 sessions
Hello, I am using the rtpproxy, so I cannot really answer your question, but for tracking active calls you can just use dialog module. There are other options to do it manually in the config wusing some htable or db table, but easiest is with dialog module. Then you can see them via rpc/mi with sercmd/kamctl or in the database dialog table. Cheers, Daniel On 2/16/11 10:51 PM, Ricardo Martinez wrote: Hello. I’m using kamailio 3.1.2 and mediaproxy 2.4.4 . Is there a way to see the active media sessions like in the old mediaproxy? I was using the command ./sessions -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] Kamailio and Asterisk Realtime Integration using Asterisk Database
Hello, On 2/15/11 3:10 PM, Pavel Miskov wrote: Hi all, I am trying to integrate Kamailio and Asterisk as explained in http://kb.asipto.com/asterisk:realtime:kamailio-3.0.x-asterisk-1.6.2-astdb document but I have some problems. 1. When Asterisk sends the call back to Kamailio, Asterisk generates new INVITE but with wrong From URI. In From header, Display name is OK (Phone A) but From URI is wrong (it is URI of Phone B). this was reported to me privately, however it is nothing kamailio can do. Maybe asterisk is matching something by IP instead of username there. Try to force the caller id from asterisk dialplan. Play a bit with asterisk configs for peers/users/friends. Ultimately you can just send the caller id back to kamailio via some custom header and use uac_replace_from() to set the proper call id. Right now I don't have anymore the environment I used for testing, but I don't remember such issue. 2. When Phone B answers the call, Asterisk generates another INVITE to Phone B. When Phone B sends OK to this second INVITE Asterisk generates another INVITE to Phone A. 3. When Phone B sends BYE, Asterisk generates INVITE to Phone A and when it receives OK from Phone A it sends BYE to Phone A. This is probably some re-invites so asterisk gets out of media relaying. IIRC, there is related to canreinvite or such config option in asterisk sip channel. Cheers, Daniel I can fix the first problem with transformation in Kamailio but is this the way how it is supposed to work or I misconfigured something? I have tried this with kamailio 3.1 and asterisk 1.6.2.16.1 (and 1.8.2.3). -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] Kamailio 1.5.5 No TLS Segmentation Fault
it into 1.5.5 in time (revision 6049). Could you try the latest SVN of 1.5 and see if it solves the issue? Thanks. Cheers, --Timo On 14.02.2011 21:07, Stagg Shelton wrote: Hello, We have been having a problem with Kamilio faulting and dumping core files on occasion. I have not been able to reproduce the failure at will, but notice the back trace seems to point toward actions with the dialogue. Below is from a backtrace of a core file from just a few minutes ago. Can anyone determine what may have caused the system to error and stop processing? Thanks Stagg Core was generated by `/sbin/kamailio -m 512'. Program terminated with signal 11, Segmentation fault. #0 0x7f8a11d55fa7 in unref_dlg (dlg=0x7f89f7e07470, cnt=1) at dlg_hash.c:474 474 d_entry =(d_table-entries[dlg-h_entry]); Missing separate debuginfos, use: debuginfo-install bzip2-libs-1.0.5-5.fc11.x86_64 db4-4.7.25-11.fc11.x86_64 e2fsprogs-libs-1.41.9-2.fc11.x86_64 elfutils-libelf-0.147-1.fc11.x86_64 glibc-2.10.2-1.x86_64 keyutils-libs-1.2-5.fc11.x86_64 krb5-libs-1.6.3-31.fc11.x86_64 libacl-2.2.49-3.fc11.x86_64 libattr-2.4.43-3.fc11.x86_64 libcap-2.16-4.fc11.1.x86_64 libconfuse-2.6-2.fc11.x86_64 libgcc-4.4.1-2.fc11.x86_64 libselinux-2.0.80-1.fc11.x86_64 lm_sensors-3.1.0-1.fc11.x86_64 lua-5.1.4-3.fc11.x86_64 mysql-libs-5.1.46-1.fc11.x86_64 net-snmp-libs-5.4.2.1-13.fc11.x86_64 nspr-devel-4.8.4-1.3.fc11.x86_64 nss-devel-3.12.6-1.2.fc11.x86_64 nss-softokn-freebl-3.12.6-1.2.fc11.x86_64 openssl-0.9.8n-1.fc11.x86_64 pcre-7.8-2.fc11.x86_64 perl-libs-5.10.0-82.fc11.x86_64 popt-1.13-5.fc11.x86_64 radiusclient-ng-0.5.6-4.fc11.x86_64 rpm-libs-4.7.2-1.fc11.x86_64 tcp_wrappers-libs-7.6-55.fc11.x86_64 xz-libs-4.999.9-0.1.beta.20091007git.fc11.x86_64 zlib-1.2.3-22.fc11.x86_64 (gdb) bt full #0 0x7f8a11d55fa7 in unref_dlg (dlg=0x7f89f7e07470, cnt=1) at dlg_hash.c:474 d_entry = 0x0 __FUNCTION__ = unref_dlg #1 0x7f8a11d5180f in unref_dlg_from_cb (t=0x7f89f7d9c660, type=4096, param=0x7f8a1836a6e0) at dlg_handlers.c:622 dlg = 0x7f89f7e07470 #2 0x7f8a18138ea3 in run_trans_callbacks (type=4096, trans=0x7f89f7d9c660, req=0x0, rpl=0x0, code=0) at t_hooks.c:240 cbp = 0x7f89f7dc30e8 backup = 0x71a9d0 trans_backup = 0x __FUNCTION__ = run_trans_callbacks #3 0x7f8a181273cc in free_cell (dead_cell=0x7f89f7d9c660) at h_table.c:132 b = 0x0 i = 1 rpl = 0x0 tt = 0x0 foo = 0x7fff4282f190 p = 0x7f89f7d3b068 #4 0x7f8a18127bb6 in free_hash_table () at h_table.c:345 p_cell = 0x7f89f7d9c660 tmp_cell = 0x0 i = 4075 #5 0x7f8a181342a4 in tm_shutdown () at t_funcs.c:109 __FUNCTION__ = tm_shutdown #6 0x004529f6 in destroy_modules () at sr_module.c:321 t = 0x7349d0 foo = 0x734910 __FUNCTION__ = destroy_modules #7 0x0041f6b4 in cleanup (show_status=1) at main.c:331 No locals. #8 0x00420597 in handle_sigs () at main.c:517 chld = 0 chld_status = 134 i = 12 do_exit = 1 ---Typereturn to continue, or qreturn to quit--- shutdown_time = 60 __FUNCTION__ = handle_sigs #9 0x004217b5 in main_loop () at main.c:859 chd_rank = 12 i = 4 pid = 21442 si = 0x0 __FUNCTION__ = main_loop #10 0x00423410 in main (argc=3, argv=0x7fff4282f498) at main.c:1321 cfg_log_stderr = 0 cfg_stream = 0x1fe1010 c = -1 r = 0 tmp_len = 0 port = 0 proto = 4910128 ret = -1 rfd = 4 tmp = 0x7fff4282ff8a options = 0x4b77e0 f:cCm:b:l:n:N:rRvdDFETSVhw:t:u:g:P:G:W: rand_source = 0x4b7d9c /dev/urandom seed = 3628387751 __FUNCTION__ = main (gdb) (gdb) quit ___ 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 -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] Bad File Descriptor
Hello, what is the version you are using? On 2/17/11 7:35 PM, David J. wrote: 5(20390) ERROR: core [udp_server.c:586]: ERROR: udp_send: sendto(sock,0x7f67f7f94d14,4,0,69.117.34.101:2048,16): Bad file descriptor(9) 5(20390) ERROR: nathelper [nathelper.c:1722]: udp_send failed I see this error when I try to restart kamailio after crash; What is the cause for the crash? Do you have a log or core for that? I see the cause of this problem is 'stale' entries in the location table; If I delete this entries kamailio starts fine; any suggestions to prevent this from continuously happening. Is any change in the IP address of the server upon restart? Do the errors persist or they stop after a while? They are related to NAT keepalives sent by nathelper module, so they don't affect the sip traffic and if they are for stale contacts then they are fully harmless. The stale contacts should be automatically removed after a while by usrloc module. Cheers, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] Bad File Descriptor
Please keep the mailing list cc-ed. My previous email had other comments/questions inline, can you answer them as well? They are relevant in troubleshooting. Thanks, Daniel On 2/17/11 7:57 PM, David J. wrote: version: kamailio 3.1.1 (x86_64/linux) 88bda8 flags: STATS: Off, USE_IPV6, USE_TCP, USE_TLS, TLS_HOOKS, USE_RAW_SOCKS, DISABLE_NAGLE, USE_MCAST, DNS_IP_HACK, SHM_MEM, SHM_MMAP, PKG_MALLOC, DBG_QM_MALLOC, USE_FUTEX, FAST_LOCK-ADAPTIVE_WAIT, USE_DNS_CACHE, USE_DNS_FAILOVER, USE_NAPTR, USE_DST_BLACKLIST, HAVE_RESOLV_RES ADAPTIVE_WAIT_LOOPS=1024, MAX_RECV_BUFFER_SIZE 262144, MAX_LISTEN 16, MAX_URI_SIZE 1024, BUF_SIZE 65535, PKG_SIZE 4MB poll method support: poll, epoll_lt, epoll_et, sigio_rt, select. id: 88bda8 compiled on 04:39:27 Dec 9 2010 with gcc 4.3.2 On 2/17/11 1:46 PM, Daniel-Constantin Mierla wrote: Hello, what is the version you are using? On 2/17/11 7:35 PM, David J. wrote: 5(20390) ERROR: core [udp_server.c:586]: ERROR: udp_send: sendto(sock,0x7f67f7f94d14,4,0,69.117.34.101:2048,16): Bad file descriptor(9) 5(20390) ERROR: nathelper [nathelper.c:1722]: udp_send failed I see this error when I try to restart kamailio after crash; What is the cause for the crash? Do you have a log or core for that? I see the cause of this problem is 'stale' entries in the location table; If I delete this entries kamailio starts fine; any suggestions to prevent this from continuously happening. Is any change in the IP address of the server upon restart? Do the errors persist or they stop after a while? They are related to NAT keepalives sent by nathelper module, so they don't affect the sip traffic and if they are for stale contacts then they are fully harmless. The stale contacts should be automatically removed after a while by usrloc module. Cheers, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] ERROR: failover functions used, but AVPs paraamters required are NULL
ok, thanks for reporting back so future reads of the mailing list archive points to the solution. Cheers, Daniel On 2/17/11 4:23 PM, Gary Chen wrote: Never mind. I used wrong kamailio.cfg file. *From:*Daniel-Constantin Mierla [mailto:mico...@gmail.com] *Sent:* Thursday, February 17, 2011 8:51 AM *To:* Gary Chen *Cc:* sr-users@lists.sip-router.org *Subject:* Re: [SR-Users] ERROR: failover functions used, but AVPs paraamters required are NULL Hello, can you send all log messages printed by: kamailio -E -ddd Thanks, Daniel On 2/17/11 2:42 PM, Gary Chen wrote: kamailio version 3.1.2 I am trying to setup dispatcher to use its failover feature. Here is dispatcher part of configure file: loadmodule dispatcher.so modparam(dispatcher, db_url, DBURL) modparam(dispatcher, table_name, dispatcher) modparam(dispatcher, ds_ping_interval, 30) modparam(dispatcher, ds_probing_threshhold, 10) modparam(dispatcher, ds_ping_reply_codes, class=2;class=4) modparam(dispatcher, ds_probing_mode, 1) modparam(dispatcher, ds_ping_from, sip:lb1 at m-lab-ca805-sig.kd-lab.de) modparam(dispatcher, dst_avp, $avp(dsdst)) modparam(dispatcher, grp_avp, $avp(dsgrp)) modparam(dispatcher, cnt_avp, $avp(dscnt)) modparam(dispatcher, attrs_avp, $avp(dsattrs)) modparam(dispatcher, dstid_avp, $avp(dsdstid)) modparam(dispatcher, flags, 2) But it is still give the following error: 0(1917) ERROR: dispatcher [dispatcher.c:624]: failover functions used, but AVPs paraamters required are NULL -- feature disabled Does anybody know why? Gary ___ SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org mailto:sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users -- Daniel-Constantin Mierla http://www.asipto.comhttp://www.asipto.com ___ 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 -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] AVP Error in version 3.1.0
Hello, is any particular reason to do the processing after t_relay() ? You can do the save before, since it is the same register message. Also, are you getting this in a testing environment while using tools like sipp to simulate traffic? Starting with 3.0, the AVPs (which are associated with the message and transaction in this case) become available in onreply_route[3] (in 1.x that was a config option for tm module), so if it is fast reply, it my happen that the avps are no longer available in the script after t_relay(). As a recommended rule, it is better to avoid using avps after t_relay() - this function creates the transaction and forwards the message. From there on, the avps are in the hands of tm module, which moves them to onreply_route or failure_route, depending on your config file. Cheers, Daniel On 2/16/11 4:28 PM, Jijo wrote: Hi Daniel, Please find the code and corresponding error trace. This happens only for 1 subscriber randomly out of 2000 subscribers. This can be reproduced consistently also. route(1) { : : : # - # Registration handling dynamic endpoints # - $avp(reg_contact)= $ct; $var(reg_contact)= $ct; t_on_reply(3); if(!is_avp_set($avp(reg_contact))) xlog(L_ERR, R1 - not set the reg_contact3 F=$fu T=$tu Ct=$ct IP=$si CI=$ci var_contact:$var(reg_contact)\n); # relay if(!t_relay_to(0x3)) { xlog(L_ERR, R1/R10 - Registration failed - M=$rm F=$fu T=$tu CT=$ct IP=$si CI=$ci\n); append_to_reply(Warning: 399 $Ri - R1 - Registration failed: fail in relay in R10.\r\n); sl_reply_error(); exit; } if(!is_avp_set($avp(reg_contact))) xlog(L_ERR, R1 - not set the reg_contact4 F=$fu T=$tu Ct=$ct IP=$si CI=$ci var_contact:$var(reg_contact)\n); xlog(L_ERR, R1 - Saving Registration-2 save to location F=$fu T=$tu Ct=$ct IP=$si CI=$ci reg_ct:$avp(reg_contact)\n); if(!isflagset(28) is_avp_set($avp(reg_contact))) # Check if we need to save it in location table { if(!save(location,0x02)) { xlog(L_ERR, R1 - Location save for Registration failed - M=$rm F=$fu T=$tu IP=$si CT=$ct\n); } } LOGS for the error condtion. 2011-02-15T12:19:30-05:00 [err] sipserver: ERROR: script: R1 - not set the reg_contact4 F=sip:5614510478@10.235.86.54:5060;transport=UDP T=sip:5614510478@10.235.86.54:5060;transport=UDP Ct=sip:5614510478@10.235.204.5:5060 http://sip:5614510478@10.235.204.5:5060 IP=10.235.204.5 CI=119ac328-4cceb0a-13c4-7fa55-76a2903a-7fa55 var_contact:sip:5614510478@10.235.204.5:5060 http://sip:5614510478@10.235.204.5:5060 2011-02-15T12:19:30-05:00 [err] sipserver: ERROR: script: R1 - Saving Registration-2 save to location F=sip:5614510478@10.235.86.54:5060;transport=UDP T=sip:5614510478@10.235.86.54:5060;transport=UDP Ct=sip:5614510478@10.235.204.5:5060 http://sip:5614510478@10.235.204.5:5060 IP=10.235.204.5 CI=119ac328-4cceb0a-13c4-7fa55-76a2903a-7fa55 reg_ct:null On Wed, Feb 16, 2011 at 5:02 AM, Daniel-Constantin Mierla mico...@gmail.com mailto:mico...@gmail.com wrote: Hello, it is not clear for me what you tried to do. Can you paste here the parts of the config file that are relevant for the case? Do you relay the REGISTER? Cheers, Daniel On 2/16/11 1:17 AM, Jijo wrote: Hi All, On register we store the contact in an avp variable and do a t_relay(). After t_relay() the $avp variable becomes null. I printed the value before after t_relay() to determine this behavior. This happens only on registration load test around 2000 subcribers with ( 4 REGISTER/sec). This happens only for one subscriber out of 2000 subscribers. I did the similar test with $var and its working fine. Anybody observed similar behavior with avp? This was working in kamailio 1.4 version. We did the upgrade recently to 3.1.0 and started observing this issue. How do we debug this issue.? Thanks Jijo ___ SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org mailto:sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users -- Daniel-Constantin Mierla http://www.asipto.com -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] Visiting CeBIT 2011 in Hanover
Hello, I am going to visit CeBIT show this year (first week of March in Hanover, Germany), if anyone else here is there and want to meet for a chat about latest developments in the project and VoIP world, drop me an email, maybe we have some overlapping days and can sit together for a bit. Cheers, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] Kamailio Awards 2010
Hello, almost a tradition by now, being the 4th edition, I published Kamailio Awards for 2010 - a blog post that tries to summarize the top of the activities in the public space related to Kamailio project that happened during the previous year. You can browse it at: http://asipto.com/u/ka10 Cheers, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] get_profile_size() function help (Alex Balashov)
What is the version of kamailio used here? I did a fix for this function when it takes three parameters sometime by end of last year, so if you are not using the latest version, just upgrade to it and see if the issue still persists. Cheers, Daniel On 2/22/11 6:38 PM, Henning Westerholt wrote: On Tuesday 22 February 2011, 侯旭光 wrote: On 02/21/2011 04:50 AM, ??? wrote: ALTER:core [main.c 722] : child process 29651 exited by sinal 11 ALTER:core [main.c 725] : core was generated INFO :core [main.c 737] : terminating due to SIGCHILD This is a crash. It's a bug. Then how to get the number of dialogs belonging to a profile? Hi 侯旭光, well, the server should return the number of dialogs here - that it crashs its not normal, of course. :-) Can you take a look to the core dump that was generated and post the result here on the list? More informations can be find here: http://www.kamailio.org/dokuwiki/doku.php/troubleshooting:corefiles Cheers, Henning ___ 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 -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] kamailio 3.1: forward(10.0.0.10:5060) not working?
Hello, after integration of the new core between Kamailio and SER this function changed and I guess the wiki is still having the old prototype. Try: forward(67.154.xx.xx, 5080); and see if this one works for you. Cheers, Daniel On 2/22/11 7:30 PM, Min Wang wrote: HI It seems the forward(host:port) not working in the kamailio 3.1? the simple route like: route { forward(67.154.xx.xx:5080); } the error is: core [proxy.c:278]: ERROR: mk_proxy: could not resolve hostname: 67.154.xx.xx:5080 Anything missing? the detailed log is: 0(8500) DEBUG: core [sr_module.c:625]: find_export_record: found load_tm in module tm [/usr/lib/kamailio/modules/tm.so] 0(8500) DEBUG: core [sr_module.c:625]: find_export_record: found t_newtran in module tm [/usr/lib/kamailio/modules/tm.so] 0(8500) DEBUG: core [sr_module.c:625]: find_export_record: found t_relay_to_tcp in module tm [/usr/lib/kamailio/modules/tm.so] 0(8500) DEBUG: core [sr_module.c:625]: find_export_record: found t_relay_to_udp in module tm [/usr/lib/kamailio/modules/tm.so] 0(8500) DEBUG: core [sr_module.c:625]: find_export_record: found t_relay in module tm [/usr/lib/kamailio/modules/tm.so] 0(8500) DEBUG: core [sr_module.c:625]: find_export_record: found t_forward_nonack in module tm [/usr/lib/kamailio/modules/tm.so] 0(8500) DEBUG: core [sr_module.c:625]: find_export_record: found t_release in module tm [/usr/lib/kamailio/modules/tm.so] 0(8500) DEBUG: core [main.c:2371]: Expect (at least) 18 SER processes in your process list 0(8500) DEBUG: core [proxy.c:278]: DEBUG: mk_proxy: doing DNS lookup... 0(8500) DEBUG: core [dns_cache.c:567]: dns_hash_find(_sip._udp.67.154.xx.xx:5080(28), 33), h=780 0(8500) DEBUG: core [resolve.c:727]: get_record: lookup(_sip._udp.67.154.xx.xx.:5080, 33) failed 0(8500) DEBUG: core [dns_cache.c:895]: dns_cache_mk_bad_entry(_sip._udp.67.154.xx.xx:5080, 33, 60, 1) 0(8500) DEBUG: core [dns_cache.c:828]: dns_cache_add: adding _sip._udp.67.154.xx.xx:5080(28) 33 (flags=1) at 780 0(8500) DEBUG: core [dns_cache.c:567]: dns_hash_find(67.154.xx.xx:5080(18), 1), h=16 0(8500) DEBUG: core [resolve.c:727]: get_record: lookup(67.154.xx.xx:5080, 1) failed 0(8500) DEBUG: core [dns_cache.c:895]: dns_cache_mk_bad_entry(67.154.xx.xx:5080, 1, 60, 1) 0(8500) DEBUG: core [dns_cache.c:828]: dns_cache_add: adding 67.154.xx.xx:5080(18) 1 (flags=1) at 16 0(8500) : core [proxy.c:278]: ERROR: mk_proxy: could not resolve hostname: 67.154.xx.xx:5080 0(8500) ERROR: core [route.c:1161]: fixing failed (code=-478) at cfg:/etc/kamailio/kamailio.cfg:394 ERROR: error -478 while trying to fix configuration 0(8500) DEBUG: tm [t_funcs.c:122]: DEBUG: tm_shutdown : start 0(8500) DEBUG: tm [t_funcs.c:125]: DEBUG: tm_shutdown : emptying hash table 0(8500) DEBUG: tm [t_funcs.c:127]: DEBUG: tm_shutdown : removing semaphores 0(8500) DEBUG: tm [t_funcs.c:129]: DEBUG: tm_shutdown : destroying tmcb lists 0(8500) DEBUG: tm [t_funcs.c:132]: DEBUG: tm_shutdown : done 0(8500) DEBUG: core [mem/shm_mem.c:236]: shm_mem_destroy 0(8500) DEBUG: core [mem/shm_mem.c:239]: destroying the shared memory lock thx. -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] UAC Module: test registration to a Voip provider
Hello, On 2/21/11 1:10 PM, Matteo Campana wrote: Hi all, we are using the UAC module (http://www.kamailio.org/docs/modules/stable/modules_k/uac.html#id2910015) to register the proxy to an external DID provider. I know that the module takes care of sending REGISTER on the basis of credentials stored in uacreg table, but my question is: if I add a new row in the uacreg table, kamailio will register the new username after the database update or I need a restart of kamailio (or some kamailio module)? If I edit the row in uacreg table and I call the rpc command /sercmd uac.reg_dump /I see the old values in the output, but if I restart kamailio I see the new values. you have to restart it, there is no reload RPC command yet for uac registrations. Cheers, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] decimal fraction problem
Hello, On 2/21/11 10:28 AM, 侯旭光 wrote: Hello I need to add q value while using function append_branch(),but the function only takes decimal fraction as the parameter. What if I want to use pv to add q value? The $var and $avp just have string and integer type. Thanks a lot! do: km_append_branch($var(branchuri)); $(branch(q)[-1]) = $var(q); $var(q) has to hold an integer value that represents the decimal fraction value multiplied with 100 (so if q should be 0.5, then $var(q) = 50). Cheers, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] Unable to start Siremis
On 2/20/11 3:34 PM, j...@4voice.net wrote: I have installed the latest Kamailio and have it running. When trying to run Siremis-2.0.0, i get the following error message The requested URL /siremis/system/general_default was not found on this server * I have made sure that the mod_rewrite is enabled in my apacher server * I have made sure that the directories o + siremis/log + siremis/session + siremis/files + siremis/themes/default/template/cpl All have write access Stuck Have you done: make prepare in the siremis directory? Cheers, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] pipelimit db schema
Hello, On 2/23/11 12:30 AM, thrillerbee wrote: Can anyone point me to the db schema for the new pipelimit module? seems I forgot to add it to db creation script. I will fix that in the next days. Meanwhile you can use: INSERT INTO version (table_name, table_version) values ('pl_pipes','1'); CREATE TABLE pl_pipes ( id INT(10) UNSIGNED AUTO_INCREMENT PRIMARY KEY NOT NULL, pipeid VARCHAR(64) DEFAULT '' NOT NULL, algorithm VARCHAR(32) DEFAULT '' NOT NULL, plimit INT DEFAULT 0 NOT NULL, CONSTRAINT pipeid_idx UNIQUE (pipeid) ) ENGINE=MyISAM; This is inside sources, modules/pipelimit/pl_db.c Thanks, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] How to get the dialog information via dlg_list command?
Hello, the problem is you are using the dialog module coming from SER, not the one coming from Kamailio. The loadpath (or mpath) has to include directorins ending in modules_k and modules. I recommend you use kamailio.cfg as a start to build your config and then add the dialog module. Before compiling, when you are using the sources, you have to do: make FLAVOUR=kamailio cfg You can see more at: http://www.kamailio.org/dokuwiki/doku.php/install:kamailio-3.1.x-from-git If you prefer to install deb files (on Debian/Ubuntu), see: http://www.kamailio.org/dokuwiki/doku.php/packages:debs Cheers, Daniel On 2/23/11 7:32 AM, yan wang wrote: Dear Friends, I need your help on the following question: I am using Kamailio 3.1.2. I want to get the dialog information dynamically via the FIFO command dlg_list by kamctl fifo dlg_list. But unfortunately, I could get NOTHING in the output. And the fact is that I have setup 5 pairs SIP calls with the Kamailio SIP proxy. Could anyone show me the clues and how to get the correct dialog information? Thanks. BTW, I attached the config file. Best Regards, Spencer ___ 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 -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] UC Expo 2011, London, next week
Hello, I will be visiting the first day of UC Expo in London (http://www.ucexpo.co.uk/), Tuesday, March 8. If you are going to be there and want to meet for a chat about Kamailio VoIP, drop me an email. Cheers, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] dispatcher confusion
Hello, On 2/28/11 5:29 PM, Klaus Darilion wrote: Hi! Every time I use the dispatcher(k) module I am confused again. Sometimes it seems that probing is a dedicated state, sometimes it seems that probing is done also in active state, but never in inactive state. if you set the global parameter for probing, then no matter the state, the pinging is done for all addresses. If the module parameter is not set, only the destinations marked as probing should be pinged. In devel version I tried to sort out a bit these states, so we should make it more sane and clear. IMO probing should only be a flag which indicates if OPTIONS should sent or not. If probing is successful, then the state should be active. If probing is unsuccessful, then the state should be inactive. Current behavior is very strange (ds_probing_mode(0)): -- startup state: A -- no probing kamctl fifo ds_set_state i 1 sip: -- state: I -- no probing kamctl fifo ds_set_state a 1 sip: -- state: A -- no probing When ds_probing_mode==0, only if you set P flag to address will be pinged. calling 3 times ds_mark_dst(p) -- state: P -- probing (and dst is still loaded as last value into the dst_avp, why?) kamctl fifo ds_set_state i 1 sip: -- state: I -- still probing kamctl fifo ds_set_state a 1 sip: -- state: P (???) -- probing Thus, ds_set_state a ... does not set active, but probing if it was probing before. Strange. And as inactive does not stop probing when dst was in probing mode, the destination becomes automatically active if the probing succeeds. inactive and probing are different flags. In devel I introduced new state 'disabled' for cases when you want to remove an address from destination list. And why is a destination in probing mode loaded into the dst_avp? Very weird. If it is just probing and not inactive, then it is loaded as new dst. Is there a reason for this behavior? IIRC, I think Carsten developed most of the probing mode, maybe there was a reason behind current behavior. Cheers, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] modulo operator
Hello, On 2/28/11 9:15 PM, Klaus Darilion wrote: Hi! Using kamailio 3.1.1, I failed to use '%' as described in the core cookbook. Using 'mod' instead seems to work. % was used in SER for some attributes AFAIK -- looking at cfg.lex -- so I changed it to 'mod' only in 3.x. I should check again if the conflict really exists and/or can be avoided. For now using 'mod' is the option to go. Cheers, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] Segfault in Kamailio 1-3-4 to 1.5.5
On 3/1/11 8:41 AM, Andrew O. Zhukov wrote: I someone interested in . It's the old coredumps from 1.3.4. It's really much stabile then 1.5.5 I did degrade today night version 1.3.x is openser only which became later kamailio, practically is no other option for this version. Have you considered upgrading to latest stable (3.1.x) instead of downgrade? Cheers, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] Segfault in Kamailio 1-3-4 to 1.5.5
On 2/28/11 8:06 AM, Andrew O. Zhukov wrote: As I understood you do not provide any support for a legacy versions. In the first place, the problem is you are using very old versions and it is very unlikely someone has a testbed for them. I and many others still have such versions running, but never happened to crash, it has to be something specific, like a not very common module or particular sip request that triggers this one. I tried to help you in the spare time, which didn't happen to be that much lately. Your way of answering the questions was also consuming a lot of such cycles. Normally, yes, we officially support the latest two stable version, those being now 3.0 and 3.1. And it is really advisable to use the latest stable. But as you could see, we don't mind doing it for older version when we can, but that is not always possible we current constraints of time and load. Even if you are willing to get paid support, it is not always possible to get it from a day to the next one, people travel or have other project booked some time ago. Cheers, Daniel On 02/25/2011 09:00 AM, Andrew O. Zhukov wrote: In continue of letters: Kamailio 1.5.5 No TLS Segmentation Fault After upgrade from openser 1.3.4 to kamailio 1.5.5 the same crash set Can someone from developers provide me commercial support to fix this bug in malloc module. If so, contact me directly. -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] Kamailio Installation
Hello, I don't get why you have errors regarding the xml files. Have you set the FLAVOUR=kamailio? Maybe you can follow the next tutorial and adapt it for redhat: http://www.kamailio.org/dokuwiki/doku.php/install:kamailio-3.1.x-from-git Practically it is about the installation of dependencies. The compileinstall 'make' commands are the same. Cheers, Daniel On 2/28/11 7:08 AM, Suresh Bhandari wrote: Hello Community, I am new to Kamailio, and this list as well. I am trying to install Kamailio 3.1.2, but I am getting too many errors. I have fixed some but still not getting the way. I am using Red Hat Enterprise Linux (RHEL) 5, and /usr/local directory. When I ran the following command: make group_include=standard standard-dep mysql include_modules=carrierroute peering install it prompted not found error for the file docbookx.dtd, I found it (modules/auth/auth.xml, and modules_s/acc_syslog/acc_syslog.xml) and fixed it as it was errorenous URL location. For reference earlier it was http://www.oasis-open.org/docbookid/id/g/4.5/docbookx.dtd, which I changed to http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd. Now when I run the previous command again, I am getting the follwing errors: /nsgmls:URLhttp://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd:116:17:E: X20AC is not a function name/ If I ignore this, and continue, I am not able to find the sip-router service in /etc/init.d. The entire errors is attached here. Please help me solve the issue. TIA Suresh ___ 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 -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] Segfault in Kamailio 1-3-4 to 1.5.5
On 3/1/11 10:02 AM, Andrew O. Zhukov wrote: On 03/01/2011 10:49 AM, Daniel-Constantin Mierla wrote: On 3/1/11 8:41 AM, Andrew O. Zhukov wrote: I someone interested in . It's the old coredumps from 1.3.4. It's really much stabile then 1.5.5 I did degrade today night version 1.3.x is openser only which became later kamailio, practically is no other option for this version. Have you considered upgrading to latest stable (3.1.x) instead of downgrade? Daniel, I sent you my config. How can I do it on a hi usage production server for a one night. The lot of fixes for a different buggy customers SIP and NAT devices which is impossible to retest again. Sending the config is not enough, since I can not use it in my server, I do not have your kind of traffic. The config is good when is some misrouting or syntax error, but for this specific case the investiagation of core and adding some patches to print more information when the crash is happening is the way to solve. I sent you some patches, that were not good enough because I had no 1.5 around and I was offline. More than that, I can count 3-4 more developers that tried to help you on the public mailing list, even you play with very old versions. As said, everyone tries to do it in available time and its own conditions. I would need access to the server to investigate the core dump myself -- you offered that but being traveling was not for me at that time. My interest is to discover if it something that affects 3.x, although we changed the internal architecture a lot, might be some cases existing in 1.x still applying in 3.x What I don't understand is the complain regarding testing. When you did the upgrade to 1.5 from 1.3, you had to do changes everywhere, there were major versions. Same would be for a migration from 1.5 to 3.1. You can even have them both installed, using shared database so you can start/restart with older or newer versions. I did it many times and it goes smooth, just few tables have changed the structure, for that case you can use different databases. Cheers, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] modulo operator
On 3/1/11 10:26 AM, Klaus Darilion wrote: Am 01.03.2011 09:46, schrieb Daniel-Constantin Mierla: Hello, On 2/28/11 9:15 PM, Klaus Darilion wrote: Hi! Using kamailio 3.1.1, I failed to use '%' as described in the core cookbook. Using 'mod' instead seems to work. % was used in SER for some attributes AFAIK -- looking at cfg.lex -- so I changed it to 'mod' only in 3.x. I should check again if the conflict really exists and/or can be avoided. For now using 'mod' is the option to go. I added some text to the core coookbooks. Thanks, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] about tmx:inuse_transactions stat
Hi Juha, On 3/1/11 9:34 AM, Juha Heinanen wrote: Juha Heinanen writes: regarding tmx:inuse_transactions stat, it does not seem to exist among tm.stats: ... or does it have the same value as created - freed? a took a look at the code and tmx inuse_transactions seems to be equal to tm current transactions. you are right, I saw your email but I forgot to answer it. SER core, sl tm exported more stats in regard to transactions and replies, so I kept that version when we integrated and exported them via K stats API. Cheers, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] NAT Traversal
Hello, one option might be a bad ALG implementation in the router. Can you send a full ngrep of such case? You can obfuscate the IP addresses, use different ones for each point in the network and leave the ports. Seeing SIP headers and SDP can indicate the presence of an ALG or something broken in config logic. Also, what is the parameter you give to force_rtp_proxy(...)? Cheers, Daniel On 3/2/11 8:38 AM, Spinov Evgeniy wrote: May be I miss some important details? No suggestions? Thank you. Hello, all. Using nathelper + rtpproxy for subj. Kamailio has public and private network interfaces. Asterisk is only private. RTP Proxy is working in bridge mode and relaying traffic from UAC to Asterisks. Everything is working fine, except one configuration. When the client is behind router ( a specific one, I do not have an access there to check ), and this UAC is making a call to other public extension, which is behind router, then RTP Proxy is relaying traffic to the caller, using another UDP port, then the packets arrive. For instance: UAC 1 - UAC 2 PUBLIC_IP:10 KAMAILIO_IP: KAMAILIO_IP:5678 PUBLIC_IP:12 While for the UAC 2 it looks like: PUBLIC_IP:20 KAMAILIO_IP:6767 KAMAILIO_IP:4564 PUBLIC_IP:20 The source and destination UDP ports are the same. As result, I can hear UAC 1 and he cannot hear me. In case of we have UAC 3, which is behind other router, call is working fine with same configuration. It's routers fault you can say, but in the same configuration ( I mean network, not kamailio ) it worked, but when RTPProxy was not in bridge mode and Kamailio and Asterisks were in public network. Reinvites are not allowed in both cases. The question is, why the source and destination UDP ports are different? Using STUN in first case, cause without it, private IP written in contacts and as result, traffic relayed from Kamailio is incorrect, cause heading to private network which is unreachable. Any ideas where to dig? ___ 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 -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] Radius authentication
); sl_send_reply(401, Invalid Password); case -1: xlog(L_INFO, - 401: invalid user); sl_send_reply(401, Invalid User); default: xlog(L_INFO, - 401: unauthorized); sl_send_reply(401, Unauthorized); } } But... I got that in the debug of Kamailio: *Code:* 4(31099) DEBUG: auth [api.c:95]: auth: digest-algo: MD5 parsed value: 1 4(31099) DEBUG: auth_radius [sterman.c:271]: radius_authorize_sterman(): Success 4(31099) WARNING: auth_radius [authorize.c:89]: RADIUS server did not send SER-UID attribute in digest authentication reply 4(31099) DEBUG: auth [challenge.c:102]: build_challenge_hf: realm='i2cat.net http://i2cat.net' 4(31099) DEBUG: auth [challenge.c:113]: build_challenge_hf: qop='auth' 4(31099) DEBUG: auth [challenge.c:236]: auth: 'WWW-Authenticate: Digest realm=i2cat.net http://i2cat.net, nonce=TWZJLk1mSAKFVzL0b+dVPzkuyyAnZHQs, qop=auth I guess it has something to do with this SER-UID attribute and thus something about the dictonary? It is weird seeing that the radius server says 'ok' but then openser is not authenticating it. I need some clues! Thank you!. -- Pablo Ros ___ 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 -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] how to combine alias_db_lookup() with lookup()
Hello, On 2/27/11 3:46 AM, x-kamai...@sidell.org wrote: I'm trying to use the db_alias module as a way to define generic addresses that map to a set of actual phones. For example, I'd like the alias h...@foo.bar to map to kitc...@foo.bar and off...@foo.bar, so that both phones ring when a call comes in to home. I have set the append_branches param to 1: modparam(alias_db, append_branches, 1) I also modified the dbaliases database table so that key alias_idx isn't unique, thereby allow me to add multiple rows for the same alias. The relevant script section is taken verbatim from 3.1 kamailio.cfg: # USER location service route[LOCATION] { #!ifdef WITH_ALIASDB # search in DB-based aliases alias_db_lookup(dbaliases); #!endif if (!lookup(location)) { switch ($rc) { case -1: case -3: xlog( L_WARN, XXX $ru $fu\n); t_newtran(); t_reply(404, Not Found); exit; case -2: sl_send_reply(405, Method Not Allowed); exit; } } # when routing via usrloc, log the missed calls also if (is_method(INVITE)) { setflag(FLT_ACCMISSED); } } When I place a call to an alias, the kamailio debug log shows that alias_db_lookup() is correctly setting the ruri to the first entry found in the table, and using append_branch() to add the others. But only the first matching phone gets an INVITE, not the others. I suspect that the lookup() call is blowing away the branches set up by alias_db_lookup() and replacing them with the single phone that matches the ruri for the first alias entry. Is there a way to get alias_db_lookup() and lookup() to play together, so that the first function can set up a list of branches, and the second function can resolve all of the branches to the actual device locations? the branches added by alias_db are not lost, but they are sent back to you over loopback. They get dropped probably because they are authenticated. Try to watch the traffic on loopback with ngrep just to see if I am right: ngrep -d any -qt -W byline port 5060 The solution in this case is to have a condition in route[AUTH] for non-REGISTER requests, something like: if(src_ip==myself) return; before doing proxy_authenticate(). Cheers, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] NAT Traversal
On 3/2/11 9:32 AM, Spinov Evgeniy wrote: Unfortunately ngrep is unavailable right now, cause network was configured to use public IPs. May be I'll can do that on development network later. Right now development network using public`s also. I'll try to sort out ngrep anyway. I was giving FAEI to INVITEs from UAC to Asterisk and FAIE to INVITEs from Asterisks to UAC. Everything was good except destination UDP port to UAC 1. It was different then the source. As result UAC 1 didn't received backflow. You say about wrong port for RTP or for SIP? For SIP be sure you call force_rport(). For RTP try eventually the flag 'r' in in parameters of force_rtp_proxy(). Also, may be this will help: Kamailio was unable to identify that faulty UAC 1 is behind the NAT. I've tried nat_uac_test(31), however - nothing, while SIP headers were containing NATed IPs. By NATed ip you mean private class, like 10... or 192.168...? If yes, that is strange, can you add debugger module with cfgtrace enabled to see what lines in the config file are executed for that call? (this is assuming you are using v3.1.x, if not add xlog() messages in the config to be sure the nat handling part is executed). Cheers, Daniel So during tests I've just forced NAT always. Without that I didn't had audio at all. While with it - one way audio with faulty UAC and normal call for all others. Also, on faulty UAC 1 I had to use STUN server, while all other clients worked without it. After going Asterisks public and changing kamailio configuration for it, STUN no longer needed anywhere. Just assuming fact, that router has bad ALG implementation. Is there any workaround for it, may be forcing destination ports to source ones? On Wed, 2011-03-02 at 09:30 +0100, Daniel-Constantin Mierla wrote: Hello, one option might be a bad ALG implementation in the router. Can you send a full ngrep of such case? You can obfuscate the IP addresses, use different ones for each point in the network and leave the ports. Seeing SIP headers and SDP can indicate the presence of an ALG or something broken in config logic. Also, what is the parameter you give to force_rtp_proxy(...)? Cheers, Daniel On 3/2/11 8:38 AM, Spinov Evgeniy wrote: May be I miss some important details? No suggestions? Thank you. Hello, all. Using nathelper + rtpproxy for subj. Kamailio has public and private network interfaces. Asterisk is only private. RTP Proxy is working in bridge mode and relaying traffic from UAC to Asterisks. Everything is working fine, except one configuration. When the client is behind router ( a specific one, I do not have an access there to check ), and this UAC is making a call to other public extension, which is behind router, then RTP Proxy is relaying traffic to the caller, using another UDP port, then the packets arrive. For instance: UAC 1 - UAC 2 PUBLIC_IP:10 KAMAILIO_IP: KAMAILIO_IP:5678 PUBLIC_IP:12 While for the UAC 2 it looks like: PUBLIC_IP:20 KAMAILIO_IP:6767 KAMAILIO_IP:4564 PUBLIC_IP:20 The source and destination UDP ports are the same. As result, I can hear UAC 1 and he cannot hear me. In case of we have UAC 3, which is behind other router, call is working fine with same configuration. It's routers fault you can say, but in the same configuration ( I mean network, not kamailio ) it worked, but when RTPProxy was not in bridge mode and Kamailio and Asterisks were in public network. Reinvites are not allowed in both cases. The question is, why the source and destination UDP ports are different? Using STUN in first case, cause without it, private IP written in contacts and as result, traffic relayed from Kamailio is incorrect, cause heading to private network which is unreachable. Any ideas where to dig? ___ 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 -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] WARNING: core [db_id.c:281]: identical DB URLs, but different DB connection pid [30123/30107]
On 3/4/11 8:59 PM, Juha Heinanen wrote: Klaus Darilion writes: So, when it is fixed, why printing a WARNING? Is it something I have to be aware of? I use mysql with 3 modules doing DB lookups. I get this warning 3 times. Since ever usually most modules use the same db_url. So I am confused. If there isn't a problem anymore we should change the WARNING to an DBG. i agree with klaus. if a module does not use db correctly, it needs to be fixed. otherwise, please change log level to debug. I will change that. The warning is fully harmless, but I let it for a while just to be sure is all fine. The update done could have caused kamailio not to start if some module would do some extra internal checks over the existence of db connection -- the warning would give a clear indication about what could be the issue in such case. Cheers, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] Kamailio auth_radius: duplicate User-Name attribute
Hello, what is the value of parameter radius_extra for acc module? Cheers, Daniel On 3/4/11 1:06 PM, Kosilov Fedor wrote: Hello List! I'm trying to set up authorization with our billing proprietary radius server, using Freeradius as a proxy. Currently I'm experiencing the following problem: The Access-Request packet, sent by Kamailio, contains two User-Name attribute records Here is a log from the Freeradius server: rad_recv: Access-Request packet from host 127.0.0.1 port 59294, id=112, length=298 User-Name = 2219...@example.com mailto:2219...@example.com Digest-Attributes = 0x0a0932323139303031 Digest-Attributes = 0x01106c696e6b2d726567696f6e2e7275 Digest-Attributes = 0x022254584452634531773045524b7368796f30684a70544f4f6a69424d386b32534a Digest-Attributes = 0x04147369703a6c696e6b2d726567696f6e2e7275 Digest-Attributes = 0x030a5245474953544552 Digest-Attributes = 0x050661757468 Digest-Attributes = 0x090a3030303030303031 Digest-Attributes = 0x080c32383034636535373032 Digest-Response = e79b47955c02401fe52d05f7956609aa Service-Type = Sip-Session Sip-Uri-User = 2219001 *User-Name = call-id=domcmqmnychbwlp@koffe-work* NAS-Identifier = kamserv.example.com http://kamserv.example.com NAS-Port = 5060 NAS-IP-Address = 127.0.0.1 # Executing section authorize from file /etc/freeradius/sites-enabled/default +- entering group authorize {...} ++[preprocess] returns ok ++[chap] returns noop ++[mschap] returns noop [digest] Checking for correctly formatted Digest-Attributes [digest] Digest-Attributes look OK. Converting them to something more usful. Digest-User-Name = 2219001 Digest-Realm = example.com http://example.com Digest-Nonce = TXDRcE1w0ERKshyo0hJpTOOjiBM8k2SJ Digest-URI = sip:example.com http://example.com Digest-Method = REGISTER Digest-QOP = auth Digest-Nonce-Count = 0001 Digest-CNonce = 2804ce5702 [digest] Adding Auth-Type = DIGEST ++[digest] returns ok [suffix] Looking up realm example.com http://example.com for User-Name = 2219...@example.com mailto:2219...@example.com [suffix] Found realm example.com http://example.com [suffix] Adding Realm = example.com http://example.com [suffix] Proxying request from user 2219001 to realm example.com http://example.com [suffix] Preparing to proxy authentication request to realm example.com http://example.com ++[suffix] returns updated [eap] No EAP-Message, not doing EAP ++[eap] returns noop ++[files] returns noop ++[expiration] returns noop ++[logintime] returns noop ++[pap] returns noop Sending Access-Request of id 250 to 127.0.0.1 port 1822 User-Name = 2219...@example.com mailto:2219...@example.com Digest-Attributes = 0x0a0932323139303031 Digest-Attributes = 0x01106c696e6b2d726567696f6e2e7275 Digest-Attributes = 0x022254584452634531773045524b7368796f30684a70544f4f6a69424d386b32534a Digest-Attributes = 0x04147369703a6c696e6b2d726567696f6e2e7275 Digest-Attributes = 0x030a5245474953544552 Digest-Attributes = 0x050661757468 Digest-Attributes = 0x090a3030303030303031 Digest-Attributes = 0x080c32383034636535373032 Digest-Response = e79b47955c02401fe52d05f7956609aa Service-Type = Sip-Session Sip-Uri-User = 2219001 *User-Name = call-id=domcmqmnychbwlp@koffe-work* NAS-Identifier = kamserv.example.com http://kamserv.example.com NAS-Port = 5060 NAS-IP-Address = 127.0.0.1 Proxy-State = 0x313132 Proxying request 1 to home server 127.0.0.1 port 1822 As I understand, this second User-Name attribute has to be a call-id attribute. ___ 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 -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] problem unreferencing dialog in dialog module
Hello, just committed a safety check for this case. If anyone can give it some tests, then we can backport. I will analyze to see why it got in such case, but anyhow it is better and safer to detect bogus dereferences to dialogs and not crash. Thanks, Daniel On 3/3/11 11:34 AM, Timo Reimann wrote: Argh: On 03.03.2011 11:11, Timo Reimann wrote: What I can tell though is that the crash happens because too much dialog reference counter decrementing takes place. Although I have no clue why, ^ ...the crash happens, I believe the implementation of unref_dlg_unsafe() (a macro) could be somewhat more robust by not unlinking and destroying a dialog when the counter drops below zero. That is, instead of running the following block if ((_dlg)-ref=0) { \ unlink_unsafe_dlg( _d_entry, _dlg);\ LM_DBG(ref=0 for dialog %p\n,_dlg);\ destroy_dlg(_dlg);\ }\ for _dlg-ref= 0, I see no reason to change the compare operator to ==. I see no reason *not* to change compare operator to ==. That is, I want the block to execute iff the reference counter is found to be zero. --Timo ___ 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 -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] Calls are killed during kamailio restart
Hello, On 2/28/11 10:52 AM, Henning Westerholt wrote: On Thursday 24 February 2011, Efelin Novak wrote: I'd like to ask whether my situation is normal. During kamailio restart calls are dropped from mediaproxy. Those two programs are connected using kamailio.sock. Why RTP strem is dropped when SIP proxy is restarted? I would expect just undelivered BYE or something. Hi Efelin, i'm not an expert with mediaproxy, but does the kamailio hold some state that mediaproxy need to proper route the RTP packets? This would explain the behaviour that you observe, as this would probably lost during a restart. even if it needs details from SIP signaling, then it is a bug IMO that media proxy kills the calls. Kamailio recovers the states of active calls upon restart when dialog module is loaded, nothing is lost. I never used media proxy, but restarts of kamailio when using rtpproxy to relay the rtp does not impact at all the ongoing calls. Cheers, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] stats in kamailio
On 2/27/11 5:27 AM, Juha Heinanen wrote: Henning Westerholt writes: kamctl fifo get_statistics all will show you all available statistics, for a more simpler view try kamctl moni. The closest thing you'll find regards to the load are inuse transaction, or concurrent dialogs. tmx:inuse_transactions would be more useful if it would contain an average over some time (1-5 minutes or something like the routers have) rather than an instantaneous value. but last time when i looked, it was difficult to implement in k any kind of stat with average value. perhaps that has now changed with sip router? What I used, even in older versions, is to combine statistics with rtimer and htable. The statistics were just simple counters, holding integer value, incremented/decremented as wanted. There are some stats that just increment, practically counting different events. Here is what I do if I want to get like load stats - i.e., number of events in a specific period of time. For example number of 2xx transactions per minute: Load htable module and define a htable, say stats. In event_route[htable:mod-init] I set $sht(stats=2xx_transactions) = 0; Load rtimer module to execute a route block every minute. In that route block, do this kind of logic: $var(stats) = $stat(2xx_transactions); $var(diff) = $var(stats) - $sht(stats=2xx_transactions); $sht(stats=2xx_transactions) = $var(stats); - insert in db the value of $var(diff) along with the timestamp so you have the number of transactions answered with 2xx during the last minute. Then configure siremis to make a graph out of the db records You can have another rtimer route executed not that often that can delete records older than 1-2 days, so you don't fill up the database. Cheers, Daniel tmx:2xx_transactions -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] How to access additional xavp's
Hi Alex, it took me quite a while due to traveling, but now the issue should be fixed on git. Indeed there was an issue with the indexes when accessing the xavp as PV. Thanks, Daniel On 12/24/10 12:27 PM, Alex Hermann wrote: On Friday 24 December 2010, Daniel-Constantin Mierla wrote: On 12/21/10 2:44 PM, Alex Hermann wrote: I'm currently toying with xavp's and have some trouble accessing the values. I want to have access to the xavp that isn't the last added one. From the wiki page on http://sip-router.org/wiki/devel/xavp I got the impression that indices are supported, but that doesn't seem to work. In the following fragment i want access to the values 1A 1B, how to do that? $xavp(test=a) = 1A; $xavp(test[0]=b) = 1B; $xavp(test=a) = 2A; $xavp(test[0]=b) = 2B; Yes, indexes are supported, functionality should be: when you do not use an index, then you just stack a new value. When you use indexes, you overwrite. In this case you have to use indexes after a and be, like $xavp(test=a[0]) a.s.o. This also doesn't work, see below and the wiki page says the index should be on the avpname... Can you explain what the index on the avpname does and what the index on the subfield does, because i thought i understood, but it doesn't seem to work. What i want to accomplish is to set an xavp (test) multiple times with multiple subfields (a b) so that when i do an pv_unset($xavp(test)) i get the next set of subfields (to be used for a serial forking scenario later on). This already works. Now i want to have random access to the xavp, using an index to get to the right set of subfields. ie if i query $xavp(test[0]=a) i get 2A, $xavp(test[1]=b) should give 1B. If i get this working i'll post an interesting patch to sqlops soon :) I did some more testing and think there is a off-by-one bug somewhere: $xavp(test=a) = 1A; $xavp(test[0]=b) = 1B; $xavp(test=a) = 2A; $xavp(test[0]=b) = 2B; $xavp(test[1]=a) = 3A; $xavp(test[1]=b) = 3B; xlog(Index on subavp); xlog(0: $xavp(test)); xlog(0a: $xavp(test=a[0])); xlog(0b: $xavp(test=b[0])); xlog(1: $xavp(test)); xlog(1a: $xavp(test=a[1])); xlog(1b: $xavp(test=b[1])); xlog(2: $xavp(test)); xlog(2a: $xavp(test=a[2])); xlog(2b: $xavp(test=b[2])); xlog(Index on avpname); xlog(0: $xavp(test[0])); xlog(0a: $xavp(test[0]=a)); xlog(0b: $xavp(test[0]=b)); xlog(1: $xavp(test[1])); xlog(1a: $xavp(test[1]=a)); xlog(1b: $xavp(test[1]=b)); xlog(2: $xavp(test[2])); xlog(2a: $xavp(test[2]=a)); xlog(2b: $xavp(test[2]=b)); Results in: Dec 24 12:07:40 veyron wsproxy1[13032]: ERROR:script: Index on subavp Dec 24 12:07:40 veyron wsproxy1[13032]: ERROR:script: 0:xavp:0xb3a627c4 Dec 24 12:07:40 veyron wsproxy1[13032]: ERROR:script: 0a: 2A Dec 24 12:07:40 veyron wsproxy1[13032]: ERROR:script: 0b: 2B Dec 24 12:07:40 veyron wsproxy1[13032]: ERROR:script: 1:xavp:0xb3a627c4 Dec 24 12:07:40 veyron wsproxy1[13032]: ERROR:script: 1a:null Dec 24 12:07:40 veyron wsproxy1[13032]: ERROR:script: 1b:null Dec 24 12:07:40 veyron wsproxy1[13032]: ERROR:script: 2:xavp:0xb3a627c4 Dec 24 12:07:40 veyron wsproxy1[13032]: ERROR:script: 2a:null Dec 24 12:07:40 veyron wsproxy1[13032]: ERROR:script: 2b:null Dec 24 12:07:40 veyron wsproxy1[13032]: ERROR:script: Index on avpname Dec 24 12:07:40 veyron wsproxy1[13032]: ERROR:script: 0:xavp:0xb3a627c4 Dec 24 12:07:40 veyron wsproxy1[13032]: ERROR:script: 0a: 2A Dec 24 12:07:40 veyron wsproxy1[13032]: ERROR:script: 0b: 2B Dec 24 12:07:40 veyron wsproxy1[13032]: ERROR:script: 1:xavp:0xb3a6286c Dec 24 12:07:40 veyron wsproxy1[13032]: ERROR:script: 1a: 1A Dec 24 12:07:40 veyron wsproxy1[13032]: ERROR:script: 1b: 1B Dec 24 12:07:40 veyron wsproxy1[13032]: ERROR:script: 2:null Dec 24 12:07:40 veyron wsproxy1[13032]: ERROR:script: 2a:null Dec 24 12:07:40 veyron wsproxy1[13032]: ERROR:script: 2b:null Dec 24 12:07:40 veyron wsproxy1[13032]: INFO:core [xavp.c:470]: + XAVP list: 0xb3a62770 Dec 24 12:07:40 veyron wsproxy1[13032]: INFO:core [xavp.c:473]: *** XAVP name: test Dec 24 12:07:40 veyron wsproxy1[13032]: INFO:core [xavp.c:474]: XAVP id: 2063405720 Dec 24 12:07:40 veyron wsproxy1[13032]: INFO:core [xavp.c:475]: XAVP value type: 6 Dec 24 12:07:40 veyron wsproxy1[13032]: INFO:core [xavp.c:496]: XAVP value:xavp:0xb3a627c4 Dec 24 12:07:40 veyron wsproxy1[13032]: INFO:core [xavp.c:470]: + XAVP list: 0xb3a627c4 Dec 24 12:07:40 veyron wsproxy1[13032]: INFO:core [xavp.c:473]: *** XAVP name: b Dec 24 12:07:40 veyron wsproxy1[13032]: INFO:core [xavp.c:474]: XAVP id: 110 Dec 24 12:07:40 veyron wsproxy1[13032]: INFO:core [xavp.c:475]: XAVP value type: 2 Dec 24 12:07:40 veyron wsproxy1[13032]: INFO:core [xavp.c:484]: XAVP value: 2B Dec 24 12:07:40 veyron wsproxy1[13032
Re: [SR-Users] Newly acquired SIP fails authorization from softphone
Hello, On 3/5/11 2:16 AM, Larry Baumbach wrote: I am a newbie to the world of VIOP. I am attempting to set up an ATA with SIP. I created a SIP at account iptel.com and received an email confirmation stating We are reserving the following SIP address for you: sip:larry.baumb...@iptel.org. I tried to testing this address in Xlite but got messages saying: Account failed to enable. Account Iptel could not be enabled. Verify your user ID, password and authorization name. When I set up the SIP account in Xlite I used: UserID: larry.baumb...@iptel.org ( I also tried larry.baumbach sip:larry.baumb...@iptel.org) Domain: sip.iptel.org Password: my password Authorization name: (I left blank as I did not receive any) the auth username is the same as user id. Try that and see if works. Cheers, Daniel I can log into SERweb with the same UserID and Password and access my account. What am I doing wrong? Or is there some kind of wait time before my SIP address is activated? I have spent too much time trying to get this to work on my own. Thanks very much for any help you can provide. -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] Balancing Asterisk
Hello, On 3/7/11 12:51 AM, Andy Lippitt wrote: Hello all, I've read as many of the asterisk balancing threads as I can find. Either my situation is unusual or I simply haven't understood anything I've read. In short, I'm building an web/phone mashup which uses Asterisk's AGI to get its work done. My only users are on the PSTN connected to Asterisk through a SIP trunk provider. So presently, in and out through the same trunk, apps live on the single Asterisk box. My goal is scaling and failover. I don't have any need for cross talk or transfers between the asterisk instances, and the algo's in dispatcher seem fine. It seems to me that I should be setting the sip-router up a replacement for the existing peer in Asterisk. What leaves me scratching my head is how I then register the sip-router with the upstream provider. Alternatively, if I use the sip-router as an outboundproxy from asterisk (which seems like it's going to take some hacking to make this work in 1.4), doesn't this now mean I have multiple UAC's trying to register for the same name? Can someone set me on the right track? the recommended way is to get IP-based authentication and peering with your provider, in this way you don't need to authenticate calls out neither send registrations - kamailio/ser is a proxy at its core. The alternative is to use uac module, beware of its limitations regarding authentication: http://kamailio.org/docs/modules/stable/modules_k/uac.html In case you still need a b2bua-like interaction with the provider, see our related project - sip express media server (sems): http://iptel.org/sems - the sources are in the same git repository hosted at sip-router.org Cheers, Daniel Thanks, Andy Lippitt ___ 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 -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] #!define and #!subst problem
Hello, subst is replacing inside the sintring values, those being in between quotes, like: #subst /404/408/ sl_send_reply(404, Timeout) The define is replacing ID tokes, which are alpha-numeric tokens stand alone. In your case, you try to replace inside a composite value, and the ip address is not a stand alone token there - not sure if it supports, but you try putting the value in between quotes. If does not work, then you have to break down the listen value in listen with ip and then port separately. Cheers, Daniel On Tue, Mar 8, 2011 at 1:13 PM, Klaus Darilion klaus.mailingli...@pernau.at wrote: Hi! I tried #!subst /IPADDRESS_VIRTUAL/83.136.32.161/ listen=udp:IPADDRESS_VIRTUAL:5060 and #!define IPADDRESS_VIRTUAL 83.136.32.161 listen=udp:IPADDRESS_VIRTUAL:5060 Both do not work - am I doing something wrong or is this a known limitation with listen statements? Thanks Klaus ___ 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 -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] Question about LCR
Hello, I am not an extensive user of lcr module, but probably next_gw() adds a branch each time is called in failure route. If yes (when true you should see some parallel forking, depending o how the addresses are selected), you can mark the bad branches with a branch flag and drop them in a branch_route. while(next_gw()){ if($var(gw_flag) != $avp(i:712)){ xlog(L_INFO,Found an LCR destination which is different than current, routing. ($ci)); t_on_reply(1); t_on_failure(1); t_on_branch(1); t_relay(); exit; }else{ xlog(L_INFO,The next destination in LCR has the same AVP flag, skipping. ($ci)); setbflag(10); } } branch_route[1] { if(isbflagset(10)) drop; } However, if the destinations are selected like provider 1, provider 2, provider 1, provider 2, the condition you have in config file failure route is not good, since you check for change of the provider in each step, which happens in this case. Maybe you can use flags to check if a provider was used (or avps). Cheers, Daniel On Tue, Mar 8, 2011 at 11:35 PM, Geoffrey Mina geoffreym...@gmail.comwrote: Hello, I have a question about LCR which I have been unable to solve. I have 4 upstream carrier gateways owned by 2 carriers. Each carrier provides a primary and secondary gateway for load balancing purposes. On a 5XX error I am trying to send the same call to the other carrier. If both carriers reject the call with 5XX, I allow the response to go downstream to my asterisk server. The issue I am running into is that in a scenario where both my carriers respond with a 5XX, I end up presenting the same call to all 4 gateways. I would like to present the call to one gateway on each carrier and not try the same carriers second gateway for the same call. Here is what is happening now: ASTERISK -- INVITE -- KAMAILIO INVITE -- CARRIER A/GATEWAY 1 -- 5XX Error INVITE -- CARRIER A/GATEWAY 2 -- 5XX Error INVITE -- CARRIER B/GATEWAY 1 -- 5XX Error INVITE -- CARRIER B/GATEWAY 2 -- 5XX Error KAMAILIO -- 5XX Error -- ASTERISK OR any combination of the above... i.e. ASTERISK -- INVITE -- KAMAILIO INVITE -- CARRIER A/GATEWAY 1 -- 5XX Error INVITE -- CARRIER B/GATEWAY 2 -- 5XX Error INVITE -- CARRIER B/GATEWAY 1 -- 5XX Error INVITE -- CARRIER A/GATEWAY 2 -- 5XX Error KAMAILIO -- 5XX Error -- ASTERISK What I want to happen is: ASTERISK -- INVITE -- KAMAILIO INVITE -- CARRIER A/GATEWAY 1 or 2 -- 5XX Error INVITE -- CARRIER B/GATEWAY 1 or 2 -- 5XX Error KAMAILIO -- 5XX Error -- ASTERISK I tried dealing with the issue using some flags on the gateway, but i couldn't get the logic to work properly. Here is the path I was heading down, but my plan fell apart after some testing. CARRIER A has a gateway flag of 1 CARRIER B has a gateway flag of 2 failure_route[1]{ $var(gw_flag) = $avp(i:712); while(next_gw()){ if($var(gw_flag) != $avp(i:712)){ xlog(L_INFO,Found an LCR destination which is different than current, routing. ($ci)); t_on_reply(1); t_on_failure(1); t_relay(); exit; }else{ xlog(L_INFO,The next destination in LCR has the same AVP flag, skipping. ($ci)); } } # let the reply go upstram - it is the default action xlog(L_ERR, No Next Gateway - M=$rm RURI=$ru F=$fu T=$tu IP=$si ID=$ci\n); exit; } Any help would be greatly appreciated. Thanks, Geoff ___ 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 -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] acc failed_transaction_flag and t_newtran()
Hi Juha, great that you needed it so it got spotted, practically we had support for sync'ing flags back to transaction from message in 1.x, but seems it got lost during the integration. I just reintroduced the t_flush_flags() in the tmx module. Being a fix considering the lost of the old feature, it can be backported once you confirm it works for you (unfortunately I am not able to test right now). Cheers, Daniel On Sat, Mar 12, 2011 at 7:46 AM, Juha Heinanen j...@tutpro.com wrote: Juha Heinanen writes: is there any way to unset the accounting flags after calling t_newtran()? for example, i would not like to account invites that result to 407 proxy authentication required. just to clarify, i added statement resetflag(ACC_FAILED_FLAG); just before proxy_challenge() call, but it did not have any effect. i guess the reason is that transaction was already created. if failed transaction reporting cannot be undone after transaction has been created, then another possibility (although not as attractive) would be to add a filter param to accounting module that would list which response codes =300 script writer is not interested in. -- juha ___ 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 -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] acc failed_transaction_flag and t_newtran()
Hello Juha, On Sat, Mar 12, 2011 at 8:14 PM, Juha Heinanen j...@tutpro.com wrote: Daniel-Constantin Mierla writes: I just reintroduced the t_flush_flags() in the tmx module. Being a fix considering the lost of the old feature, it can be backported once you confirm it works for you (unfortunately I am not able to test right now). daniel, thanks for the new function. now 407 does not anymore get accounted with this piece of script: resetflag(ACC_FAILED_FLAG); t_flush_flags(); proxy_challenge(...); so the function seem to work ok and could be backported. ok, thanks for testing. while at this, it may still be a good idea to have a failure code filter param in acc module, because, people may not be interested, for example, in 404 not found calls to be accounted. It is fine for me - anyone that has time to do it just go ahead and let it be controlled by module parameter. Cheers, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] OPENSER MIB
Hello, On 3/14/11 9:42 AM, Stefan Tiedje wrote: Hi, In the Kamailio OPENSER-MIB there is the counter openserTotalNumFailedDialogSetups. This is a Counter32. The description is: The total number of calls that failed with an error. The following codes define a failed call: *Question:* * I'm looking for the corresponding counter to openserTotalNumFailedDialogSetups who counts successful Dialog setups of Counter32 type. Does it exist? * If not, does it exist a work around? * Where in the code can the new suggested counter be added? * Something else the dialog module counts the number of processed dialogs, see: http://kamailio.org/docs/modules/stable/modules_k/dialog.html#id2966360 There is no counter currently inside dialog module exporting exactly the number of successfully setup dialogs, it should not be hard to do it, though. Using the above and the number of failed and expired dialogs, you can actually get the number of successful dialogs. Dialog module being the one that tracks SIP dialogs, therefore being able to count them, now I don't know if snmpstats module exports all the counters from dialog module. I setup snmpstats just few weeks ago and works perfect on Ubuntu/Debian servers, but I had no need to check dialog module counters. Note that you can get the list of all internal statistics via kamctl: - kamctl fifo get_statistics all Or via XMLRPC if you need them remotely in another application. Another option is to define your statistics with statistics module. Knowing that in SIP a successful call dialog means 200ok reply to an INVITE transaction, you can count it in the onreply_route[abc] that you arm for relayed transactions with t_on_reply(abc). Hope these help you, Daniel Suggestion for the new counter is a name like: openserTotalNumSucceededDialogSetups. It has a counter32. Description: The total number of calls that succeeded I know that there are the counters openserCurNumDialogs, openserCurNumDialogsInProgress and openserCurNumDialogsInSetup but these are of Gauge type who only reflects the current situation. These Gauge counters can't be used together with a Counter32 counter. That don't mix. The calculation done for the counter openserCurNumDialogsInProgress should be used where every new dialog setup is added to the new suggested counter. A counter of 32 should cover a great deal of connections. These counters are usually read, if used, every 15 minutes or 1 hour. *Rationale:* The reason for the new counter is that a calculation between succeeded and failed dialog setups can be done and be used for SLA agreements. Without this, its hard to make any customer versus provider agreements. /Stefan PS. Ask if anything is unclear and I need an answer rapidly. ___ 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 -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] decimal fraction problem
Hello, are you using kamailio 3.1.x? If not, you have to upgrade, the $branch(...) variable was updated to be writable starting with this version. I played last week with it in a need of combining serial forking with parallel forking and all is ok with assigning values to $branch(...). Cheers, Daniel On 3/14/11 5:25 AM, 侯旭光 wrote: sorry to bother again $(branch(q)[-1]) = $var(q); this script line doesn't work and the pv $branch() aren't writable,just readable . index -1 is not accessable either. if append_branch() function doesn't take the q value parameter,the $branch(q) just return NULL (which I think is the default value Q_UNSPECFIED=-1) I find a function set_ruri_q() in dset.c but I don't know how to call it in the configure file. 2011/2/23 Daniel-Constantin Mierla mico...@gmail.com: Hello, On 2/21/11 10:28 AM, 侯旭光 wrote: Hello I need to add q value while using function append_branch(),but the function only takes decimal fraction as the parameter. What if I want to use pv to add q value? The $var and $avp just have string and integer type. Thanks a lot! do: km_append_branch($var(branchuri)); $(branch(q)[-1]) = $var(q); $var(q) has to hold an integer value that represents the decimal fraction value multiplied with 100 (so if q should be 0.5, then $var(q) = 50). Cheers, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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 -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] LCR Routes and memory allocations
Hello, popping in to add some clarifications/hints regarding some statements in this thread... Loading of LCR rules from database is done through private memory, but the records are loaded in chunks. So you should be fine with 4MB of memory. If it is not enough for startup/reload time, just lower the valuu of fetch_rows parameter (usually present in other modules that load from database, as well). http://kamailio.org/docs/modules/stable/modules/lcr.html#id2502056 Also note that private memory is sued temporary to load the rules, just to transit from database to shared memory, then no private memory is used for lcr records as Juha said. Regarding the shared memory, looking at the source code will help to see the overhead per lcr record and then just add the size of the data loaded from memory (some such as domain names are variable size). However, there is a simple way to estimate the need of shared memory by loading for example 1000 records and then 2000 records. Using 'kamctl fifo get_statistics all' you can see the used shared memory size in the both cases, make the difference and then estimate the size per record. As I said, that is practically to approximate average size per record. If you reload the rules at runtime, you may need 2x shared memory size for lcr rules - Juha can confirm that the module is (re-)loading rules in a separate memory structure and then swaps with the active one, and frees the old one afterwards, since I am not really using much this module. Besides the lcr records, you need to have extra shared memory for transaction processing. Cheers, Daniel On 3/13/11 9:13 PM, Juha Heinanen wrote: Graham Wooden writes: I already had the -m 512 in my init file, so it appears I am ok there. I went ahead and recompiled with PKG_MEM_POOL_SIZE to 16MB and I'll see how it goes. graham, lcr module (at least the later versions) does not use any pkg memory. it keeps all gws and rules in shm memory. you can check with kamctl command how much shm memory you have left/used/etc. -- juha ___ 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 -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] Call subscriber online
Hello, shouldn't the call go to location service before relaying to subscriber B? Is B at a fix address an port and that is local host port 5060? Are you doing all in your computer for testing purposes, because otherwise an application bound to localhost (like could be the softphone B) cannot really communicate with the inter/intra-network? Cheers, Daniel On 3/11/11 4:50 PM, Stefano Larosa wrote: Hi, I'm new on Kamailio 3.0 This is the scenario I would like to build: 1 Subscriber A - 2 kamailio - 3 asterisk - 4 Kamailio - 5 Subscriber B Everything is working fine until the last step This is the code that manage the call from asterisk to kamailio /if(is_method(INVITE) (src_ip==80.169.xx.xx) )/ /{/ / route(TOPROXYUSER);/ /}/ And this is the code that should end the call the the subscriber route[TOPROXYUSER] { xlog(L_NOTICE, $mi route[$rm][0] $fu - $ru START PROCESSING MESSAGE\n); rewritehostport(127.0.0.1:5060); if (is_method(BYE|CANCEL)) { route(FAIL_ONE); } else if (is_method(INVITE)){ route(RELAY); }; exit; } Thank you, Stivu. ___ 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 -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] Register a CISCO IP phone
Hello, Hello, assuming is no NAT ALG as Dani Popa asked previously and there was no answer so far, here are some questions/hints that may help... On 3/11/11 12:15 PM, Dani Popa wrote: CISCO SPA 303 IP phone is under NAT? if yes, what router do you use ? Dani On 03/10/11 21:32, Pang, Gary (Liguang) wrote: Dear Sir, I have a difficulty to register a CISCO SPA 303 IP phone. I can register a Soft phone to the SER server by setting the Hold IP address Did you mean here Host IP address instead of Hold IP address? , Proxy, account number.. But it is not working with the CISCO phone. Can you advice? Many cisco phones are dual protocol, is yours set for SIP? I have no spa 303 but you should get some web interface where to enter the sip server (registrar or proxy), username and password of you sip account that it should be enough. Cheers, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] pseudo variables available in on_reply route
Hello, On 3/11/11 3:03 AM, Asgaroth wrote: Hi All, I have a requirement to perform some processing based on the source and destination addresses on a message in on_reply route. I can get source ip address using $si pseudo variable, but I cant seem to access the destination ($dd). Is there any way I can access destination ip/domain of message in on_reply route? an easy (classic way) to do it is to store the the source IP of request (the IP address of sender) before t_relay() in an avp: $avp(reqsrcip) = $si; The in onreply_route you have access to source IP of reply which is the IP address of the destination for request. Assuming you are using kamailio 3.x, then all avps you set for request are available in the onreply_route and you can do what ever operations you need now with $avp(reqsrcip) and $si. Cheers, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] ACK not sent and rr-enforced
Hello, I will look over it very soon. As a hint for the future, if you catch me traveling, rar files won't work for me, use tgz or zip as they are easy to expand very easy even on web mail clients. If the trace is not big, plain text is faster or eventually use some pastebin sites out there. Cheers, Daniel On 3/10/11 1:49 PM, Dominguez Jover, Ricardo wrote: Hello Daniel, here it is. Thanks Ricardo De: Daniel-Constantin Mierla [mailto:mico...@gmail.com] Enviado el: jueves, 10 de marzo de 2011 12:49 Para: Dominguez Jover, Ricardo CC: sr-users@lists.sip-router.org Asunto: Re: [SR-Users] ACK not sent and rr-enforced Hello, can you post the ngrep trace of such call (fron incoming invite, to the bye, taken on your server)? That will help to see what could be mismatching there. Cheers, Daniel On Thu, Mar 10, 2011 at 11:06 AM, Dominguez Jover, Ricardodjo...@umh.es wrote: Hi again, I'm still working in this issue. I've noticed that iptel proxy is writing in the ACK message the following: ACK sip:username@myproxyIP:5060;. - ACK is not sent to the client. tcheck_trans fails. If a force the transfer - t_relay do nothing while sip2sip and VoIP-Talk are writing: ACK sip:username@userprivateIP:5060; - ACK is sent to the client In both cases, contact URI sent in the 200 OK message by my proxy is the private IP address of the client sending the 200 OK, so I don't know why IPtel doesn't use it in the ACK. I find a lot of information about lost ACKs in posts, but not this particular issue. Could anyone give me some related information that can help me to solve this issue? Best regards, Ricardo Dominguez De: sr-users-boun...@lists.sip-router.org [mailto:sr-users-boun...@lists.sip-router.org] En nombre de Dominguez Jover, Ricardo Enviado el: lunes, 07 de marzo de 2011 20:03 Para: sr-users@lists.sip-router.org Asunto: [SR-Users] ACK not sent and rr-enforced Hi everybody. I am using Kamailio 3.1 and RTP proxy for internet calls. I'm using external test accounts to check if the calls are established and the media flow is ok. When I use a sip2sip.info or VoIP Talk accounts, then all is working fine between my internal and these external accounts. But when I use a iptel.org account and this account calls to an internal account (registered with kamailio), then callee sends the 200 OK to the SIP proxy and the SIP proxy to iptel. IPtel.org proxy sends the ACK to my proxy with this lines at the end of the packet: P-hint: rr-enforced\r\n P-hint: rr-enforced\r\n And my SIP proxy never resends the ACK to the callee, so the callee resends OK 200 periodically and after 32 seconds sends a BYE message and the call is finished. I've been reading posts about missing ACKs but I can't find the answer to my problem, that it seems like t_check_trans doesn´t recognize the ACK as related to a transaction. But this is only with IPTEL accounts, my proxy SIP is working with other SIP providers, so I don't know if forcing relay of every ACK packet is a good idea. Any help would be appreciated. Thanks, Ricardo ___ 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 -- Daniel-Constantin Mierla http://www.asipto.com ___ 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 -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] OPENSER MIB
Hello Stefan, On 3/14/11 11:03 AM, Stefan Tiedje wrote: Thanks for the answer. Maybe I have some older versions of the OPENSER-MIB and the other related MIB's since I could not find the counter you pointed at. I'm using a MIB browser for reading the MIB's. Is the suggested counter expired dialogs added in a specific release of Kamailio? Which? We use Kamailio 3.0.2. I used Kamailio and recommend using it sine it has the latest commits for stability. However, what I wrote before is pretty much not related to the version. There is a counter that tracks the processed dialogs, but seems it is not exported by default through snmpstats module. The statistics counter is named processed_dialogs, implemented by dialog module. You can dump all internal statistics through kamctl or via xmlrpc command, but probably to export it through snmpstats you may need to extend the mibs and the code of the module. I just grepped the sources of snmpstats module to see what dialog statistics it is exporting: $ grep -n _dialogs modules_k/snmpstats/* | grep get_statistic modules_k/snmpstats/alarm_checks.c:83:num_dialogs = get_statistic(active_dialogs); modules_k/snmpstats/snmpObjects.c:404:int result = get_statistic(active_dialogs); modules_k/snmpstats/snmpObjects.c:424: get_statistic(active_dialogs) - modules_k/snmpstats/snmpObjects.c:425: get_statistic(early_dialogs); modules_k/snmpstats/snmpObjects.c:443:int result = get_statistic(early_dialogs); modules_k/snmpstats/snmpObjects.c:459:int result = get_statistic(failed_dialogs); modules_k/snmpstats/snmpObjects.c:508:int num_dialogs = get_statistic(active_dialogs); Perhaps when the snmpstats was developed the dialog module didn't export the statistics counter of processed_dialogs and then it was not updated. Now, what I tried to say is that if the processed_dialogs counter is not available through snmpstats (and it is not now after grepping the sources) you can get its value from another application through kamctl get_statistics all or XMLRPC command for all of the existing kamailio releases. Upcoming one we will look to implement the export through snmpstats as well. If you have time to do it and send us a patch, we will gladly commit it to source tree in our GIT repository. Cheers, Daniel Do you have the MIB name for the expired dialogs counter. I will look for that in my version of OPENSER MIBS. Important, do you have a link to where MIB files can be downloaded for Kamailio 3.0.2? Below follows an excerp from one of the MIB's. Is it old, I don't know? -- *** -- OPENSER-MIB: OPENSER MIB -- -- Date of Creation: Januay 2006 -- -- This MIB provides information related to the OpenSER SIP Router. -- -- Copyright (c) The Internet Society (2006) -- Ammendments (c) Soma Networks, Inc. (2006) -- -- All rights reserved. -- * /Stefan *From:* Daniel-Constantin Mierla [mailto:mico...@gmail.com] *Sent:* den 14 mars 2011 10:16 *To:* Stefan Tiedje *Cc:* sr-users@lists.sip-router.org *Subject:* Re: [SR-Users] OPENSER MIB Hello, On 3/14/11 9:42 AM, Stefan Tiedje wrote: Hi, In the Kamailio OPENSER-MIB there is the counter openserTotalNumFailedDialogSetups. This is a Counter32. The description is: The total number of calls that failed with an error. The following codes define a failed call: *Question:* * I'm looking for the corresponding counter to openserTotalNumFailedDialogSetups who counts successful Dialog setups of Counter32 type. Does it exist? * If not, does it exist a work around? * Where in the code can the new suggested counter be added? * Something else the dialog module counts the number of processed dialogs, see: http://kamailio.org/docs/modules/stable/modules_k/dialog.html#id2966360 There is no counter currently inside dialog module exporting exactly the number of successfully setup dialogs, it should not be hard to do it, though. Using the above and the number of failed and expired dialogs, you can actually get the number of successful dialogs. Dialog module being the one that tracks SIP dialogs, therefore being able to count them, now I don't know if snmpstats module exports all the counters from dialog module. I setup snmpstats just few weeks ago and works perfect on Ubuntu/Debian servers, but I had no need to check dialog module counters. Note that you can get the list of all internal statistics via kamctl: - kamctl fifo get_statistics all Or via XMLRPC if you need them remotely in another application. Another option is to define your statistics with statistics module. Knowing that in SIP a successful call dialog means 200ok reply to an INVITE transaction, you can count it in the onreply_route[abc] that you arm
Re: [SR-Users] OPENSER MIB
On 3/14/11 12:33 PM, Daniel-Constantin Mierla wrote: Hello Stefan, On 3/14/11 11:03 AM, Stefan Tiedje wrote: Thanks for the answer. Maybe I have some older versions of the OPENSER-MIB and the other related MIB's since I could not find the counter you pointed at. I'm using a MIB browser for reading the MIB's. Is the suggested counter expired dialogs added in a specific release of Kamailio? Which? We use Kamailio 3.0.2. I used Kamailio and recommend using it sine it has the latest commits for stability. ... ^^^ ... obviously this was incomplete phrase, it meant to be: I used Kamailio 3.1.2 and recommend using it since it has the latest commits for stability. I can add also that I got more familiar in configuring it with snmpstats on debian/ubuntu, so it would be easier for me to give hints as well as add new features since it is the same as devel version. Cheers, Daniel However, what I wrote before is pretty much not related to the version. There is a counter that tracks the processed dialogs, but seems it is not exported by default through snmpstats module. The statistics counter is named processed_dialogs, implemented by dialog module. You can dump all internal statistics through kamctl or via xmlrpc command, but probably to export it through snmpstats you may need to extend the mibs and the code of the module. I just grepped the sources of snmpstats module to see what dialog statistics it is exporting: $ grep -n _dialogs modules_k/snmpstats/* | grep get_statistic modules_k/snmpstats/alarm_checks.c:83:num_dialogs = get_statistic(active_dialogs); modules_k/snmpstats/snmpObjects.c:404:int result = get_statistic(active_dialogs); modules_k/snmpstats/snmpObjects.c:424: get_statistic(active_dialogs) - modules_k/snmpstats/snmpObjects.c:425: get_statistic(early_dialogs); modules_k/snmpstats/snmpObjects.c:443:int result = get_statistic(early_dialogs); modules_k/snmpstats/snmpObjects.c:459:int result = get_statistic(failed_dialogs); modules_k/snmpstats/snmpObjects.c:508:int num_dialogs = get_statistic(active_dialogs); Perhaps when the snmpstats was developed the dialog module didn't export the statistics counter of processed_dialogs and then it was not updated. Now, what I tried to say is that if the processed_dialogs counter is not available through snmpstats (and it is not now after grepping the sources) you can get its value from another application through kamctl get_statistics all or XMLRPC command for all of the existing kamailio releases. Upcoming one we will look to implement the export through snmpstats as well. If you have time to do it and send us a patch, we will gladly commit it to source tree in our GIT repository. Cheers, Daniel Do you have the MIB name for the expired dialogs counter. I will look for that in my version of OPENSER MIBS. Important, do you have a link to where MIB files can be downloaded for Kamailio 3.0.2? Below follows an excerp from one of the MIB's. Is it old, I don't know? -- *** -- OPENSER-MIB: OPENSER MIB -- -- Date of Creation: Januay 2006 -- -- This MIB provides information related to the OpenSER SIP Router. -- -- Copyright (c) The Internet Society (2006) -- Ammendments (c) Soma Networks, Inc. (2006) -- -- All rights reserved. -- * /Stefan *From:* Daniel-Constantin Mierla [mailto:mico...@gmail.com] *Sent:* den 14 mars 2011 10:16 *To:* Stefan Tiedje *Cc:* sr-users@lists.sip-router.org *Subject:* Re: [SR-Users] OPENSER MIB Hello, On 3/14/11 9:42 AM, Stefan Tiedje wrote: Hi, In the Kamailio OPENSER-MIB there is the counter openserTotalNumFailedDialogSetups. This is a Counter32. The description is: The total number of calls that failed with an error. The following codes define a failed call: *Question:* * I'm looking for the corresponding counter to openserTotalNumFailedDialogSetups who counts successful Dialog setups of Counter32 type. Does it exist? * If not, does it exist a work around? * Where in the code can the new suggested counter be added? * Something else the dialog module counts the number of processed dialogs, see: http://kamailio.org/docs/modules/stable/modules_k/dialog.html#id2966360 There is no counter currently inside dialog module exporting exactly the number of successfully setup dialogs, it should not be hard to do it, though. Using the above and the number of failed and expired dialogs, you can actually get the number of successful dialogs. Dialog module being the one that tracks SIP dialogs, therefore being able to count them, now I don't know if snmpstats module exports all the counters from dialog module. I setup snmpstats just few weeks ago and works perfect on Ubuntu/Debian servers, but I
Re: [SR-Users] decimal fraction problem
Hello, cc-ing to the mailing list is very important because even it is an email to show the previous answer was good, that will help other people with similar problem that search on web and read the mailing list archive to know the proposed solution worked and they can use it without asking again on mailing list if it was ok or not. Thanks, Daniel On 3/14/11 12:07 PM, 侯旭光 wrote: got it thanks cheers 在 2011年3月14日 下午5:22,Daniel-Constantin Mierla mico...@gmail.com 写道: Hello, are you using kamailio 3.1.x? If not, you have to upgrade, the $branch(...) variable was updated to be writable starting with this version. I played last week with it in a need of combining serial forking with parallel forking and all is ok with assigning values to $branch(...). Cheers, Daniel On 3/14/11 5:25 AM, 侯旭光 wrote: sorry to bother again $(branch(q)[-1]) = $var(q); this script line doesn't work and the pv $branch() aren't writable,just readable . index -1 is not accessable either. if append_branch() function doesn't take the q value parameter,the $branch(q) just return NULL (which I think is the default value Q_UNSPECFIED=-1) I find a function set_ruri_q() in dset.c but I don't know how to call it in the configure file. 2011/2/23 Daniel-Constantin Mierla mico...@gmail.com: Hello, On 2/21/11 10:28 AM, 侯旭光 wrote: Hello I need to add q value while using function append_branch(),but the function only takes decimal fraction as the parameter. What if I want to use pv to add q value? The $var and $avp just have string and integer type. Thanks a lot! do: km_append_branch($var(branchuri)); $(branch(q)[-1]) = $var(q); $var(q) has to hold an integer value that represents the decimal fraction value multiplied with 100 (so if q should be 0.5, then $var(q) = 50). Cheers, Daniel -- Daniel-Constantin Mierla http://www.asipto.com ___ 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 -- Daniel-Constantin Mierla http://www.asipto.com -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] $rU isn't used in t_relay() in failure_route
Hello, for the question of this thread it is important to know the version of kamailio used. In older versions, append_branch was called on purpose upon changes in failure route, in latest one, changes to routing URIs will be detected and a new branch is created by t_relay(). I do not know if latest lcr does internally append_branch(), but if it does and you change afterwards r-uri, then you will get two branches. On 3/18/11 7:00 PM, Klaus Darilion wrote: Am 16.03.2011 21:09, schrieb Steven Wheeler: $rd=$dd; $rp=$dp; $du=$ru; This one I do not understand. Also I do not see the code where you change $dU? $dX - is the pseudo-variable for internal destination uri field (or outbound proxy address) -- this will not be shown in the sip message at all. Since user part of a SIP URI has no relevance in the IP routing, $dU (which you may think it is the user part of dst uri) is not exported as PV. Cheers, Daniel Anyway, it seems that 2 branches are added: maybe one by lcr module internally via next_gw and one manually? You can try to change $dU before calling next_gw and omit the append_branch() call. regards klaus ___ 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 -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] binary name
Hello, ser and sip-router flavours are completely the same, just different names for binaries and tools. Historically, being the initial project, ser stays the default flavour kamailio is different, installing what was traditionally provided by kamailio (openser), one being the database structure specific for kamailio. Then just few things are enabled by default: kamailio's internal statistics and tm module extensions used by seas module. Then, no matter which flavour you select, all modules are installed, so you can combine them, you need to be sure you create the database table structure specific for what modules you use. Cheers, Daniel On 3/23/11 2:57 AM, Claudio Furrer wrote: Hi Sascha, Thanks your answer.. I'm coming from ser flavour, and need to upgrade to 3.x, then my doubt is specifically related with ser/sip-router. Now I've already have ser binaries (ser, sercmd, etc) and am i asking if new binaries should be named as ser* or siprouter* based on the flavour set. Moreover, what if it's a new installation and need only common modules and a few of modules_s.. Then which flavour is recommended (ser or sip-router) and which name should the main binaries have. Again, thank you. Claudio On Tue, 22 Mar 2011, Sascha Daniels wrote: Hi. If you use FLAVOUR=kamailio you will get kamailio, kamctl and kamdbctl as binary. Regards Sascha Am 22.03.2011 19:42, schrieb Claudio Furrer: Hello, What is (or should be) the binary main name when using FLAVOUR=ser, FLAVOUR=sip-router or no FLAVOUR specified? I'm getting ser as the name whatever I set to FLAVOUR var at compile time. Is it right? (Makefiles.defs says ser in these cases but not sure the intention of the sip-router project). I need to know the correct one to make an ebuild package for Gentoo. Thank you for your answers.. -- AMOOMA GmbH - Bachstr. 124 - 56566 Neuwied -- http://www.amooma.de Geschäftsführer: Stefan Wintermeyer, Handelsregister Montabaur B14998 Bücher: http://das-asterisk-buch.de - http://ruby-auf-schienen.de ___ 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 -- Daniel-Constantin Mierla http://www.asipto.com ___ 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] event_route and acc_db_request().
Hello, On 3/17/11 5:45 PM, Alexandre Abreu wrote: Hello. Why acc_db_request() doesn't work on event_route? I will take a look. Is the BYE generated by dialog timeout or you trigger it by kamctl/xmlrpc? Cheers, Daniel Mar 17 13:15:44 devel kamailio[25209]: INFO: script: Routing locally generated BYE to sip:200@192.168.200.114:9297 Mar 17 13:15:44 devel kamailio[25209]: ERROR: core [db.c:421]: invalid parameter value Mar 17 13:15:44 devel kamailio[25209]: ERROR: acc [acc.c:391]: error in use_table Mar 17 13:15:44 devel kamailio[25209]: INFO: script: Routing locally generated BYE to sip:201@192.168.200.149:7335 Mar 17 13:15:44 devel kamailio[25209]: ERROR: core [db.c:421]: invalid parameter value Mar 17 13:15:44 devel kamailio[25209]: ERROR: acc [acc.c:391]: error in use_table event_route[tm:local-request] { xlog(L_INFO, Routing locally generated $rm to $ru\n); if (is_method(BYE)) acc_db_request(rtp-timeout, acc); } If I change acc_db_request() to acc_log_request() everything works fine, but this BYE should go to database for accounting purposes. I am using GIT version from Kamailio branch 3.1. From 2008 there is a thread that also demonstrate this problem: http://www.mail-archive.com/users@lists.kamailio.org/msg01411.html Unfortunately, in the archives, there's no solution for that. Regards, Alexandre ___ 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 -- Daniel-Constantin Mierla http://www.asipto.com ___ 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