Thursday, June 23, 2011

Using 2talk SIP Provider with Lync

yesterday I posted about using Asterisk with Lync. Today I will share my configuration files for getting 2Talk up and running with the latest version of Asterisk 1.6:
Effectively there are two configuration files you need to worry about. The sip and the extensions files.
The sip.conf file specifies the different sip trunks and authentication mechanisms. The extensions.conf is your dialplan, which can be the trickiest to get working. Below are my versions (passwords removed)


allowoverlap=no ; Disable overlap dialing support. (Default is yes)
udpbindaddr= ; IP address to bind UDP listen socket to ( binds to all)
tcpenable=yes ; Enable server for incoming TCP connections (default is no)
tcpbindaddr= ; IP address for TCP server to bind to ( binds to all interfaces)
srvlookup=yes ; Enable DNS SRV lookups on outbound calls
notifyhold = yes

;register 2Talk number to receive incoming calls (replace placeholders with values, remove brackets)
register =>

[1001] ; A locally attached SIP extension (in my case an X-Lite client)

context=from-2talk ; going to use this in extensions.conf
;allow=g729 ; only if you have licenses to use it
insecure=invite,port ; use insecure=very in earlier versions of Asterisk such as v1.2

[Lync_Trunk] ; Our Lync trunk
port=5068 ; This is the default Lync Server TCP listening port
host= ; This should be the IP address of your Lync Mediation Server





;calls to a 4 digit extension starting with one are routed directly via SIP to local phones
exten => _1XXX,1,Dial(SIP/${EXTEN},20)
exten => _1XXX,2,hangup()

; outbound calls (outside of your own PBX) (only used for internal phones, not calls originating from Lync)
exten => _0.,1,Dial(SIP/${EXTEN:1}@2talk)
exten => _0.,2,hangup()

;calls coming in locally going to a 4 digit number starting with 2 are redirected over the Lync trunk
exten => _2XXX,1,Dial(SIP/Lync_Trunk/${EXTEN},20)
exten => _2XXX,2,hangup()

;dialling other extensions starting with 1 followed by three digits are sent locally

;send other calls to 2talk for Asterisk (no prefix here as Lync will probably have its own dialplan)
exten => _.,1,Dial(SIP/${EXTEN}@2talk)
exten => _.,2,hangup()

;send incoming calls on your 2talk number to a Lync Extension
exten => _X.,1,Dial(SIP/Lync_Trunk/2001)

That's it folks! Try using the two configurations with your 2talk SIP provider, add your own number, secret and Lync IP address and start making and receiving calls over Lync.

Tuesday, June 21, 2011

Using Asteriks with Lync 2010

Next week I am teaching how to install and configure Lync using the material provided in the course10533 from Microsoft. Although the course has some great stuff, it misses out on the really juicy bits. Setting up a PSTN connection for example.
I simply could not resist setting it up for myself. After some digging I found this GREAT! Post by Adam:

But then I need to get my Virtual machines connected to the internet! Now ICS has proven to be rather icky. And Bridging really mucks things up. So in the end only a good ol Routing Service would do the trick.
John Paul has a nice article on how to configure Hyper-V to route traffic to your wireless adapter:

WARNING! Skip the first quarter of the screenshots where he shows bridging. don't wanna do that. jump down to where he starts talking about RRAS

Once I had routing set up and could connect to the net using the private ip-ranges I wanted, I was ready to install Asterisk using Adam's instructions.

Some tips for getting it all running:
No need to buy Skype Plugin if you wanna use sip. I used 2talk and am happy with the results. For the detailled config for 2talk try this page:

IK found a mix between the settings from Adam and the ones from 2talk worked best.

WARNING! A typo or bad rule can send your Asterisk server into an endless crash loop. To fix that, copy the 2talk configurations back into the files and start over again.

Some helping commands I used along the way on the Linux box:
ifconfig (set a new IP address)
route (add a default route to connect to Gateway)
ping (test ip connectivity)
nslookup (test dns server connectivity)
ifconfig and route take effect immediately on the linux box. The changes made via the network setup program only come to life on the next reboot (which took about 5-10 minutes each time)
asterisk -r (connect to asterisk console)
  reload (reload all configs)
  diaplan reload (reload only the dialplan)
  sip show peers (see what routes are setup and working)

And as I hate using the command line editor, downlad a browser/editor for Windows ASAP, such as WinSCP:
You will need that editor to edit the /etc/asterisk/sip.conf and /etc/asterisk/extensions.conf files

Whenever you make a change to sip.conf or extensions.conf make sure to run the reload command in asterisk again.
Also, staying logged in to Asterisk will show what is going on and is useful when debugging conversation attempts.
Finally, try getting it working step by step.
1) connect X-Lite to SIP provider via Asterisk
2) connect X-Lite to Lync
3) connect Lync to X-Lite
4) connect Lync to SIP provider
Step 1 should be your priority. Once that works the rest falls into place.

Happy configuring. Having it all working is an exhilerating feeling. you'll know what I mean once you have made your first Lync phone call to a real land line.

Monday, June 13, 2011

Hierarchies inspired by Tube Maps

One of the probably most famous and useful navigation resource is the London Underground map. It is truly a masterpiece of navigational aid and has hardly changed since its inception. When reviewing the different possible ways to map out a navigation I came across Patrick Walsh's post :

There he describes a process of using Visio to create a tube map like representation of an intranet. A sample could look as such:

Using interconnections, call-outs and differently coloured lines it now becomes easier to show the different paths a user could take through the system, how the navigation nodes relate to each other and where cross linking is used to help navigation.

Also it should become easier to add lots more links onto a page while keeping it printable and overviewable.

Donna Maurer ( has already found the benefits of adding actualt data to a visio diagram, which makes updating th diagrams with new titles or descriptions a breeze. As datasource you can use either a excel file, Access database or even a SharePoint list!

A few tips for when you are working your way through connecting data to your shapes:
1) call the field which contains the url to the page Url. That way visio will automatically link the whole shape. You can rename a field in Visio, no need to fix the source.
2) create custom representations for your data using the Data Graphics button on the Visio 2010 ribbon.
3) create four different options, one for title above, one for below and one for each side. Changing one option will change all instances of that option. Thus, you will need to create four separate ones.

I'll be handing out samples of the visio I used to create a map at my IA course in Wellington which you can use straight away to build your own metro sitemaps!

Saturday, June 4, 2011

Introduction to SharePoint Information Architecture

It is my pleasure to announce the newest course offering by Equinox in Wellington:
I've teamed up with Equinox to deliver three SharePoint Information Architecture courses in Wellington. A one day introduction which covers the basics of IA as well as the basics of SharePoint. A two day course which then goes into the depths of creating taxonomies and hierarchies in SharePoint which can withstand the test of time. Finishing off with an advanced course which covers records management, governance, scalability and other advanced concepts over another two days.
I've been spending many hours online and in libraries prepping the contents of the introduction course and while I will be demystifing some SharePoint myths during the course I also am looking forward to the interactive sessions with the students. IA simply is not something you can learn by listening to speeches or watching viedos. It really only sinks in when you do it for real, so expect some fun and enlightening hands on session to drive home the concepts learnt!

We'll be running the course on June 22nd. Places are limited; so make sure you book your place soon to avoid disappointment!

Expired Virtual Machines for 10232

Thank God, Microsoft Learning is fixing the date issue on the 10232 virtual machines. Looks like this time they didn't get away with "it is not broken, it is by design". So if you are planning on teaching Advanced SharePoint Development techniques any time soon, then make sure to get your hands on the newest images. They should be online within the next week or so.
Btw, 10232 is full of theory and "best practice" concepts. Great for solution architects, team leads and senior developers. Not really the stuff junior SharePoint developers are keen on. They just want to get their hands dirty coding WebParts.
Also, encourage the client to send their newbie SharePoint developers onto 10174 first before visiting any of the advanced courses. Although it is an admin focussed course it covers all the essentials which a developer needs to know about.