Google Voice, Asterisk, Motif

I had some free time after a business trip to test out the motif channel driver which although not a new concept is supposed to work much better with the Google Voice/Talk Jabber/XMPP protocols.

My previous setup involved something of the following:

Main Number @ Google Voice -> Calls DID @ FlowRoute <- SIP CSIPSimple on Android Registers to FlowRoute
Voicemail & SMS hit Google Voice.
Voice calls hit Google Voice and redirect to FlowRoute.

This worked quite well, except two things.

First, people would call my Google Voice number and hear two to three rings before it even started ringing my FlowRoute number. This would throw off the number of rings my phone would receive before transferring the caller to the Google Voicemail.

Second, using Google Voice this way caused about a two to three second delay (time to transfer my voice to the other end so the conversation was always lagging behind and not flowing nicely) and sometimes had a slight, maybe 200ms, jitter (speeding up and slowing down of packets making the voice choppy and other anomalies).

I setup another VPS at my provider and installed the AsteriskNOW distribution. I previously tested AsteriskNOW, Elastix, and the FreePBX Distro on my ESXi setup to find the one I wanted. The Elastix distro I downloaded did not have Asterisk 11 so I could not use the motif channel driver (which was the point of this project), FreePBX Distro worked nicely but had lots of things I would never use installed using more memory. I ended up going with AsteriskNOW because it does not have all the extras installed, enabled and running from the start, and used less memory.


I first opened Asterisk Advanced settings and changed the extension/user mode from `device` to `extensionanduser` so to add some extra little security.

Motif was enabled by default on AsteriskNOW so I just did the setup, verified the trunk, checked the outgoing route, created an incoming route, created an extension (device) and then created a user that was bound to that device, and registered CSIPSimple on my Android to the server. Test call went through instantly.

I then logged into the server using SSH and created a new user, gave them sudo privileges, changed SSH to listen on non-standard port, locked out root from logging in via SSH, and then setup Fail2Ban.

I also setup iptables on the server to only allow web admin from my home location (which I can VPN into if necessary), block all ports except the very few Asterisk needs to run.

By |May 29th, 2013|Categories: General|Tags: , , , , |0 Comments

Google Voice forward to Asterisk PBX

I recently started at a new place of employment and wanted to port my cell number over from Sprint which my old employer used. This was okay with them so I ended up porting the number to my Google Voice account. I wanted to forward it to a new DID that I would get