In the last 12 months I have learned how to set up and manage a Lync 2013 environment. I completed a complex migration path starting from OCS 2007 R1. There have been many challenges that I need to deal with and starting with this post I will share my journey and experience so far.
Setting up PSTN connectivity has been one my first wishes after my Lync 2013 standard edition pool has been running. Finally last week I was able to setup a SIP trunk connecting to and from Avaya IP Office and Lync.
Most import pre-requisite is to run latest IP Office firmware release. I am running R9 on my IP Office 500v2. On the web I tried to find some help how this SIP trunk could be established; unfortunately I didn’t find any post that guided me through the whole process. I am publishing my setup and I hope others will have find their way easier than I did.
My objective
- Establish direct SIP path without additional proxy
- Forward a PSTN extension to Lync so Conference bridge can be reached from outside
- Allow Lync user to dial outside to PSTN
- Allow IP Office user reach a Lync extension
My environment
- Lync 2013 Standard Edition server running as virtual machine
- Lync 2013 Edge server running as virtual machine (not needed for SIP trunk)
- Managed IP VPN network with classes of service for QoS
- No firewall between IP Office and Lync front end server
- Avaya IP Office 500v2 with R9 firmware
- SIP trunking license for 10 channels
- Lync enabled user with Enterprise Voice feature
Before you start make sure that mediation server has been configured to listen on TCP port 5060. I also needed to adjust the Windows Firewall as this TCP 5060 port is not enabled by default.
Step 1 IP Office configuration
IP Office firmware
IP Office 500 v2 with 9.0.3.16 build 2 firmware
SIP Licenses
Make sure to have SIP Trunk Channel license. I have 10 channels in total.
System configuration
Make sure SIP Trunks Enable is checked.
System / LAN1 / VoIP
SIP Trunks Enable: checked
Create new SIP line
SIP line
I am creating new SIP line with line number 18.
ITSP Domain: Networknet.nl
National Prefix: empty
International Prefix: empty
Check OOS: unchecked
All other options should be kept default when line is created.
Transport
ITSP Proxy Address: 192.168.200.9 (IP address of the Lync Mediation server)
Layer 4 Protocol: TCP
Send Port: 5060
Listen Port: 5060
SIP URI
Create channel 1
Local URI: *
Contact: *
Display Name: *
PAI: None
Registration: 0: <None>
Incoming Group: 1
Outgoing Group: 18
Create channel 2
Local URI: Use Internal Data
Contact: Use Internal Data
Display Name: Use Internal Data
PAI: None
Registration: 0: <None>
Incoming Group: 0
Outgoing Group: 21
VoIP
Custom codec is selected for G.711 ALAW 64K. That’s it. The SIP line configuration has now been completed.
Create new ASR route
Any URI with Networknet.nl will go through Dial feature and line group 21 this is outgoing group channel for the SIP trunk to Lync server.
Code: N;
Telephone Number: N”@networknet.nl”
Feature: Dial
Line Group ID: 21
Create new short dial for outgoing traffic to Lync SIP trunk
New short code is needed to reach any Enterprise Voice enabled users or to a Dial-In Access Number. I am sending this traffic over the ASR group that I created with 54 ID.
Code: *5962XXX (*LYNCEXTENSION)
Feature: Dial
Telephone Number: N
Line Group ID: 54: Lync
Configuration for IP office is basically done. One tweak I implemented in addition is to add additional ASR codes for my main route:
Any Lync calling number that was entering IP Office added two additional zeros (00). This way I didn’t need to implement any further configuration on IP Office and kept the configuration lean by removing them at my Main ASR route.
Step 2 Lync Server configuration
Make sure TCP and port 5060 range is set for Lync Meditation server.
Now I will create new PSTN gateway from Lync Topology builder to my IP office
Create new IP/PSTN gateway
FQDN: ipo.networknet.local
Make sure that IP Office has been registered with an HOST A record for DNS
Enable IPv4
Trunk name: ipo.networknet.local
Listening port of IP/PSTN gateway: 5060
SIP Transport Protocol: TCP
Associated Mediation Server: Lync-01.Networknet.Local
Associated Mediation Server port: 5060
SIP trunk is created and I updated my Lync Topology that is ready for publishing.
Voice Routing
One of great things I learned some months ago when going to a Microsoft Lync Enterprise Voice training is the following website. https://www.lyncoptimizer.com/ has optimized set of dialing rules for 80 countries that will work with Microsoft Lync Server 2010/2013. It helped me to start with a working Voice Routing configuration. At first I couldn’t figure out where to start and after the rules were created I got better understanding how voice policies work.
I run the script on my Lync server by selecting my Networknet site and creating user-level dial plan.
After the script finished I refreshed Lync Control Panel. It created new Dial Plan and defined required normalization rules for calling out to +31 PSTN network
Pretty cool! Saves a lot of work and worked for me immediately without need to troubleshoot from Lync server side.
The script associated my IP Office trunk with a route. In screenshot below you can see the +316 pattern for mobile network
After running the voice routing test I could confirm everything was setup.
I used my Lync client and I could dial out through my new configured SIP trunk. My mobile phone was ringing.
This is an example mobile number :). Sure it worked with my own.
Another cool command to verify PSTN connectivity is Test-CsPstnOutboundCall
Test-CsPstnOutboundCall -TargetFqdn lync-01.networknet.local -UserSipAddress sip:[email protected] -TargetPstnPhoneNumber “+31612345678”
Result is Success! And my mobile was ringing.
That’s it. In other posts I will publish my steps how to setup Dial-In conferencing bridge and how to troubleshoot SIP communication between IP Office and Lync. Use IP Office – Monitor tool to troubleshoot and analyze any problems with your own SIP trunk. Each environment has it’s own parameters at Lync and IP office side. Monitor tool helped me to understand what was going on and why certain things didn’t work. Log and analyze why certain calls work and see what happens when trying to reach IP Office from Lync server.
I hope this will help those that trying to find to get this working. Let me know what you think and leave a short comment.
telly
Hello, i am using a Neogate TG200 GSM SIP Gateway which is different to an Lync,i realy want to know how to make work with an AVAYA Ip Office .
Any suggestion !
Thanks !
Vahid
Thanks for the information,
you mention that you are making line 18 but in "SIP URI " you used incoming 1 and outgoing 18 for channel 1 and for channel 2 used in 0 and out 21!