[SR-Users] Mid-dialog failover without virtual IP

2022-01-13 Thread Muhammad Danish Moosa
Hi,

I have a pair of kamailio stateful proxies and am trying to achieve
Active-Passive failover model with DMQ dialog replication. Primary Proxy is
working in the middle of  2 SBCs and all nodes are within the same network
so NATing is NOT involved ;secondary proxy is accessible through VPN. It's
pretty simple configuration, proxy is just adding and removing headers in
the middle.

So if I stop the kamailio service on primary IP , SBCs blacklist that and
start sending new invites to secondary IP. That's all good.

But if I reproduce this failover during a connected session , SBCs do not
send mid-dialog requests/responses to failover IP. I can see they still try
to send messages to primary SBC which obviously end up with timeout. I
understand the most natural solution is HA with Virual IP but it's not
possible because secondary IP is accessible through VPN.

I tried to use DNS SRV record with priorities but that also does not work
with mid-dialog messages, I also have tried to change record-route/via
header to fqdn through advertise_address. Its not changing record-route but
via only but I am still not getting expected results.

Any guidance of possible solution(s) here will be appreciated.






-- 
Muhammad Danish Moosa

" The core of mans' spirit comes from new experiences. "___ Christopher
McCandless
__
Kamailio - Users Mailing List - Non Commercial Discussions
  * sr-users@lists.kamailio.org
Important: keep the mailing list in the recipients, do not reply only to the 
sender!
Edit mailing list options or unsubscribe:
  * https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users


[SR-Users] Retrieve last via IP from SIP MEssage

2022-01-13 Thread Adarsh Chauhan
Hi All,

I have tried couple of methods to retrieve last via IP of SIP message but 
failed to retrieve it, trying to retrieve the source

- @hf_value.via[-1].host,
it simply prints the exact text back @hf_value.via[-1].host

- $sel(@hf_value.via[-1])
it doest give the IP but the entire via value
SIP/2.0/TCP 
172.31.30.144;branch=z9hG4bKf8bd.753341d2.0.host

@via[-1].host
it also simply prints the exact text back @via[-1].host

Regards,
Adarsh Chauha
__
Kamailio - Users Mailing List - Non Commercial Discussions
  * sr-users@lists.kamailio.org
Important: keep the mailing list in the recipients, do not reply only to the 
sender!
Edit mailing list options or unsubscribe:
  * https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users


[SR-Users] Alternate to FoHSS for Kamailio IMS?

2022-01-13 Thread Simon,Benjamin T
Hello,

We are attempting to setup an instance of Kamailio to serve as an IMS 
for a test setup of 4G/5G NSA with Open5GS.

The instructions on the Kamailio wiki and provided by Open5GS 
currently specify to use FoHSS as the HSS solution for Kamailio IMS. As
this HSS solution has not seen significant development in a few years 
we are reticent to deploy it on our implementation.

Is there an alternative open source HSS which can be deployed to serve 
as the HSS for Kamailio instead of FoHSS, and would there need to be 
any adjustments to Kamailio to reflect the deployment of this HSS 
instead of FoHSS?

Thank you,


Benjamin Simon


Research Assistant
Florida Institute for Cybersecurity Research, University of Florida
Email: bsim...@ufl.edu

Disclaimer: Florida has a very broad public records law. As a result, 
any written communication created or received by the University of 
Florida will be made available to the public and media, upon request, 
unless otherwise exempt. Under Florida law, e-mail addresses are public
records. If you do not want your e-mail address released in response to
a public records request, do not send electronic mail to this address. 
Instead, contact by phone or in writing.

__
Kamailio - Users Mailing List - Non Commercial Discussions
  * sr-users@lists.kamailio.org
Important: keep the mailing list in the recipients, do not reply only to the 
sender!
Edit mailing list options or unsubscribe:
  * https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Massive uploading of aliases through a dbtext

2022-01-13 Thread Denys Pozniak
Do I understand correctly that if db_text is in caching mode ( db_mode=0 ),
then changes in the dbtext/domain file are not updated by the *kamcmd
domain.reload* command?


чт, 13 янв. 2022 г. в 12:17, Denys Pozniak :

> Thanks! Now it works!
>
> чт, 13 янв. 2022 г. в 11:55, Daniel-Constantin Mierla :
>
>> Hello,
>>
>> alias_db is for user aliases, not for host aliases. For multi-domain
>> support with database storage, use domain module and set register myself
>> mod param.
>>
>> Anyhow, the domains won't show up in core.aliases_list rpc response,
>> that's only for host aliases set in config file, but domain module has also
>> rpc command for listing its records.
>>
>> Cheers,
>> Daniel
>> On 13.01.22 10:49, Denys Pozniak wrote:
>>
>> Hello!
>>
>> I need help uploading a list of aliases through a dbtext to use them via
>> myself.
>> It is likely that there is some configuration problem:
>>
>> *loadmodule "db_text.so"*
>>
>>
>> *modparam("db_text", "db_mode", 1) modparam("db_text", "emptystring", 1) *
>>
>>
>>
>> *loadmodule "alias_db.so" modparam("alias_db", "db_url",
>> "text:///etc/kamailio/dbtext") *
>>
>>
>>
>>
>>
>> *[root@kamailio]$ cat dbtext/dbaliases id(int,auto)
>> alias_username(string) alias_domain(string) username(string) domain(string)
>> 1::sip.test.local:: *
>>
>>
>>
>>
>>
>>
>> *[root@kamailio]$ kamcmd core.aliases_list { myself_callbacks:
>> yes aliases: { } } *
>>
>> If done through a script (alias=sip.test.local), then everything works
>> fine:
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>> *[root@kamailio]$ kamcmd core.aliases_list { myself_callbacks:
>> yes aliases: { alias: {
>> proto: * address: sip.test.local
>>   port: * } } } *
>>
>>
>> --
>>
>> BR,
>> Denys Pozniak
>>
>>
>>
>> __
>> Kamailio - Users Mailing List - Non Commercial Discussions
>>   * sr-users@lists.kamailio.org
>> Important: keep the mailing list in the recipients, do not reply only to the 
>> sender!
>> Edit mailing list options or unsubscribe:
>>   * https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
>>
>> --
>> Daniel-Constantin Mierla -- www.asipto.comwww.twitter.com/miconda -- 
>> www.linkedin.com/in/miconda
>> Kamailio Advanced Training - Online
>>   Feb 21-24, 2022 (America Timezone)
>>   * https://www.asipto.com/sw/kamailio-advanced-training-online/
>>
>>
>
> --
>
> BR,
> Denys Pozniak
>
>
>

-- 

BR,
Denys Pozniak
__
Kamailio - Users Mailing List - Non Commercial Discussions
  * sr-users@lists.kamailio.org
Important: keep the mailing list in the recipients, do not reply only to the 
sender!
Edit mailing list options or unsubscribe:
  * https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] EVAPI workload allocation across processes

2022-01-13 Thread Henning Westerholt
Hello Alex,

I did not looked that closely, sorry. Maybe somebody else can comment as well.

My suggestion would be to try on a small (i.e. low children count) test setup 
and look e.g. with some "strace" tools inside the process and see actually what 
is happening.

Cheers,

Henning

-Original Message-
From: sr-users  On Behalf Of Alex Balashov
Sent: Tuesday, January 11, 2022 4:25 PM
To: Kamailio (SER) - Users Mailing List 
Subject: Re: [SR-Users] EVAPI workload allocation across processes

Thanks, Henning! So, does this mean that all messages over a given connection 
are always received in the same EvAPI worker process? Or does the dispatcher 
hold the connections, process the messages, and then allocate these messages in 
a RR/pseudorandom fashion among one or more EvAPI worker processes?

The latter was my understanding, but you said: "The dispatcher process 
accept(..) the connections and then pass them to the worker processes for 
further processing.”

That particular formulation had me wondering if the connections themselves are 
handed off to workers, or just the messages.

— Alex

> On Jan 11, 2022, at 10:09 AM, Henning Westerholt  wrote:
> 
> Hi Alex,
> 
> not the author of this module - but I think you are right after having 
> briefly looked to the code. The dispatcher process accept(..) the connections 
> and then pass them to the worker processes for further processing. 
> 
> Cheers,
> 
> Henning
> 
> --
> Henning Westerholt – https://skalatan.de/blog/ Kamailio services – 
> https://gilawa.com
> 
> -Original Message-
> From: sr-users  On Behalf Of Alex 
> Balashov
> Sent: Sunday, January 2, 2022 3:54 AM
> To: Kamailio (SER) - Users Mailing List 
> Subject: [SR-Users] EVAPI workload allocation across processes
> 
> Hi,
> 
> Given several EVAPI worker processes:
> 
>   modparam("evapi", "workers", 4)
> 
>   # kamcmd -s /run/kamailio/kamailio_ctl ps | fgrep -i evapi
>   539257  EvAPI Dispatcher
>   539258  EvAPI Worker
>   539259  EvAPI Worker
>   539260  EvAPI Worker
>   539261  EvAPI Worker
> 
> How should one understand the way that the EVAPI workload is allocated among 
> them?
> 
> My best guess is that the EvAPI dispatcher process is the sole accept()or of 
> client connections and the place where all relaying to client connections is 
> done, regardless of their number, and that the ‘workers’ represent an async 
> pool of processes in which TM transactions can be resumed or other work can 
> be done when an outside caller sends a message to the dispatcher.
> 
> However, the documentation[1] is a little vague on the meaning of the 
> ‘workers’ modparam:
> 
>   "Number of worker processes to be started to handle incoming messages from 
> remote applications.”
> 
> Or maybe it’s not. Just wanted to confirm that my understanding is correct.
> 
> Thanks!
> 
> — Alex
> 
> [1] 
> https://kamailio.org/docs/modules/5.5.x/modules/evapi.html#evapi.p.wor
> kers
> 
> --
> Alex Balashov | Principal | Evariste Systems LLC
> 
> Tel: +1-706-510-6800 / +1-800-250-5920 (toll-free)
> Web: http://www.evaristesys.com/, http://www.csrpswitch.com/
> 
> 
> __
> Kamailio - Users Mailing List - Non Commercial Discussions
>  * sr-users@lists.kamailio.org
> Important: keep the mailing list in the recipients, do not reply only to the 
> sender!
> Edit mailing list options or unsubscribe:
>  * https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users

--
Alex Balashov | Principal | Evariste Systems LLC

Tel: +1-706-510-6800 / +1-800-250-5920 (toll-free)
Web: http://www.evaristesys.com/, http://www.csrpswitch.com/


__
Kamailio - Users Mailing List - Non Commercial Discussions
  * sr-users@lists.kamailio.org
Important: keep the mailing list in the recipients, do not reply only to the 
sender!
Edit mailing list options or unsubscribe:
  * https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
__
Kamailio - Users Mailing List - Non Commercial Discussions
  * sr-users@lists.kamailio.org
Important: keep the mailing list in the recipients, do not reply only to the 
sender!
Edit mailing list options or unsubscribe:
  * https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Massive uploading of aliases through a dbtext

2022-01-13 Thread Denys Pozniak
Thanks! Now it works!

чт, 13 янв. 2022 г. в 11:55, Daniel-Constantin Mierla :

> Hello,
>
> alias_db is for user aliases, not for host aliases. For multi-domain
> support with database storage, use domain module and set register myself
> mod param.
>
> Anyhow, the domains won't show up in core.aliases_list rpc response,
> that's only for host aliases set in config file, but domain module has also
> rpc command for listing its records.
>
> Cheers,
> Daniel
> On 13.01.22 10:49, Denys Pozniak wrote:
>
> Hello!
>
> I need help uploading a list of aliases through a dbtext to use them via
> myself.
> It is likely that there is some configuration problem:
>
> *loadmodule "db_text.so"*
>
>
> *modparam("db_text", "db_mode", 1) modparam("db_text", "emptystring", 1) *
>
>
>
> *loadmodule "alias_db.so" modparam("alias_db", "db_url",
> "text:///etc/kamailio/dbtext") *
>
>
>
>
>
> *[root@kamailio]$ cat dbtext/dbaliases id(int,auto) alias_username(string)
> alias_domain(string) username(string) domain(string) 1::sip.test.local:: *
>
>
>
>
>
>
> *[root@kamailio]$ kamcmd core.aliases_list { myself_callbacks: yes
> aliases: { } } *
>
> If done through a script (alias=sip.test.local), then everything works
> fine:
>
>
>
>
>
>
>
>
>
>
>
>
> *[root@kamailio]$ kamcmd core.aliases_list { myself_callbacks: yes
> aliases: { alias: { proto:
> * address: sip.test.local
> port: * } } } *
>
>
> --
>
> BR,
> Denys Pozniak
>
>
>
> __
> Kamailio - Users Mailing List - Non Commercial Discussions
>   * sr-users@lists.kamailio.org
> Important: keep the mailing list in the recipients, do not reply only to the 
> sender!
> Edit mailing list options or unsubscribe:
>   * https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
>
> --
> Daniel-Constantin Mierla -- www.asipto.comwww.twitter.com/miconda -- 
> www.linkedin.com/in/miconda
> Kamailio Advanced Training - Online
>   Feb 21-24, 2022 (America Timezone)
>   * https://www.asipto.com/sw/kamailio-advanced-training-online/
>
>

-- 

BR,
Denys Pozniak
__
Kamailio - Users Mailing List - Non Commercial Discussions
  * sr-users@lists.kamailio.org
Important: keep the mailing list in the recipients, do not reply only to the 
sender!
Edit mailing list options or unsubscribe:
  * https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Massive uploading of aliases through a dbtext

2022-01-13 Thread Daniel-Constantin Mierla
Hello,

alias_db is for user aliases, not for host aliases. For multi-domain
support with database storage, use domain module and set register myself
mod param.

Anyhow, the domains won't show up in core.aliases_list rpc response,
that's only for host aliases set in config file, but domain module has
also rpc command for listing its records.

Cheers,
Daniel

On 13.01.22 10:49, Denys Pozniak wrote:
> Hello!
>
> I need help uploading a list of aliases through a dbtext to use them
> via myself.
> It is likely that there is some configuration problem:
>
> /loadmodule "db_text.so"/
> /modparam("db_text", "db_mode", 1)
> modparam("db_text", "emptystring", 1)
> /
> /
> /
> /loadmodule "alias_db.so"
> modparam("alias_db", "db_url", "text:///etc/kamailio/dbtext")
> /
> /
> /
> /[root@kamailio]$ cat dbtext/dbaliases
> id(int,auto) alias_username(string) alias_domain(string)
> username(string) domain(string)
> 1::sip.test.local::
>
> /
> /[root@kamailio]$ kamcmd core.aliases_list
> {
>         myself_callbacks: yes
>         aliases: {
>         }
> }
> /
>
> If done through a script (alias=sip.test.local), then everything works
> fine:
>
> /[root@kamailio]$ kamcmd core.aliases_list
> {
>         myself_callbacks: yes
>         aliases: {
>                 alias: {
>                         proto: *
>                         address: sip.test.local
>                         port: *
>                 }
>         }
> }
> /
>
>
> -- 
>
> BR,
> Denys Pozniak
>
>
>
> __
> Kamailio - Users Mailing List - Non Commercial Discussions
>   * sr-users@lists.kamailio.org
> Important: keep the mailing list in the recipients, do not reply only to the 
> sender!
> Edit mailing list options or unsubscribe:
>   * https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users

-- 
Daniel-Constantin Mierla -- www.asipto.com
www.twitter.com/miconda -- www.linkedin.com/in/miconda
Kamailio Advanced Training - Online
  Feb 21-24, 2022 (America Timezone)
  * https://www.asipto.com/sw/kamailio-advanced-training-online/
__
Kamailio - Users Mailing List - Non Commercial Discussions
  * sr-users@lists.kamailio.org
Important: keep the mailing list in the recipients, do not reply only to the 
sender!
Edit mailing list options or unsubscribe:
  * https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users


[SR-Users] Massive uploading of aliases through a dbtext

2022-01-13 Thread Denys Pozniak
Hello!

I need help uploading a list of aliases through a dbtext to use them via
myself.
It is likely that there is some configuration problem:

*loadmodule "db_text.so"*


*modparam("db_text", "db_mode", 1)modparam("db_text", "emptystring", 1)*



*loadmodule "alias_db.so"modparam("alias_db", "db_url",
"text:///etc/kamailio/dbtext")*





*[root@kamailio]$ cat dbtext/dbaliasesid(int,auto) alias_username(string)
alias_domain(string) username(string) domain(string)1::sip.test.local::*






*[root@kamailio]$ kamcmd core.aliases_list{myself_callbacks: yes
aliases: {}}*

If done through a script (alias=sip.test.local), then everything works fine:












*[root@kamailio]$ kamcmd core.aliases_list{myself_callbacks: yes
aliases: {alias: {proto: *
  address: sip.test.localport: *
}}}*


-- 

BR,
Denys Pozniak
__
Kamailio - Users Mailing List - Non Commercial Discussions
  * sr-users@lists.kamailio.org
Important: keep the mailing list in the recipients, do not reply only to the 
sender!
Edit mailing list options or unsubscribe:
  * https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users