<?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>MCB Systems &#187; 3cx</title>
	<atom:link href="http://www.mcbsys.com/techblog/tag/3cx/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.mcbsys.com/techblog</link>
	<description>Custom Software and I.T. Services</description>
	<lastBuildDate>Sat, 04 Feb 2012 17:53:10 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Setting Up QoS for 3CX under Windows 7</title>
		<link>http://www.mcbsys.com/techblog/2011/06/setting-up-qos-for-3cx-under-windows-7/</link>
		<comments>http://www.mcbsys.com/techblog/2011/06/setting-up-qos-for-3cx-under-windows-7/#comments</comments>
		<pubDate>Thu, 02 Jun 2011 21:32:42 +0000</pubDate>
		<dc:creator>Mark Berry</dc:creator>
				<category><![CDATA[IT Administration]]></category>
		<category><![CDATA[3cx]]></category>
		<category><![CDATA[qos]]></category>
		<category><![CDATA[voip]]></category>

		<guid isPermaLink="false">http://www.mcbsys.com/techblog/2011/06/setting-up-qos-for-3cx-under-windows-7/</guid>
		<description><![CDATA[As mentioned in the previous post, getting endpoints to apply QoS tagging is only half the battle. We also need the PBX to apply tagging on outbound packets.
  
My current PBX is 3CX version 9, running in a Windows 7 virtual machine. 
I initially planned to use 3CX’s native DSCP tagging capability to apply [...]]]></description>
			<content:encoded><![CDATA[<p>As mentioned in the <a href="http://www.mcbsys.com/techblog/2011/05/basic-qos-setup-on-a-cisco-sg-200-switch/" target="_blank">previous post</a>, getting endpoints to apply QoS tagging is only half the battle. We also need the PBX to apply tagging on outbound packets.</p>
<p>  <span id="more-800"></span>
<p>My current PBX is 3CX version 9, running in a Windows 7 virtual machine. </p>
<p>I initially planned to use 3CX’s native DSCP tagging capability to apply tags. But that didn’t work. According to <a href="http://www.3cx.com/forums/msrtptos-does-not-add-dscp-tags-under-windows-20435.html#p103252" target="_blank">this 3CX forum thread</a>, this is due to a limitation in Windows 7; the QoS API has been “banned.”</p>
<p>The recommendation is to follow <a href="http://www.3cx.com/blog/voip-howto/qos-windows-2008-server-local-policy/" target="_blank">this blog post</a> to set up QoS through Policy. Sure enough, that works fine. I did modify the instructions a bit for my environment:</p>
<ul>
<li>I used Group Policy rather than Local Policy, simply restricting the scope to the virtual machine running 3CX. </li>
<li>To be consistent with my endpoints, I applied DSCP 46 (Expedited Forwarding) rather than 56 as recommended in the blog post. </li>
<li>Rather than set up one policy covering <em>all</em> traffic from the PBX machine, I set up three policies, each one for a different 3CX executable:
<p><strong>3CXMediaServer.exe</strong> covers standard RTP traffic on any port.       <br /><strong>3CXPhoneSystem.exe</strong> generates the SIP traffic (port 5060 by default).      <br /><strong>3CXTunnel.exe</strong> is used when tunneling from a 3CX softphone (port 5090).      </li>
</ul>
<p>My Group Policy looks like this:</p>
<p><a href="http://www.mcbsys.com/techblog/wp-content/uploads/2011/06/3CX-QoS.png"><img style="background-image: none; border-right-width: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px; padding-top: 0px" title="3CX QoS" border="0" alt="3CX QoS" src="http://www.mcbsys.com/techblog/wp-content/uploads/2011/06/3CX-QoS_thumb.png" width="554" height="75" /></a></p>
<p>Now all VoIP traffic inside my network is tagged with DSCP 46.</p>
<p>Next step would be to get calls to and from the VoIP provider to be QoS tagged. Oh, and every Internet switch between me an them to use QoS for prioritizing packets. Yeah, right. At this point, getting QoS to work beyond the firewall seems pretty unlikely for a small business on a standard DSL or cable connection.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.mcbsys.com/techblog/2011/06/setting-up-qos-for-3cx-under-windows-7/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Getting Into VoIP</title>
		<link>http://www.mcbsys.com/techblog/2008/11/getting-into-voip/</link>
		<comments>http://www.mcbsys.com/techblog/2008/11/getting-into-voip/#comments</comments>
		<pubDate>Thu, 06 Nov 2008 10:32:40 +0000</pubDate>
		<dc:creator>Mark Berry</dc:creator>
				<category><![CDATA[IT Administration]]></category>
		<category><![CDATA[3cx]]></category>
		<category><![CDATA[freepbx]]></category>
		<category><![CDATA[pbx]]></category>
		<category><![CDATA[pbx in a flash]]></category>
		<category><![CDATA[piaf]]></category>
		<category><![CDATA[sipx]]></category>
		<category><![CDATA[sipxecs]]></category>
		<category><![CDATA[trixbox]]></category>
		<category><![CDATA[voip]]></category>

		<guid isPermaLink="false">/mark/post/Getting-Into-VoIP.aspx</guid>
		<description><![CDATA[It all started with my new Magicjack. Plug this little gizmo into your PC and you get unlimited domestic calling, $40 for the first year and $20/year thereafter. That&#8217;s hard to pass up. But it also means that I now have three phone lines coming into the home office. So I either needed to get [...]]]></description>
			<content:encoded><![CDATA[<p>It all started with my new <a href="http://www.magicjack.com" target="_blank">Magicjack</a>. Plug this little gizmo into your PC and you get unlimited domestic calling, $40 for the first year and $20/year thereafter. That&#8217;s hard to pass up. But it also means that I now have <em>three</em> phone lines coming into the home office. So I either needed to get a bigger analog phone, or get into a PBX.</p>
<p><span id="more-54"></span></p>
<h1>Requirements</h1>
<p>Here are the things I wanted my PBX system to do:</p>
<ul>
<li>Answer two incoming POTS lines, one business line and one personal line. </li>
<li>Answer the Magicjack line, also as a POTS line. (Unfortunately, Magicjack does not yet allow users to access them as a VoIP provider without the use of the Magicjack hardware.) </li>
<li>Route these three lines to two existing analog phone lines in the house, and eventually to a SIP phone for the home office. </li>
<li>Route outgoing calls based on least cost. In particular, local calls should go out on the personal line (which has unlimited local calling), and long-distance on the Magicjack. &#8220;Local&#8221; in this case is loosely defined as area codes 619 and 858. I only dial 7 digits for 619 phone numbers, but I have to dial 1 + the area code to reach 858 numbers. Ideally least cost could be differentiated more granularly, as some 858 prefixes are probably toll calls and should go out on the Magicjack. </li>
<li>If possible, run in a virtual machine. The host is an old 2 GHz Pentium 4 with 1 GB of memory, running XP Professional. </li>
<li>If possible, cost nothing for software. </li>
<li>Oh yeah:&#160; and deliver crisp, clear audio with no jitter, crackling, drop-outs, echo, or all those other annoying problems that have become so familiar with VoIP. </li>
</ul>
<p>A quick aside for those who want to try this at home:&#160; before doing anything else, I had to modify my existing phone wiring. I basically installed a multi-port phone jack at the point where the phone lines come into the house. The top ports of the jack are the incoming phone lines. The bottom ports feed back out to the existing analog phones. My PBX goes in between.</p>
<h1>Choosing a VoIP PBX</h1>
<p>A couple years ago, I needed to replace a small traditional PBX for a client. It quickly became apparent that a computer-based VoIP PBX would be significantly cheaper than buying a new traditional PBX. I eventually went with <a href="http://www.trixbox.org" target="_blank">Trixbox</a>, and it&#8217;s still working pretty good. </p>
<p>Trixbox is basically a pre-built ISO that installs the CentOS flavor of Linux, then sets up <a href="http://www.freepbx.org" target="_blank">FreePBX</a>, which is based on <a href="http://www.asterisk.org/" target="_blank">Asterisk</a>. Trixbox has since gone commercial. While they still offer a free version, I decided this time to look at <a href="http://www.pbxinaflash.com/" target="_blank">PBX in a Flash</a> (PiaF). PiaF also uses CentOS, FreePBX, and Asterisk.</p>
<p>I&#8217;d seen mention of <a href="http://www.3cx.com" target="_blank">3CX</a> in some forums. Since I mostly use Windows boxes, the idea of a Windows-based PBX is appealing. I decided to look at 3CX.</p>
<p>Somewhere along the way I stumbled across <a href="http://sipx-wiki.calivia.com/index.php/Main_Page" target="_blank">sipXecs</a> and spent some time looking at that as well. I&#8217;ve already <a href="http://blogs.mcbsys.com/mark/post/Testing-sipXecs.aspx" target="_blank">blogged</a> on that so I won&#8217;t spend any more time on that here.</p>
<h1>Trying Out 3CX</h1>
<p>It was pretty easy to get 3CX set up and running in a Windows virtual machine under Microsoft Virtual PC/Server. (That&#8217;s saying a lot compared to the hoops you have to jump through to run a Linux-based PBX in a virtual machine!) And once set up, there&#8217;s a lot to like:</p>
<ul>
<li>Consistent user interface. </li>
<li>Decent documentation on how to set up Analog Terminal Adapters (ATAs) and phones. </li>
<li>Pretty easy to configure. </li>
<li>Caller ID was captured correctly (number only, no name) </li>
<li>Good voice quality, except with the Magicjack, which turned out to be a pretty universal problem. </li>
</ul>
<p>However it didn&#8217;t take long before I started encountering some limitations:</p>
<ul>
<li>Web access to voicemail, and fax service, are only available in the commercial edition. </li>
<li>Voicemails can be sent as email attachments, but the .wav files occupy about 1MB per minute. </li>
<li>Outbound call rules can only be set up based on number length, number starting with, or which extension is making the call. I did not see an obvious way to set up my least-cost dialing rules (although it might be possible to set up area codes with the &#8220;number starting with&#8221; option). My <a href="http://www.3cx.com/forums/how-to-set-up-smart-outbound-rules-7439.html" target="_blank">forum post</a> on the topic yielded no solution. </li>
</ul>
<p>I initially had some other issues, but they were mostly related to the Grandstream HT-503 ATAs that I started testing with. I wound up returning those ATAs when I was unable to get them to reliably deliver Caller ID.</p>
<h1></h1>
<h1>Trying Out PBX in a Flash</h1>
<p>PBX in a Flash (PiaF) has a great <a href="http://www.pbxinaflash.com" target="_blank">web site</a> with loads of documentation and an active forum. PiaF uses <a href="http://www.freepbx.org" target="_blank">FreePBX</a> , which has its own site and forum. FreePBX is built around <a href="http://www.asterisk.org" target="_blank">Asterisk</a>, also with its own site and forum. This multi-level product can be a bit confusing at first, but ultimately it is one of its strengths. It wasn&#8217;t until I looked at sipXecs that I was reminded what it&#8217;s like to deal with &#8220;raw&#8221; open-source software. The great thing about PiaF and FreePBX is that these guys have tested a bunch of different versions of the software plus dozens of add-ons, have found combinations that work, and have created packages that install everything for you automagically (more or less).</p>
<p>Some of the other PiaF/FreePBX pluses:</p>
<ul>
<li>Outbound calling rules are infinitely configurable through a kind of regular expression syntax. FreePBX can even pull in a pre-built list of local phone number prefixes. </li>
<li>The free version includes web access to email and fax service. </li>
<li>Voicemails sent as email attachments are compact&#8211;under 100K per minute. </li>
<li>Voice quality is good except with the Magicjack. </li>
<li>Lots and lots of add-ons are available. I may not need or use most of these, but it is nice to use a platform (Asterisk) that is so widely implemented and enhanced. </li>
</ul>
<p>Of course, PiaF is not without its difficulties:</p>
<ul>
<li>By far the biggest hassle is getting PiaF running well in a virtual machine. More on that in a <a href="http://blogs.mcbsys.com/mark/post/Setting-Up-PBX-in-a-Flash2c-Part-1-Configuring-a-Virtual-Machine.aspx" target="_blank">separate blog post</a>. </li>
<li>The PiaF/FreePBX user interface has improved greatly in the last couple years, but it&#8217;s still clear that PiaF incorporates programs by several different authors:&#160; the &#8220;look and feel&#8221; is not consistent throughout. </li>
<li>You can&#8217;t entirely avoid knowing something about Linux. This could also be listed as a &#8220;plus&#8221; since learning Linux is probably a good thing. But it does make the install more difficult when you need to search Google every time you want to run some simple command (check the IP address of the computer, list files with their sizes, etc.). </li>
</ul>
<h1>General Findings and Moving Forward</h1>
<p>After much testing, I&#8217;ve had to accept that the Magicjack may not work reliably with a VoIP PBX system. It seems that going from a VoIP device to analog and back to VoIP, with all those analog-to-digital transitions, may be too much too ask. I&#8217;ve moved Magicjack compatibility down the priority list. Hopefully Magicjack will eventually support a &#8220;BYOD&#8221; (Bring Your Own Device) solution so I can directly register the Asterisk server with Magicjack as a VoIP provider.</p>
<p>Running a PBX in a virtual machine is indeed a questionable endeavor. 3CX, the Windows-based PBX, seemed to run pretty well in virtual Windows client. But for some reason, getting a Linux-based PBX to run well in a virtual machine is more difficult. I&#8217;ll try running it virtually for a while, but I may wind up installing directly on a physical machine.</p>
<p>Both 3CX and PBX in a Flash have much to recommend them. I&#8217;ve decided to go with PiaF for now. For my own records, I need to document the steps that I took to get it all working. Hopefully by putting the information in a series of posts, it will help some of you out there as well. Here they are:</p>
<p><a href="http://blogs.mcbsys.com/mark/post/Setting-Up-PBX-in-a-Flash2c-Part-1-Configuring-a-Virtual-Machine.aspx">Setting Up PBX in a Flash, Part 1:&#160; Configuring a Virtual Machine</a></p>
<p><a href="http://blogs.mcbsys.com/mark/post/Setting-Up-PBX-in-a-Flash2c-Part-2-Before-Running-FreePBX.aspx">Setting Up PBX in a Flash, Part 2:&#160; Before Running FreePBX</a></p>
</p>
<p> <a href="http://blogs.mcbsys.com/mark/post/Setting-Up-PBX-in-a-Flash2c-Part-3-Configuring-FreePBX.aspx">Setting Up PBX in a Flash, Part 3:&#160; Configuring FreePBX</a>
<p><a href="http://blogs.mcbsys.com/mark/post/Setting-Up-PBX-in-a-Flash2c-Part-4--Configuring-a-Linksys-SPA-3102-ATA.aspx">Setting Up PBX in a Flash, Part 4:&#160; Configuring a Linksys SPA-3102</a></p>
<p><font color="#0000ff">Update 11/24/2008:&#160; I ultimately converted to a physical machine, though the virtual machine was a great test bed and is probably a good alternative for production with the right host. See more </font><a href="http://blogs.mcbsys.com/mark/post/Moving-PBX-in-a-Flash-from-a-Virtual-to-a-Physical-Machine.aspx"><font color="#0000ff">here</font></a><font color="#0000ff">.</font></p>
]]></content:encoded>
			<wfw:commentRss>http://www.mcbsys.com/techblog/2008/11/getting-into-voip/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

