Michael Collins
2006-Nov-18 10:21 UTC
[asterisk-users] Asterisk Manager: equivalent of 'show channels'?
I'm interested in knowing if anyone else has worked around this issue: I have an application that needs to check the status of the calls going through Asterisk about every 5 seconds or so. I don't want to do "asterisk -rx 'show channels verbose'" at the Linux command line 12 times per minute so I am looking at the AMI. I see that there isn't a manager command for 'show channels.' Has anyone come up with an equivalent of 'show channels' using the extant manager commands? If so, could you post how you did it? Thanks! -MC -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.digium.com/pipermail/asterisk-users/attachments/20061118/6b344a43/attachment.htm
Marco Mouta
2006-Nov-18 10:24 UTC
[asterisk-users] Asterisk Manager: equivalent of 'show channels'?
take a look at Flash Operator Panel, as far as i know they use AMI , and they also provide "real time channel status". On 11/18/06, Michael Collins <mcollins@fcnetwork.com> wrote:> > I'm interested in knowing if anyone else has worked around this issue: > > > > I have an application that needs to check the status of the calls going > through Asterisk about every 5 seconds or so. I don't want to do "asterisk > ?rx 'show channels verbose'" at the Linux command line 12 times per minute > so I am looking at the AMI. I see that there isn't a manager command for > 'show channels.' Has anyone come up with an equivalent of 'show channels' > using the extant manager commands? If so, could you post how you did it? > > > > Thanks! > > -MC > > _______________________________________________ > --Bandwidth and Colocation provided by Easynews.com -- > > asterisk-users mailing list > To UNSUBSCRIBE or update options visit: > http://lists.digium.com/mailman/listinfo/asterisk-users > > >-- Com os melhores cumprimentos, Marco Mouta -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.digium.com/pipermail/asterisk-users/attachments/20061118/884f7c93/attachment.htm
Nico Busch
2006-Nov-18 10:33 UTC
[asterisk-users] Asterisk Manager: equivalent of 'show channels'?
As far as I know, you can do something like this, i.e. in PHP: fputs($socket, "Action: Command\r\n"); fputs($socket, "Command: show channels concise\r\n"); I hope that helps, but perhaps there is a better possibility. NB Michael Collins schrieb:> > I?m interested in knowing if anyone else has worked around this issue: > > I have an application that needs to check the status of the calls > going through Asterisk about every 5 seconds or so. I don?t want to do > ?asterisk ?rx ?show channels verbose?? at the Linux command line 12 > times per minute so I am looking at the AMI. I see that there isn?t a > manager command for ?show channels.? Has anyone come up with an > equivalent of ?show channels? using the extant manager commands? If > so, could you post how you did it? > > Thanks! > > -MC > > ------------------------------------------------------------------------ > > _______________________________________________ > --Bandwidth and Colocation provided by Easynews.com -- > > asterisk-users mailing list > To UNSUBSCRIBE or update options visit: > http://lists.digium.com/mailman/listinfo/asterisk-users >
Earl Terwilliger
2006-Nov-18 10:50 UTC
[asterisk-users] Asterisk Manager: equivalent of 'show channels'?
On Saturday 18 November 2006 13:28, Michael Collins wrote:> I'm interested in knowing if anyone else has worked around this issue: > > > > I have an application that needs to check the status of the calls going > through Asterisk about every 5 seconds or so. I don't want to do > "asterisk -rx 'show channels verbose'" at the Linux command line 12 > times per minute so I am looking at the AMI. I see that there isn't a > manager command for 'show channels.' Has anyone come up with an > equivalent of 'show channels' using the extant manager commands? If so, > could you post how you did it? > > > > Thanks! > > -MCAn approach i take with my event monitor is to have a manager application register for all events, then when something in asterisk happens you get an event record. No need to 'poll' to check. Then you can easily determine what is going on. http://micpc.com/eventmonitor uses the event records to display the state of phones, channels, etc. 'realtime' with AJAX without polling. earl
Richard Lyman
2006-Nov-18 10:58 UTC
[asterisk-users] Asterisk Manager: equivalent of 'show channels'?
Michael Collins wrote:> I?m interested in knowing if anyone else has worked around this issue: > > I have an application that needs to check the status of the calls > going through Asterisk about every 5 seconds or so. I don?t want to do > ?asterisk ?rx ?show channels verbose?? at the Linux command line 12 > times per minute so I am looking at the AMI. I see that there isn?t a > manager command for ?show channels.? Has anyone come up with an > equivalent of ?show channels? using the extant manager commands? If > so, could you post how you did it? > > Thanks! > > -MC >you need to look again maybe read, http://www.dynx.net/ASTERISK/DOCS/RTF/MANAGER.RTF action: command command: show channels Response: Follows Privilege: Command Channel Location State Application(Data) 0 active channels 0 active calls --END COMMAND-- goodluck
Tim Panton
2006-Nov-20 03:41 UTC
[asterisk-users] Asterisk Manager: equivalent of 'show channels'?
On 18 Nov 2006, at 17:28, Michael Collins wrote:> I?m interested in knowing if anyone else has worked around this issue: > > > > I have an application that needs to check the status of the calls > going through Asterisk about every 5 seconds or so. I don?t want > to do ?asterisk ?rx ?show channels verbose?? at the Linux command > line 12 times per minute so I am looking at the AMI. I see that > there isn?t a manager command for ?show channels.? Has anyone come > up with an equivalent of ?show channels? using the extant manager > commands? If so, could you post how you did it?I'm thinking of building an SNMP based monitor for asterisk - What level of data would you want displayed ? I was thinking of having a per-host overview with: Loadaverage Total in-use channels uptime Then a more detailed breakdown (in a pop-up) giving details of the channel technologies etc. And perhaps a final level allowing inspection of individual calls. Have I missed out any vital measures ? Bandwidth used perhaps ? Tim Panton www.mexuar.net www.westhawk.co.uk