[SR-Users] Switching form UDP to TCP causes authentication errors

2018-05-24 Thread Wilkins, Steve
Hello All,

When I switched from UDP to TCP I started getting Authentication Errors, 
Asterisk responds to an INVITE via Kamailio with a '401 Unauthorized', but 
Kamailio does nothing with it.  Processing just stops near WITH_BLOCK401407.  
Shouldn't the 401 be relayed so a new INVITE can be sent?

Thank you.
___
Kamailio (SER) - Users Mailing List
sr-users@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Performance Testing Kamailio 5.1 as SIP300 LCR on AWS - Recommendation on Tools and Methods

2018-05-24 Thread Alex Balashov
On Thu, May 24, 2018 at 10:27:00PM +, KamDev Essa wrote:

>  I am assuming the function http_query in kamailio utils is async. Is it not? 

It is not async, and is furthermore deprecated in 5.x.

You may want to have a look at:

https://kamailio.org/docs/modules/5.1.x/modules/http_client.html
https://kamailio.org/docs/modules/5.1.x/modules/http_async_client.html

But in general, if you're looking to squeeze maximum performance for a
dialer type workload, no, pound-for-pound, HTTP is not the way to go.

-- Alex

-- 
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 (SER) - Users Mailing List
sr-users@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Performance Testing Kamailio 5.1 as SIP300 LCR on AWS - Recommendation on Tools and Methods

2018-05-24 Thread KamDev Essa
 I am assuming the function http_query in kamailio utils is async. Is it not? 
KD
On Thursday, May 24, 2018, 6:19:33 PM EDT, Alex Balashov 
 wrote:  
 
 On Thu, May 24, 2018 at 10:15:42PM +, KamDev Essa wrote:

>    - Is http_query a bad choice for performance. Is KEMI better?

As long as you perform the queries in a properly asynchronous manner,
i.e. using http_async_client, not necessarily. But yes, HTTP queries are
by nature bureaucratic, since they evolve the establishment of a new
connection socket, etc. Doing something more inline is always better.

>    - Are there any better free apps than SIPp?

sipp is the leading FOSS tool for this. There are a variety of
commercial ones.

>    - Has anyone got cps stats for a SIP300 only Kamailio instance on AWS

That's a meaningless question; way, way, way too many variables.

>    - Is AWS a bad choice for prime time LCR. Any gory stories? 

No, it's not a bad choice.

-- Alex

-- 
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 (SER) - Users Mailing List
sr-users@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
  ___
Kamailio (SER) - Users Mailing List
sr-users@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Performance Testing Kamailio 5.1 as SIP300 LCR on AWS - Recommendation on Tools and Methods

2018-05-24 Thread Alex Balashov
On Thu, May 24, 2018 at 10:15:42PM +, KamDev Essa wrote:

>- Is http_query a bad choice for performance. Is KEMI better?

As long as you perform the queries in a properly asynchronous manner,
i.e. using http_async_client, not necessarily. But yes, HTTP queries are
by nature bureaucratic, since they evolve the establishment of a new
connection socket, etc. Doing something more inline is always better.

>- Are there any better free apps than SIPp?

sipp is the leading FOSS tool for this. There are a variety of
commercial ones.

>- Has anyone got cps stats for a SIP300 only Kamailio instance on AWS

That's a meaningless question; way, way, way too many variables.

>- Is AWS a bad choice for prime time LCR. Any gory stories? 

No, it's not a bad choice.

-- Alex

-- 
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 (SER) - Users Mailing List
sr-users@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users


[SR-Users] Performance Testing Kamailio 5.1 as SIP300 LCR on AWS - Recommendation on Tools and Methods

2018-05-24 Thread KamDev Essa
I am currently setup with Kamailio 5.1 on an AWS t2.micro as a SIP300 LCR 
solution with a http_query call to an external resource (c# .NetCore app for 
LRN dip and MySQL Route choices) to get the contacts string, tag it to the 
Contact header an send 300. 
Its been a while since I have performance tested on SIP and It was SIPp.   
   - Is http_query a bad choice for performance. Is KEMI better?
   - Are there any better free apps than SIPp?
   - Has anyone got cps stats for a SIP300 only Kamailio instance on AWS
   - Is AWS a bad choice for prime time LCR. Any gory stories? 
KD   
___
Kamailio (SER) - Users Mailing List
sr-users@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users


[SR-Users] Kamailio does not receive anything after exit route

2018-05-24 Thread Andrey Deykunov
Hi there,

I've added a simple black list that rejects incoming requests (REGISTER and
INVITE) containing certain text in the message body. Source IP addresses of
the rejected requests are going to be banned and added to the ban list:

route
> {
> ...
>
>
> $var(ban_list_key) = $si + ":" + $sp;
> if ($sht(ip_ban_list=>$var(ban_list_key)) != $null) {
> xlog("L_INFO", "$var(log_fmt_tag) The incoming $rm request
> from: $fU, si: $si, sp: $sp was rejected. The source host is temporarily
> banned.");
> sl_send_reply("400", "Bad request");
> exit;
> }
>
> ...
>
> if (method=="REGISTER" || method=="INVITE") {
> sht_iterator_start("i1", "black_list");
> while(sht_iterator_next("i1")) {
> $var(term_is_in_wl) = 0;
> $var(collision_idx) = 0;
> while($sht(white_list=>$fU[$var(collision_idx)]) != $null
> ) {
> if($shtitval(i1) ==
> $sht(white_list=>$fU[$var(collision_idx)])) {
> $var(term_is_in_wl) = 1;
> break;
> }
> $var(collision_idx) = $var(collision_idx) + 1;
> }
> if ($var(term_is_in_wl) == 0) {
> if ( $mb =~ $shtitval(i1) ) {
> # found a term from the black list. access denied.
> xlog("L_INFO", "$var(log_fmt_tag) The incoming $rm
> request from: $fU, si: $si, sp: $sp was rejected. SIP message body contains
> a term from the black list - $shtitval(i1)");
> # add device to banlist
> $var(ban_info) = "" + $Ts + "_" + $shtitval(i1);
> $sht(ip_ban_list=>$var(ban_list_key)) =
> $var(ban_info);
> xlog("L_INFO", "$var(log_fmt_tag) The source host
> $si:$sp was banned for 1 hour.");
> sht_iterator_end("i1");
> sl_send_reply("400", "Bad request");
> exit;
> }
> }
> }
> sht_iterator_end("i1");
> }
> ...
> }


All works fine with UPD, but using TCP, kamailio ceases to accept any
requests. Please take a look, what do I wrong.

Thanks,
Andrey
___
Kamailio (SER) - Users Mailing List
sr-users@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] SIP Server Hardware or VM ??

2018-05-24 Thread Daniel Tryba
On Wed, May 23, 2018 at 02:57:57PM +, Pinter, Gerd. wrote:
> Thank you very much, this underpins my consideration.
> How to tell my Boss :o  

Since I wasn't explicit in my reply: we are running rtpengine in vmware.
The test I did bare metal vs. vmware was to confirm there is no problem
with vmware guests if you limit the amount of traffic per instance and
make sure not to overprovision.

Sure rtpengine on bare metal will be better since there is no resource
contention, but in my case that would mean multiple dedicated machines in
multiple datacentra essentially wasting 90% of resources ideling.


___
Kamailio (SER) - Users Mailing List
sr-users@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] SIP Server Hardware or VM ??

2018-05-24 Thread Henning Westerholt
Am Mittwoch, 23. Mai 2018, 16:57:57 CEST schrieb Pinter, Gerd.:
> Thank you very much, this underpins my consideration.
> How to tell my Boss :o  
> 
> Nice Regards

Hello Gerd,

to help to convince your boss I would try to underline your thoughts with some 
measurements. 

Something like this: if you get higher load on the e.g. VMWare Vcenter physical 
machines, 
then the jitter also increases etc.. Maybe you can test this during a time 
where the effect is 
also not that visible.

Maybe the talk from Alex Balashov at this year Kamailio World (available on 
youtube) 
about cloud environment restrictions and other things is also interesting for 
you, to give 
some arguments.

Best regards,

Henning
___
Kamailio (SER) - Users Mailing List
sr-users@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users