<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>NetworksAreMadeOfString &#187; VOIP</title>
	<atom:link href="http://blog.networksaremadeofstring.co.uk/category/voip/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.networksaremadeofstring.co.uk</link>
	<description>Cat5, Cat6, Fibre, or String.............</description>
	<lastBuildDate>Wed, 25 Jan 2012 12:55:30 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
		<item>
		<title>Simple Asterisk Monitoring Script</title>
		<link>http://blog.networksaremadeofstring.co.uk/2008/09/09/simple-asterisk-monitoring-script/</link>
		<comments>http://blog.networksaremadeofstring.co.uk/2008/09/09/simple-asterisk-monitoring-script/#comments</comments>
		<pubDate>Tue, 09 Sep 2008 20:41:53 +0000</pubDate>
		<dc:creator>Gareth Llewellyn</dc:creator>
				<category><![CDATA[Asterisk]]></category>
		<category><![CDATA[NAMOS]]></category>
		<category><![CDATA[VOIP]]></category>

		<guid isPermaLink="false">http://blog.networksaremadeofstring.co.uk/?p=182</guid>
		<description><![CDATA[There was a post today on the Asterisk Users mailing list about needing a simple way to monitor if your Asterisk lines are working ok. As it turns out I had such a script in my little store of doom. So just in case the Asterisk Users post doesn&#8217;t get archived here it is: &#60;pre> [...]]]></description>
			<content:encoded><![CDATA[<p>There was a post today on the Asterisk Users mailing list about needing a simple way to monitor if your Asterisk lines are working ok. </p>
<p>As it turns out I had such a script in my little store of doom. So just in case the Asterisk Users post doesn&#8217;t get archived here it is:</p>
<p><code><br />
&lt;pre><br />
&lt;?<br />
        ///////////////////////////////////////////////////<br />
        // This is a quick script that allows the external<br />
	// monitoring to check that all is ok.<br />
        //<br />
        // Gareth#NetworksAreMadeOfString.co.uk<br />
        ///////////////////////////////////////////////////<br />
       	$s = stream_socket_client('tcp://127.0.0.1:5038',$e,$es,5);<br />
        if (!$s)<br />
        {<br />
                die('&lt;pre>Error: '.$es.'&lt;/pre>');<br />
        }<br />
        stream_set_timeout($s,2,0);<br />
        fwrite($s,"Action: Command\r\n");<br />
        fwrite($s,"Command: zap show status\r\n");<br />
        fwrite($s,"\r\n");<br />
        $Response="";<br />
        while(!strstr($Response,'END COMMAND'))<br />
        {<br />
                $Chunk = fread($s,512);<br />
                $Response .= $Chunk;<br />
        }<br />
        fclose($s);<br />
        if(stristr($Response,"OK") === FALSE)<br />
        {<br />
                print("Issue detected");<br />
                print("-----");<br />
                print($Response);<br />
        }<br />
        else<br />
        {<br />
                print("Zap Lines OK");<br />
        }<br />
?><br />
&lt;/pre><br />
</code></p>
<p>Pretty simple I think you&#8217;ll agree, hope it helps someone out who doesn&#8217;t feel up to installing Nagios just to make sure the outside line is working!</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.networksaremadeofstring.co.uk/2008/09/09/simple-asterisk-monitoring-script/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Asterisk &#8216;Ring All Phones&#8217; &#8211; One Approach</title>
		<link>http://blog.networksaremadeofstring.co.uk/2007/05/23/asterisk-ring-all-phones-one-approach/</link>
		<comments>http://blog.networksaremadeofstring.co.uk/2007/05/23/asterisk-ring-all-phones-one-approach/#comments</comments>
		<pubDate>Wed, 23 May 2007 11:45:08 +0000</pubDate>
		<dc:creator>Gareth Llewellyn</dc:creator>
				<category><![CDATA[Asterisk]]></category>
		<category><![CDATA[VOIP]]></category>

		<guid isPermaLink="false">http://blog.networksaremadeofstring.co.uk/2007/05/18/asterisk-ring-all-phones-one-approach/</guid>
		<description><![CDATA[When I setup an Asterisk system for my home telephony it was configured so that if the main phone didn&#8217;t pickup after a certain amount of time then Asterisk would proceed to &#8216;call&#8217; all the phones in the house. Yesterday someone enquired as to how this is acheived because there appears to be some confusion [...]]]></description>
			<content:encoded><![CDATA[<p>When I setup an <a href="http://www.asterisk.org/">Asterisk</a> system for my home telephony it was configured so that if the main phone didn&#8217;t pickup after a certain amount of time then Asterisk would proceed to &#8216;call&#8217; all the phones in the house. </p>
<p>Yesterday someone enquired as to how this is acheived because there appears to be some confusion as to how it is done.</p>
<p>Now I make no assertions as to whether this is the best way to do it but it works.</p>
<p><strong>Extensions.conf</strong><br />
<code><br />
[globals]<br />
Office1=SIP/200<br />
LivingRoom=SIP/201<br />
ServerRoom=SIP/202<br />
All=SIP/Office1&#038;SIP/LivingRoom&#038;SIP/ServerRoom<br />
</code></p>
<p>With that done you then simply add the ALL extension to the necessary context</p>
<p><code><br />
[incoming]<br />
exten => 01234,1,NoOp(Incoming call!)<br />
exten => 01234,2,Ringing<br />
exten => 01234,3,Wait(1)<br />
exten => 01234,4,Dial(SIP/Office1,30)<br />
exten => 01234,5,Dial(SIP/All,30)<br />
exten => 01234,6,Playback(tt-weasels)<br />
exten => 01234,7,Hangup<br />
</code></p>
<p>Whilst it is possible to utilise the Dial command in the following way I prefer utilising descriptive names and other variables.</p>
<p><code><br />
exten => 01234,5,Dial(SIP/200&#038;SIP/201&#038;SIP/202,30)<br />
</code></p>
<p>If anyone reads this and knows of another way or considers this particular method to be evil then let me know.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.networksaremadeofstring.co.uk/2007/05/23/asterisk-ring-all-phones-one-approach/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

