[SR-Users] Not responding to OPTIONS if existing tcp connection
Hi all version 5.7.6 Debian 12 I'm having issues with a kamailio server not sending 200 to some OPTIONS requests. It does send 200 to some subscribers but not 100% of the time to 100% of subs. I have enabled debug=3 in that server and this is what I found: If the log says that it found existing tcp connection and it's reusing it I can't see the 200ok in a sngrep capture. Example: [core/receive.c:126]: sip_check_fline(): first line indicates a SIP reply [core/tcp_main.c:1722]: _tcpconn_find(): found connection by id: 2 [core/tcp_main.c:2614]: tcpconn_send_put(): send from reader (360359 (18)), reusing fd [core/tcp_main.c:2845]: tcpconn_do_send(): sending... [core/tcp_main.c:2881]: tcpconn_do_send(): after real write: c= 0x7fb0faa893d8 n=384 fd=14 [core/tcp_main.c:2882]: tcpconn_do_send(): buf=#012SIP/2.0 200 Keepalive#015#012Via: SIP/2.0/TCP 10.35.190.105:5060;branch=z9hG4bK15ebf764;rport=55894;received=1.1.1.186#015#012From: "Unknown" ;tag=as5311c3a7#015#012To: ;tag=054524a74bcccf444a0f08f67c5b7657.d07b5401#015#012Call-ID: 15dcd38c46f915576ded132a11d8ff4c@10.35.190.105:5060#015#012CSeq: 102 OPTIONS#015#012Server: aaa SBC#015#012Content-Length: 0#015#012#015#012 [core/receive.c:531]: receive_msg(): request-route executed in: 302 usec On the other side, if kamailio doesn't find an existing tcp connection (at least nothing in the logs about that) I can see the 200 ok in sngrep. Example: [core/receive.c:126]: sip_check_fline(): first line indicates a SIP reply [core/receive.c:531]: receive_msg(): request-route executed in: 295 usec All subs use tcp. And the kamailio.cfg is very simple regarding OPTIONS: Sanity, check maxfwd and sl_send_reply(200). Any hints? cheers, Jon -- PekePBX, the multitenant PBX solution https://pekepbx.com pgp2BCY_mGrkN.pgp Description: Firma digital OpenPGP __ Kamailio - Users Mailing List - Non Commercial Discussions To unsubscribe send an email to sr-users-le...@lists.kamailio.org Important: keep the mailing list in the recipients, do not reply only to the sender! Edit mailing list options or unsubscribe:
[SR-Users] Re: exec concurrency
El Wed, 19 Jun 2024 11:54:05 -0500 Brett Nemeroff escribió: > What you should expect using this method is blocking while the exec runs > which could run you out of child processes while they complete. I'd also > expect to see an "unusual amount of CPU activity" which will be the result > of the forked shells being created and destroyed. > > All of that being said, yes it works. It's architecturally overly simple > and very inefficient. If your load is tiny, it might be ok. Anything > moderate like Henning and others have said, will use an inordinate amount > of cpu. I would not personally risk it. > > Thank you Brett, Henning and Alex Sadly the load won't be tiny and cannot risk it. For now I'll deploy a local nginx and fpm to run the scripts, which are in php, and will use the http_async method. Sadly we have to "http all the things" nowadays. Let's see if I'm able to write down all the logic tomorrow and do some testing. cheers, Jon -- PekePBX, the multitenant PBX solution https://pekepbx.com pgpnm4ga4gJcA.pgp Description: Firma digital OpenPGP __ Kamailio - Users Mailing List - Non Commercial Discussions To unsubscribe send an email to sr-users-le...@lists.kamailio.org Important: keep the mailing list in the recipients, do not reply only to the sender! Edit mailing list options or unsubscribe:
[SR-Users] Re: replies using the wrong protocol
El Wed, 19 Jun 2024 19:54:26 - "sarah.martin--- via sr-users" escribió: > I am extremely new at this, but trying to set up TLS with a carrier. TLS > connection is good, Invite goes out, we get the 100 and the 200, but > subsequent messages (ACK and BYE) are being sent with UDP and I cannot figure > out how to get them to maintain the TLS transport. Any suggestions? I think > this is the section I'm looking for. > What's your contact look like? -- PekePBX, the multitenant PBX solution https://pekepbx.com pgpCXco3udTI4.pgp Description: Firma digital OpenPGP __ Kamailio - Users Mailing List - Non Commercial Discussions To unsubscribe send an email to sr-users-le...@lists.kamailio.org Important: keep the mailing list in the recipients, do not reply only to the sender! Edit mailing list options or unsubscribe:
[SR-Users] Re: exec concurrency
El Tue, 18 Jun 2024 13:54:41 -0500 Brett Nemeroff escribió: > Just want to add that exec is heavy and slow. I would not recommend it. > > Is there a reason you want to do this over http-ifying your script and > using async? > > Not really. The scripts are provided. Maybe I'm against "http all the things" which seems to be what everyone does nowadays. Why would http client be lighter than executing a script? That would be a design problem, right? -- PekePBX, the multitenant PBX solution https://pekepbx.com pgpkkja2jDHjG.pgp Description: Firma digital OpenPGP __ Kamailio - Users Mailing List - Non Commercial Discussions To unsubscribe send an email to sr-users-le...@lists.kamailio.org Important: keep the mailing list in the recipients, do not reply only to the sender! Edit mailing list options or unsubscribe:
[SR-Users] Re: exec concurrency
El Tue, 18 Jun 2024 13:56:06 -0400 Alex Balashov via sr-users escribió: > Yes, there is. You're best off building an rtimer+mqueue pipeline (or > streamlined 'async' equivalent) and running your exec() calls in the > asynchronous route. You can then t_continue() the transaction inside there. > Thank you Alex I haven't clear the process you're suggesting but I have a path to check. -- PekePBX, the multitenant PBX solution https://pekepbx.com pgp5b3N7oQB6b.pgp Description: Firma digital OpenPGP __ Kamailio - Users Mailing List - Non Commercial Discussions To unsubscribe send an email to sr-users-le...@lists.kamailio.org Important: keep the mailing list in the recipients, do not reply only to the sender! Edit mailing list options or unsubscribe:
[SR-Users] exec concurrency
Hi all I've been working with async http client and async db queries in the past but now I have to execute scripts and store the return values in avps. Since I have no experience with that, I wonder how to achieve concurrency with that scenario. Is there a way to exec async or suspend until the exec has finished and resume later? cheers, Jon -- PekePBX, the multitenant PBX solution https://pekepbx.com pgpZNQxxsiAnN.pgp Description: Firma digital OpenPGP __ Kamailio - Users Mailing List - Non Commercial Discussions To unsubscribe send an email to sr-users-le...@lists.kamailio.org Important: keep the mailing list in the recipients, do not reply only to the sender! Edit mailing list options or unsubscribe:
[SR-Users] Re: Filtering codes in db acc
El Thu, 6 Jun 2024 17:48:43 + Henning Westerholt escribió: > Hello, > > just to double check, you are also setting this two flags then in processing > the INVITE, right? > Yes. I get the failed rows in the database tables "missed_calls" I just want in a invite-407-invite-486 call to have a single entry with the 486 and do not have the 407 one. route[TO_PSTN] { xlog("L_NOTICE", "Call from PBX. Sending to PSTN - R=$ru\n"); $fsn="main"; if (is_method("INVITE")){ $avp(acc_company)=$hdr(P-PEKE-SRCCOMPANY); $avp(acc_exten)=$hdr(P-PEKE-SRCEXTEN); $avp(acc_direction)="out"; setflag(FLT_ACC); setflag(FLT_ACC_MISS); } -- PekePBX, the multitenant PBX solution https://pekepbx.com pgp_g7FyK5w59.pgp Description: Firma digital OpenPGP __ Kamailio - Users Mailing List - Non Commercial Discussions To unsubscribe send an email to sr-users-le...@lists.kamailio.org Important: keep the mailing list in the recipients, do not reply only to the sender! Edit mailing list options or unsubscribe:
[SR-Users] Re: Filtering codes in db acc
El Thu, 6 Jun 2024 15:40:19 +0200 "Jon Bonilla (Manwe) via sr-users" escribió: > > DEBUG: acc [acc_logic.c:721]: tmcb_func(): acc callback called for > t(0x7f7cec807480) event type 512, reply code 407 > > DEBUG: acc [acc_logic.c:443]: should_acc_reply(): probing acc state - code: > 407 flags: 0x220 > > DEBUG: acc [acc_logic.c:449]: should_acc_reply(): failed acc is off > Checking the acc_logic.c I see that filter is not checked because this: if(!is_failed_acc_on(req)) { and #define is_failed_acc_on(_rq) is_acc_flag_set(_rq, failed_transaction_flag) So seems like filter needs modparam failed_transaction_flag to work. (this is me trying to understand C code. Forgive me if I mess it up) So I added just to check modparam("acc", "db_missed_flag", FLT_ACC_MISS) modparam("acc", "failed_transaction_flag", FLT_ACC_MISS) that way when I set the flag I also set for that modparam. But I get the same result and the same log acc [acc_logic.c:721]: tmcb_func(): acc callback called for t(0x7fcbd3e47920) event type 512, reply code 407 acc [acc_logic.c:443]: should_acc_reply(): probing acc state - code: 407 flags: 0x220 acc [acc_logic.c:449]: should_acc_reply(): failed acc is off Any ideas over there? thanks -- PekePBX, the multitenant PBX solution https://pekepbx.com pgpP4oXzsMrba.pgp Description: Firma digital OpenPGP __ Kamailio - Users Mailing List - Non Commercial Discussions To unsubscribe send an email to sr-users-le...@lists.kamailio.org Important: keep the mailing list in the recipients, do not reply only to the sender! Edit mailing list options or unsubscribe:
[SR-Users] Filtering codes in db acc
Hi all I'm trying to make kamailio not to insert a row in missed_calls table when reply code is 407. But even if I set the "failed_filter" modparam the 407 row is inserted. The acc mmodparams are: modparam("acc", "db_table_acc", "kam_acc") modparam("acc", "db_flag", FLT_ACC) modparam("acc", "db_missed_flag", FLT_ACC_MISS) modparam("acc", "db_url",DBURL) modparam("acc", "db_insert_mode", 1) modparam("acc", "time_mode", 2) modparam("acc", "time_attr", "time_hires") modparam("acc", "failed_filter", "401,407") modparam("acc", "db_extra", "whatever" db is mysql. Kamailio version is 5.7.4 When I send a call that receives a 407 and after auth a 480 y get both rows in missed_calls table. Log: DEBUG: acc [acc_mod.c:404]: mod_init(): acc db table initialized to: kam_acc DEBUG: acc [acc_mod.c:362]: parse_failed_filter(): failed_filter 0 = 401 DEBUG: acc [acc_mod.c:362]: parse_failed_filter(): failed_filter 1 = 407 DEBUG: acc [acc_logic.c:721]: tmcb_func(): acc callback called for t(0x7f7cec807480) event type 512, reply code 407 DEBUG: acc [acc_logic.c:443]: should_acc_reply(): probing acc state - code: 407 flags: 0x220 DEBUG: acc [acc_logic.c:449]: should_acc_reply(): failed acc is off DEBUG: acc [acc_logic.c:721]: tmcb_func(): acc callback called for t(0x7f7cebf59bc0) event type 512, reply code 486 DEBUG: acc [acc_logic.c:443]: should_acc_reply(): probing acc state - code: 486 flags: 0x220 DEBUG: acc [acc_logic.c:449]: should_acc_reply(): failed acc is off am I configuring this wrong? cheers, Jon -- PekePBX, the multitenant PBX solution https://pekepbx.com pgpzCCkyBwzk9.pgp Description: Firma digital OpenPGP __ Kamailio - Users Mailing List - Non Commercial Discussions To unsubscribe send an email to sr-users-le...@lists.kamailio.org Important: keep the mailing list in the recipients, do not reply only to the sender! Edit mailing list options or unsubscribe:
[SR-Users] Re: Kamailio works but voice is not present during the calls!
El Sat, 20 Apr 2024 17:28:09 - "christian.marinelli--- via sr-users" escribió: > Hi all, > i have a problem with my Kamailio SIP Server. > I set up a Kamailio SIP server in a virtual machine on a private network and > i connect to this with a WireGuard VPN. The problem is that i can connect to > the SIP server throught different clients and users and i can call the other > users, the devices ring and i can answer to the calls but unfortunatly there > is no audio during the call :( I can't understand why, it seems all si OK, a > year ago i set up another SIP server with the same configuration and all > works correctly with it. Can anyone help me to understand why? I can copy and > paste here all the config files if you need it. Thank you so much in advance Do you bridge the audio in the rtp proxy the same way you bridge the signaling in the sip proxy? -- PekePBX, the multitenant PBX solution https://pekepbx.com pgpiyshy3x5FL.pgp Description: Firma digital OpenPGP __ Kamailio - Users Mailing List - Non Commercial Discussions To unsubscribe send an email to sr-users-le...@lists.kamailio.org Important: keep the mailing list in the recipients, do not reply only to the sender! Edit mailing list options or unsubscribe:
[SR-Users] Re: Topos methods_nocontact parameter
El Mon, 26 Feb 2024 15:39:31 +0100 Benoit Panizzon via sr-users escribió: > > The message body is not the issue, this seems to be handled in a > different memory buffer. The CPE crashed with a 'memory buffer too > small' when composing the reply to an invite with 5 or more Via and RR > even with minimalistic SDP. On the other hand, I threw a huge SDP with > ICE and Crypto to that CPE and it handled it well when only one Via and > no RR was present (after being handled by topos). > Those 5 vias remind me an old firmware of Cisco equipment. I think I found that once and solved with sems or something else acting as b2bua. Not sure if this is the same case but it didn't have to do with the length of the message but rather with a limitation on the number of vias in the firmware. -- PekePBX, the multitenant PBX solution https://pekepbx.com pgp52fUHJFEHk.pgp Description: Firma digital OpenPGP __ Kamailio - Users Mailing List - Non Commercial Discussions To unsubscribe send an email to sr-users-le...@lists.kamailio.org Important: keep the mailing list in the recipients, do not reply only to the sender! Edit mailing list options or unsubscribe:
[SR-Users] Re: rr, loose_route and corex alias_subdomains
El Fri, 19 Jan 2024 12:07:39 +0100 Daniel-Constantin Mierla escribió: > Hello, > > the log message in your first email is about not finding the socket. The > record route matches the domain, it is just that the socket to be used > cannot matched by the second Route URI. You can name the sockets and set > them in record-route to handle it. > > Thanks Daniel I'll try as soon as I can. My sockets are all named. It will be enabling sockname_mode modparam enough? And why the kamctl rpc corex.list_aliases doesn't list what I added to alias_subdomains corex modparam? cheers, Jon -- PekePBX, the multitenant PBX solution https://pekepbx.com pgpL9cedkdGSi.pgp Description: Firma digital OpenPGP __ Kamailio - Users Mailing List - Non Commercial Discussions To unsubscribe send an email to sr-users-le...@lists.kamailio.org Important: keep the mailing list in the recipients, do not reply only to the sender! Edit mailing list options or unsubscribe:
[SR-Users] Re: rr, loose_route and corex alias_subdomains
Upgraded to 5.7.4 Then I added "sindominio.net" example domain to corex aliases Debug Log: Jan 19 08:14:32 pekedev33 kamailio: DEBUG: [core/modparam.c:135]: set_mod_param_regex(): found in module corex [/usr/lib/x86_64-linux-gnu/kamailio/modules/corex.so] Jan 19 08:14:32 pekedev33 kamailio: DEBUG: corex [corex_lib.c:117]: corex_add_alias_subdomains(): try to add alias: sindominio.net Jan 19 08:14:32 pekedev33 kamailio: DEBUG: corex [corex_lib.c:185]: corex_add_alias_subdomains(): alias: 0:sindominio.net:0 from value: sindominio.net added But from console: # kamctl rpc corex.list_aliases { "jsonrpc": "2.0", "result": [ ], "id": 87891 } -- PekePBX, the multitenant PBX solution https://pekepbx.com pgpfbBNX11Qfr.pgp Description: Firma digital OpenPGP __ Kamailio - Users Mailing List - Non Commercial Discussions To unsubscribe send an email to sr-users-le...@lists.kamailio.org Important: keep the mailing list in the recipients, do not reply only to the sender! Edit mailing list options or unsubscribe:
[SR-Users] rr, loose_route and corex alias_subdomains
Hi I'm having an issue with the double rr for mst direct routing. I'm using subdomains like 23234.mydomain.com with a wildcard certificate and I set corex modparam alias_subdomains to mydomain.com But loose_route doesn't seem to detect the rr as myself I get the message: rr [loose.c:804]: rr_do_force_send_socket(): no socket found to match second RR (sip:20141.mydomain.com:5063;transport=tls;ftag=as7107d0fe;lr;r2=on;vsf=AAADCQMaABhMS1NYRh0cRllbR0RRQG91cC5lcw--;nat=yes;pet=mst) Regarding my setup is more or less like this: kamailio.local.cfg: #!substdef "!MSTDOMAIN!mydomain.com!g" kamailio.cfg: modparam("corex", "alias_subdomains", "MSTDOMAIN") But in the cli: kamctl rpc corex.list_aliases { "jsonrpc": "2.0", "result": [ ], "id": 1319303 } I don't remember to have this issue when I was developing the mst integration. Either I missed it or can it be a regression? kamailio version is 5.6.4 at the moment. Any ideas? cheers Jon -- PekePBX, the multitenant PBX solution https://pekepbx.com pgpzPYNBBKzEu.pgp Description: Firma digital OpenPGP __ Kamailio - Users Mailing List - Non Commercial Discussions To unsubscribe send an email to sr-users-le...@lists.kamailio.org Important: keep the mailing list in the recipients, do not reply only to the sender! Edit mailing list options or unsubscribe:
[SR-Users] Re: Not checking SRV records
El Sat, 13 Jan 2024 19:08:37 +0100 "Jon Bonilla (Manwe) via sr-users" escribió: It was stupid indeed. I wasn't seeing that I was receiving 5060 as ruri port. For future readers: If you have $rp != $null only A and queries are performed. cheers, Jon -- PekePBX, the multitenant PBX solution https://pekepbx.com pgpOSt5EX5Coj.pgp Description: Firma digital OpenPGP __ Kamailio - Users Mailing List - Non Commercial Discussions To unsubscribe send an email to sr-users-le...@lists.kamailio.org Important: keep the mailing list in the recipients, do not reply only to the sender! Edit mailing list options or unsubscribe:
[SR-Users] Not checking SRV records
Hi This may be a stupid question but after a couple of hours and some headache I can't see where the problem is. I'm trying to use SRV records to relay to different servers as I've done many many times before. But in this case I'm getting a 478 from kamailio and I see that it's not trying to resolve SRV. From the log: [core/dns_cache.c:527]: _dns_hash_find(): (fs.mydomain.dev(16), 1), h=632 [core/resolve.c:784]: get_record(): lookup(fs.mydomain.dev, 1) failed [core/dns_cache.c:761]: dns_cache_mk_bad_entry(): (fs.mydomain.dev, 1, 60, 1) [core/dns_cache.c:701]: dns_cache_add(): adding fs.mydomain.dev(16) 1 (flags=1) at 632 [core/dns_cache.c:2807]: dns_a_resolve(): (fs.mydomain.dev, 0) returning -7 [core/dns_cache.c:3176]: dns_srv_sip_resolve(): (fs.mydomain.dev, 0, 0), ip, ret=-7 uri2dst2(): failed to resolve "fs.mydomain.dev" :unresolvable A or request (-7) When doing tcpdump port 53 I see A record query but no SRV SRV records of course exist although they are not being checked. dns params in kamailio: dns_try_ipv6=no dns_retr_time=1 dns_retr_no=1 dns_use_search_list=no use_dns_cache=on use_dns_failover=on dns_srv_lb=on dns_try_naptr=no dns_sctp_pref=1 dns_tcp_pref=1 dns_tls_pref=1 dns_udp_pref=1 Same exact config in another server is working. There's something I'm missing and can't see. Any hints? cheers, Jon -- PekePBX, the multitenant PBX solution https://pekepbx.com pgprCrHIbB4Zn.pgp Description: Firma digital OpenPGP __ Kamailio - Users Mailing List - Non Commercial Discussions To unsubscribe send an email to sr-users-le...@lists.kamailio.org Important: keep the mailing list in the recipients, do not reply only to the sender! Edit mailing list options or unsubscribe: