Re: [OpenSIPS-Users] Crash at dialog.so

2020-11-11 Thread M S
Hi Liviu,
I did a quick look myself at dlg_timer.c (around the lines that crash
happens) and there is actually a FIXME note there too. it seems to me that
this issue happens when using create_dialog("PpB"), if one side is already
disconnected and also PpB doesn't receive a ping and decides to disconnect
the call, the module crashes. Basically, if the call is already
disconnected, we should not try to send BYE to them either.
For now, I removed "PpB" from create_dialog and the error has not occurred
again. I think that can be the workaround for now.

Thanks,
Mark

On Wed, Nov 11, 2020 at 3:40 PM Liviu Chircu  wrote:

> On 07.11.2020 13:27, M S wrote:
> > The server has a pretty high load, is Q_MALLOC_DBG safe?
>
> How "pretty" high of a load is that, in terms of "calls-per-second" and
> "max-concurrent-calls"?  Q_MALLOC_DBG will typically add +30-50% to
> shared/private memory usage, as well as maybe a 10% increase in CPU
> usage.  But OpenSIPS uses very few CPU and memory to begin with, so it
> will be quite safe to do.
>
> My advice: unless you're running more than 50 calls-per-second through
> it, there is no need to even start worrying about Q_MALLOC_DBG altering
> the system's behavior.  Below the 50 CPS level, the difference is
> unnoticeable.
>
> > also, is that an opensips command-line option? I don't see it in the
> > opensips man page...
> Yes, it's a "opensips" binary command-line option.  The man page needs
> updating, indeed, however you could try "opensips -h" and you'll see
> that option.
>
> --
> Liviu Chircu
> www.twitter.com/liviuchircu | www.opensips-solutions.com
>
>
___
Users mailing list
Users@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/users


Re: [OpenSIPS-Users] Crash at dialog.so

2020-11-11 Thread Liviu Chircu

On 07.11.2020 13:27, M S wrote:

The server has a pretty high load, is Q_MALLOC_DBG safe?


How "pretty" high of a load is that, in terms of "calls-per-second" and 
"max-concurrent-calls"?  Q_MALLOC_DBG will typically add +30-50% to 
shared/private memory usage, as well as maybe a 10% increase in CPU 
usage.  But OpenSIPS uses very few CPU and memory to begin with, so it 
will be quite safe to do.


My advice: unless you're running more than 50 calls-per-second through 
it, there is no need to even start worrying about Q_MALLOC_DBG altering 
the system's behavior.  Below the 50 CPS level, the difference is 
unnoticeable.


also, is that an opensips command-line option? I don't see it in the 
opensips man page...
Yes, it's a "opensips" binary command-line option.  The man page needs 
updating, indeed, however you could try "opensips -h" and you'll see 
that option.


--
Liviu Chircu
www.twitter.com/liviuchircu | www.opensips-solutions.com


___
Users mailing list
Users@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/users


Re: [OpenSIPS-Users] how to call ul_dump?brief using jsonrpc

2020-11-11 Thread Vlad Patrascu

Hi Babak,

This is a bit of a mistake in the documentation, as the parameter's name 
is "brief", but as value it actually expects an integer. As such the 
jsonrpc request should be:


'{"jsonrpc":"2.0","method":"ul_dump","params":{"brief":1},"id":10}'

or:

'{"jsonrpc":"2.0","method":"ul_dump","params":[1],"id":10}'

Regards,

--
Vlad Patrascu
OpenSIPS Developer
http://www.opensips-solutions.com

On 11.11.2020 15:08, Babak Yakhchali wrote:

Hi
I'm using opensips 3.1.
What json should be sent as body to http mi which results like 
ul_dump?brief

I tried this curl command but it is not working
curl --location --request POST 'http://127.0.0.1:8080/opensips_mi' \
--header 'Content-Type: application/json' \
--data-raw 
'{"jsonrpc":"2.0","method":"ul_dump","id":10,*"params":["brief"]*}'

I get
{"jsonrpc":"2.0","error":{"code":-32602,"message":"Invalid params"}

this works but it is not brief :)
 curl --location --request POST 'http://127.0.0.1:8080/opensips_mi' 
--header 'Content-Tya-raw '{"jsonrpc":"2.0","method":"ul_dump","id":10}'


thanks

___
Users mailing list
Users@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/users
___
Users mailing list
Users@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/users


[OpenSIPS-Users] how to call ul_dump?brief using jsonrpc

2020-11-11 Thread Babak Yakhchali
Hi
I'm using opensips 3.1.
What json should be sent as body to http mi which results like ul_dump?brief
I tried this curl command but it is not working
curl --location --request POST 'http://127.0.0.1:8080/opensips_mi' \
--header 'Content-Type: application/json' \
--data-raw '{"jsonrpc":"2.0","method":"ul_dump","id":10,*"params":["brief"]*
}'
I get
{"jsonrpc":"2.0","error":{"code":-32602,"message":"Invalid params"}

this works but it is not brief :)
 curl --location --request POST 'http://127.0.0.1:8080/opensips_mi'
--header 'Content-Tya-raw '{"jsonrpc":"2.0","method":"ul_dump","id":10}'

thanks
___
Users mailing list
Users@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/users