[OpenSIPS-Users] Monitoring Mediaproxy

Carlos Oliva carlos.oliva at numintec.com
Mon Mar 20 06:00:45 EDT 2017

Hi Daniel!

I made a little php script for Nagios some years ago that may help you.

It is intented to use on opensips machine (where media dispatcher is

You pass as argument the number of mediaproxy relay machines you expected
to have and it returnks Ok and the list of your relays or error if the
number of relays is not what you expect.

It's very simple but works well, we've been using it for years. This is the

fputs($fp, "summary\r\n");
$line  = fgets($fp);
foreach($decoded as $relay)
                $str_salida.=" ".$relay->ip;
        echo "OK IPs de Relays RTP: ".$str_salida."\n";
        echo "ERROR faltan Relays. IPs de Relays RTP: ".$str_salida."\n";


Best regards,

Carlos Oliva

2017-03-17 18:57 GMT+01:00 Daniel Zanutti <daniel.zanutti at gmail.com>:

> Understood.
> Thanks for explanation.
> Regards
> On Fri, Mar 17, 2017 at 2:47 PM, Dan Pascu <dan at ag-projects.com> wrote:
>> On 16 Mar 2017, at 15:58, Daniel Zanutti wrote:
>> > Hi Dan
>> >
>> > This is exactly how I'm monitoring but looking to the dispatcher it's
>> kind hard on a Nagios like system, because I'm monitoring Relay A, B and C,
>> but the status will be on dispatcher machine D. But ok, if it's the only
>> way.
>> The relay doesn't listen for network connections, you cannot connect
>> directly to a relay. A relay will only connect to all configured
>> dispatchers. The dispatcher on the other hand has a control port where you
>> can connect and give commands, including fetching statistics from relays
>> over the connections the relay already established with the dispatcher.
>> --
>> Dan
>> _______________________________________________
>> Users mailing list
>> Users at lists.opensips.org
>> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
> _______________________________________________
> Users mailing list
> Users at lists.opensips.org
> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opensips.org/pipermail/users/attachments/20170320/507dacc4/attachment.html>

More information about the Users mailing list