<html><head><style type='text/css'>p { margin: 0; }</style><style type='text/css'>body { font-family: 'Times New Roman'; font-size: 12pt; color: #000000}</style></head><body>You guys think YOU'RE overdoing it... your solution works with a single line. My solution was some convoluted 100 line shell script!<br><br>Tim Nelson<br>Systems/Network Support<br>Rockbochs Inc.<br>(218)727-4332 x105<br><br>----- "Lenz Emilitri" <lenz.loway@gmail.com> wrote:
<br>> <p>I have a feeling we're overdoing it :)</p><p>l.<br>> </p><br>> <div class="gmail_quote">2009/2/12 Lukas Rypl <span dir="ltr"><<a href="mailto:rypl@marconi.ttc.cz" target="_blank">rypl@marconi.ttc.cz</a>></span><br>> <blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div class="Ih2E3d"><br>>
> asterisk -rx "soft hangup $(asterisk -rx 'core show channels' | grep SIP/7000<br>>
<br>>
<br>>
</div> Hi,<br>>
<br>>
I used this way of processing output from asterisk 1.2 and found out<br>>
that it is not 100% safe because there can appear unprintable characters<br>>
in the output. This will cause the following grep command to show<br>>
message similar to "Binary content: matched" instead of expected line.<br>>
<br>>
It is necessary to use "strings -a" to filter output. So your example<br>>
should be:<br>>
<br>>
asterisk -rx 'core show channels' | strings -a | grep SIP/7000<br>>
<br>>
<br>>
<br>>
Hope it helps<br>>
<font color="#888888"><br>>
Lukas<br>>
</font><div><div class="Wj3C7c"><br>>
<br>>
<br>>
_______________________________________________<br>>
-- Bandwidth and Colocation Provided by <a href="http://www.api-digital.com" target="_blank">http://www.api-digital.com</a> --<br>>
<br>>
asterisk-users mailing list<br>>
To UNSUBSCRIBE or update options visit:<br>>
<a href="http://lists.digium.com/mailman/listinfo/asterisk-users" target="_blank">http://lists.digium.com/mailman/listinfo/asterisk-users</a><br>>
</div></div></blockquote></div><br>> <br clear="all"><br>> -- <br>> Loway - home of QueueMetrics - <a href="http://queuemetrics.com" target="_blank">http://queuemetrics.com</a><br>>
<br>> _______________________________________________
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users</lenz.loway@gmail.com></body></html>