81
pdfcrowd.com open in browser PRO version Are you a developer? Try out the HTML to PDF API I'M A UC BLOG my thoughts and experiences in enterprise communications technology… Type text to search here... Home About Tweet Step-by-step Microsoft Lync 2010, Asterisk and Skype installation/integration guide October 9th, 2010 | Tags: Asterisk , Lync 2010, Lync Server 2010, Skype , Skype for Asterisk , Skype for SIP Once a year I give my “blessing” to the wife to go away on a long weekend with the girls and usually I try to call in a few child minding favours from my parents/in-laws and this weekend, thank goodness, is no exception to the rule! Last time I was given these days of peace I wrote a Trixbox/Exchange 2010 integration guide , the emphasis was on this becoming the first in a series of how-to’s – however this never really came to fruition, the reason? Asterisk + friendly UI = Bad bad bad…so from here on in I have chosen to move to AsteriskNOW. Trixbox is a great distribution of Asterisk, however it does break certain Asterisk standards and you can’t beat a good ol’ command line – yes in Asterisk’s case the command line is easier than a web interface. So why not plain old Asterisk? AsteriskNOW makes light work of the install and I’m by no means a Linux guru! You can still opt for the FreePBX front end – but we will choose to not go down this dark path – trust me on this! So let’s talk objectives… 1. Setup AsteriskNOW, configuring a SIP extension and corresponding dial-plan 2. Install and configure Skype for Asterisk (SFA), ensuring the SIP extension above can route in/out (SkypeOut) 3. Take the Lync 2010 Server install performed here and integrate it with AsteriskNOW Make calls to and from the Asterisk SIP extension (Lync & SFA) Make calls to and from the Lync client (SIP & SFA) So here is an idea of how this will all piece together: Resources > My PowerPoint Decks > Nortel Case Study > BlackBerry Case Study > Windows Official Mag Article > Next Hop Articles Recent Posts Lync In-Person Events in 2014 Lync Room System (LRS) account creation in 10 easy steps Deploying Polycom Boss/Admin (now a part of UCS 5.0 Firmware) CX7000 and Room Mailboxes within Office 365 Unable to enable Lync to Skype connectivity (PIC) once split-domain is provisioned within Lync Online Upcoming MUCUGL Events S M T W T F S undefined 2011

Microsoft Lync 2010 Asterisk

Embed Size (px)

Citation preview

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    I'M A UC BLOGmy thoughts and experiences in enterprise communications technology

    Type text to search here...Home About

    Tweet

    Step-by-step Microsoft Lync 2010, Asterisk and Skype installation/integration guideOctober 9th, 2010 | Tags: Asterisk, Lync 2010, Lync Server 2010, Skype, Skype for Asterisk, Skype for SIP

    Once a year I give my blessing to the wife to go away on a long weekend with the girls and usually Itry to call in a few child minding favours from my parents/in-laws and this weekend, thank goodness, isno exception to the rule!

    Last time I was given these days of peace I wrote a Trixbox/Exchange 2010 integration guide, theemphasis was on this becoming the first in a series of how-tos however this never really came tofruition, the reason? Asterisk + friendly UI = Bad bad badso from here on in I have chosen to move toAsteriskNOW.

    Trixbox is a great distribution of Asterisk, however it does break certain Asterisk standards and youcant beat a good ol command line yes in Asterisks case the command line is easier than a webinterface.

    So why not plain old Asterisk? AsteriskNOW makes light work of the install and Im by no means a Linuxguru! You can still opt for the FreePBX front end but we will choose to not go down this dark path trust me on this!

    So lets talk objectives

    1. Setup AsteriskNOW, configuring a SIP extension and corresponding dial-plan2. Install and configure Skype for Asterisk (SFA), ensuring the SIP extension above can route in/out

    (SkypeOut)3. Take the Lync 2010 Server install performed here and integrate it with AsteriskNOW

    Make calls to and from the Asterisk SIP extension (Lync & SFA)Make calls to and from the Lync client (SIP & SFA)

    So here is an idea of how this will all piece together:

    Resources

    > My PowerPoint Decks> Nortel Case Study> BlackBerry Case Study> Windows Official Mag Article> Next Hop Articles

    Recent Posts

    Lync In-Person Events in 2014

    Lync Room System (LRS) accountcreation in 10 easy steps

    Deploying Polycom Boss/Admin (now apart of UCS 5.0 Firmware)

    CX7000 and Room Mailboxes withinOffice 365

    Unable to enable Lync to Skypeconnectivity (PIC) once split-domain isprovisioned within Lync Online

    Upcoming MUCUGL Events

    S M T W T F S undefined 2011

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    Sounds like a tall order right? Wrong. With AsteriskNOW and Lync Server 2010, it is reasonably straightforward and I will endeavour to document the end-to-end setup process.

    Before I begin let me talk about SFA

    Skype as you may or may not be aware offers two SME level VoIP integrations:-

    1. Skype for SIP (now re-branded as Skype Connect) essentially a way of integrating Skypes cloud ofPSTN in/out connectivity including the capability to call Skype users (22.5k online as I type) to an SIPenabled IP PBX for supported vendors see here.

    2. Skype for Asterisk (SFA) an add-on Asterisk channel driver which allows for Skype-to-Skype callsand access to Skypes uber cheap calling rates via your Asterisk end-point.

    If you are already running an Asterisk based PBX you will probably want to know the difference. From ahigh level it comes down to the following:-

    1. Cost Skype Connect is subscription-based, you pay $6.95 per channel plus calling costs not cheapfor those who want to use this for a lab sized implementation.

    2. Functionality SFA is not channel-based, it is user-based, for a one off charge of $66 you get a singleuser license sounds a bit more digestible, right? A single license would give you one channel. In thisguide we will enable a single license be configured to route out from either SIP or Lync end points.From an inbound perspective you could create a Lync response group or Asterisk call group tobroadcast inbound calls to multiple users.

    One (or should i say three?) last caveat before we get on with the good stuff:-

    1. Lync is currently in release candidate, it is unlikely to change on a grand scale, but be aware it is notsupported by Microsoft

    2. Lync (or OCS) + Asterisk integrations are not supported by Microsoft3. This is a just for fun guide or lab setup only

    Okay, with that over with lets look at requirements

    Archives

    January 2014 (2)

    September 2013 (1)

    August 2013 (2)

    July 2013 (1)

    May 2013 (1)

    March 2013 (1)

    February 2013 (1)

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    Okay, with that over with lets look at requirements

    1. Ill be using Windows Server 2008 R2 with Hyper-V to run Lync Server 2010 RC & AsteriskNOW2. I have assigned 2gb of memory to Lync Server 2010 RC and 512mb to AsteriskNOW (I know this

    seems minimal but it is enough for this small test setup)3. Youll need to setup a Skype business account as SFA will not work with regular consumer accounts

    (you can route Skype-to-Skype calls between business and consumer accounts)4. Once you have setup a free Skype business account youll need credit as without credit it wont route

    out to PSTN. I suggest you test the account by adding it to a Skype software client first (if you hit anyroadblocks further down the line youll be pleased to have ruled this potential issue out)

    5. Buy an SFA single channel license which can be purchased directly from Digium, the makers ofAsterisk, via their online store (currently at $66) youll get a licence key that we will activate later

    Lets begin

    Download a copy of AsteriskNOW, I have opted for the 64-bit version here, whilst this is downloading (itis approximately 600mb), lets setup our VM.

    Create a name:

    December 2012 (1)

    November 2012 (1)

    October 2012 (1)

    September 2012 (2)

    August 2012 (2)

    July 2012 (1)

    June 2012 (2)

    May 2012 (2)

    April 2012 (1)

    March 2012 (1)

    February 2012 (2)

    January 2012 (2)

    December 2011 (2)

    November 2011 (2)

    October 2011 (1)

    September 2011 (2)

    August 2011 (2)

    July 2011 (1)

    June 2011 (5)

    May 2011 (7)

    April 2011 (4)

    March 2011 (9)

    February 2011 (5)

    January 2011 (8)

    December 2010 (4)

    November 2010 (4)

    October 2010 (3)

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    Set memory:

    Dont connect it to your virtual network, well need to create a legacy network adaptor as we are usingLinux

    October 2010 (3)

    September 2010 (6)

    August 2010 (5)

    July 2010 (2)

    June 2010 (7)

    May 2010 (6)

    April 2010 (15)

    March 2010 (9)

    February 2010 (5)

    January 2010 (9)

    December 2009 (7)

    November 2009 (14)

    October 2009 (13)

    September 2009 (14)

    August 2009 (54)

    July 2009 (75)

    June 2009 (42)

    May 2009 (50)

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    Im going to accept the default options when configuring my virtual disk (this isnt usually recommendedfor performance, but for AsteriskNOW itll be sufficient)

    April 2009 (15)

    Lync Software Updates Center

    Updates for Lync Server 2013: January

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    Once your bootable AsteriskNOW ISO is downloaded, select this as the operating system to boot fromwithin Hyper-V Manager

    Updates for Lync Server 2013: January2014

    Cumulative updates for Lync Server2010: January 2014

    Cumulative update for Lync 2010:January 2014

    Cumulative updates for Lync PhoneEdition (for Aastra 6721ip and Aastra6725ip): January 2014

    Cumulative updates for Lync PhoneEdition (for HP 4110 and HP 4120):January 2014

    Cumulative updates for Lync PhoneEdition (for Polycom CX500, PolycomCX600, and Polycom CX3000): January2014

    Cumulative updates for Lync PhoneEdition (for Polycom CX700 and LG-Nortel IP Phone 8540): January 2014

    Security Update for Lync 2013:December 2013

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    Our summary, click Finish

    December 2013

    Cumulative updates for Lync for Mac2011: December 2013

    Security update for Lync 2010 Attendee(Administrator level installation):December 2013

    Tags

    Apple Asterisk Avaya / NortelBing BlackBerry bloggingCommunicator DataClassifications Exchange2007 Exchange2010 Google Hyper-ViPhone iPod Laptop Hunters

    Lync 2010 Lync

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    Before we kick off the install, youll need to go to your settings and add one hardware component, thelegacy network adaptor mentioned earlier and make sure this is connected to your virtualnetwork

    Lync 2010 LyncServer 2010 Microhoo!Microsoft Microsoft Retail MUCUGL

    OCS 2007 OCS2007 R2 Office 365 Office2007 Office 2010 Outlook 2007Outlook 2010 PlayStation3 PolycomSecurity Skype Skype for Asterisk

    Speaker TechEd UC Expo UnifiedCommunicationsUser Group Virtualisation VoIP

    Windows 7 WindowsServer Windows Server 2008

    Windows Server 2008 R2Windows Vista

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    Lets start our VM! Fingers-crossed the AsteriskNOW ISO will boot and the install commences, selectoption 5 Asterisk 1.6 only (we need Asterisk 1.6 for TCP support, a SIP trunk requirement for OCS andLync)

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    Select yes, to accept the creation of partitions and wiping of data

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    The default partition scheme is fine, select next. Set your region, select next and create a root (orAdministrator) password then click next.

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    The install will now commence, in my case Im going to grab some breakfast!

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    Im back and the install is complete, eject your ISO via the Hyper-V toolbar, Select Media -> DVDDrive -> Eject. Then click reboot

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    During the boot sequence youll see a ton of text, which will all (hopefully) end with [ OK ]. Uponcompletion you will see a Setup Agent, quit this and you will be presented with the screen below.

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    Login with your root account and start the network configuration utility, type system-config-network. You will then be presented with the screen below

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    Edit your network device eth0 Digital Equipment Corporation DECchip 21140 [FasterNet], removethe DHCP option and set a static address, in my case 192.168.10.30

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    Save and now edit your DNS configuration. In my case I have a local DNS server (192.168.10.253) butset this to suit your needs. I have also set my host name as ast.jacobs.local (jacobs.local is my localdomain name) and set the search to my local domain. Then Save & Quit.

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    Once you are back to the command line type: shutdown r now this will result in a reboot of thesystem. Once the system has completed a restart, login again as root. You should now be able to pingfrom this system to another address on your local network including the Internet (to check this, pingwww.bing.com to ensure internet connectivity is working) if you cant then something has gonewrong! In some cases I have found that you need to head back into the network settings and re-inputthe DNS, this issue shouldnt re-occur.

    Now you are back to your Asterisk command line, type yum install register, youll be prompted todownload the package, accept this by inputting Y and hitting enter. YUM is an abbreviated word forYellow dog Updater Modified, it is a command line package management tool. The Register package isused to activate your SFA license.

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    Next well update our version of AsteriskNOW, type yum update asterisk16, accept the upgradedpackages (as detailed within our previous step)

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    Once completed, well install SFA, type yum install asterisk16-skypeforasterisk, accept the packagedownload. Once installed reboot, type shutdown r now.

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    Once the reboot has completed login and well register the SFA module (using the license key receivedfrom Digium). Login as root and type, register. Select option 1 (Digium Products), then option 7 Skypefor Asterisk. Next you will be prompted to enter you SFA key, enter the key and register now. Click thespace bar to run through the license agreement (does anyone read these?) and accept theagreement. Complete your personal details and your license should be written to/var/lib/asterisk/licenses/ (you should back this up Ill explain this next). But one last reboot first, typeshutdown r now, our Asterisk install is now complete, next well need to configure it!

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    To configure our Asterisk PBX we need to edit a number of text files, there are Linux-based editors, butin my experience they are not that user friendly and I like to perform this remotely using my friendlyWindows PC, to do this you need an SSH client I use WinSCP. Download a free copy via theirwebsite here. Once installed add a new site (see below)

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    Then change the default remote directory (as per the illustration below) and save the site.

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    Once saved click login. The first time you connect you will be prompted to save your Asterisk serverkey, click yes to add the host key to your cache. Finally enter your password, once connected anexplorer type view of your Asterisks file system will be displayed I have changed to a detailed view(choose view -> details)

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    Back-up your SFA license by copying the file from /var/lib/asterisk/licenses there should only beone .lic file in there, just right click and copy to your desktop to save locally. Now head back to thefolder /etc/asterisk this is where our Asterisk config files are located.

    We will be editing three files: (right click and edit within WinSCP)

    1. Sip.conf for main Asterisk settings (trunks/extensions)2. Extensions.conf for dial plans3. Chan_skype.conf SFA settings

    First sip.conf, replace the content of your file with the following settings (you should probably backupyour original conf files before)

    [general]

    context=default ; Default context for incoming calls

    allowoverlap=no ; Disable overlap dialing support. (Default is yes)

    udpbindaddr=0.0.0.0 ; IP address to bind UDP listen socket to (0.0.0.0 binds to all)

    bindport=5060

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    bindaddr=0.0.0.0

    tcpenable=yes ; Enable server for incoming TCP connections (default is no)

    tcpbindaddr=0.0.0.0 ; IP address for TCP server to bind to (0.0.0.0 binds to all interfaces)

    srvlookup=yes ; Enable DNS SRV lookups on outbound calls

    notifyhold = yes ; Notify subscriptions on HOLD state (default: no)

    [1001] ; A locally attached SIP extension

    type=friend

    callerid=1001

    canreinvite=no

    dtmfmode=rfc2833

    mailbox=1001

    disallow=all

    allow=ulaw

    transport=udp

    secret=password

    host=dynamic

    context=default

    [Lync_Trunk] ; Our Lync trunk

    type=friend

    port=5068 ; This is the default Lync Server TCP listening port

    host=192.168.10.29 ; This should be the IP address of your Lync Server

    dtmfmode=rfc2833

    context=from-lync

    qualify=yes

    transport=tcp,udp

    Next extensions.conf, replace the content of your file with the following settings

    [general]

    static=yes

    writeprotect=no

    [globals]

    [default]

    ;dialling other extensions starting with 1 followed by three digits

    exten=>_1XXX,1,Dial(SIP/${EXTEN},20)

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    exten=>_1XXX,n,hangup()

    ;send every digit after 9 to Skype for Asterisk

    exten=>_9.,1,Dial(Skype/${EXTEN:1},20)

    exten=>_9.,n,hangup()

    ;dialling other extensions starting with 2 followed by three digits

    exten=>_2XXX,1,Dial(SIP/Lync_Trunk/${EXTEN},20)

    exten=>_2XXX,n,hangup()

    [from-lync]

    ;dialling other extensions starting with 1 followed by three digits

    exten=>_1XXX,1,Dial(SIP/${EXTEN},20)

    exten=>_1XXX,n,hangup()

    ;send other calls to Skype for Asterisk

    exten=>_.,1,Dial(Skype/${EXTEN},20)

    exten=>_.,n,hangup()

    This dial plan will enable call routing between Lync , Asterisk & SFA. Finally configure yourchan_skype.conf

    You will need to change the default_user to represent your Skype ID, in my case:

    ;default_user=james_bond changed to (general section)

    default_user=imapcblog

    update the password

    ;secret=goldeneye changed to (user section)

    secret=myskypepassword

    change the default context to match your dial plan

    ;context=demo changed to (user section)

    context=default

    route the inbound calls to your Lync extension, in my case 2001

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    ;exten=s changed to (user section)

    exten=2001

    Once you have configured all three config files reboot Asterisk, type shutdown r now. Congratulation,your Asterisk configuration is complete! Next we need to configure Lync and pre-supposing you followedmy previous Lync install guide here, you will need to head back into the Lync Topology Builder wedidnt add a PSTN gateway previously. Download your Topology from the existing deployment andsave the file locally, then add a PSTN gateway (see both steps below)

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    Once you have added the PSTN gateway you will have to re-publish the Topology, this will update theexisting Topology with the new configuration settings, click finish

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    To permit call flow between both Lync and Asterisk worlds we need to define our Voice Routing withinLync Server 2010. Open the Lync Server Control Panel and access the Voice Routing options, wellneed to configure our Dial Plan, Voice Policy, Route and PSTN Usage. I wont walk you through thisconfiguration (some is based upon location preferences, in my case UK), but I will show you theresulting configuration within the Lync Control Panel.

    First the dial plan summary (pay close attention to my normalisation rules) this will route 1xxx toAsterisk, +44xxxxxxxxx to Asterisk and 2xxx internally (treated as local extension)

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    Next the Voice Policy, the default Global Policy should have the following PSTN usage records (theserules will handle our calls destined for Asterisk)

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    and the routes, as follows

    Finally the PSTN usage, as follows

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    In my previous guide we created a test user, that user should now have his or her telephone detailsset, in our scenario tel:2001 (this is not best practice in a production deployment of Lync/OCS, but as alab setup with a single PSTN number we should be given a free pass!) typically in production we wouldassign individual PSTN number and normalise to an internal DDI range i.e. +44208 555 2001 wouldnormalise to 2001 when dialled.

    With these settings committed successfully your setup should be complete, calls can now be madebetween both Asterisk and Lync, to setup a SIP based client I recommend X-Lite (for download andsetup instruction follow my previous guide here)

    Here we can see X-Lite to Lync

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    And the reverse Lync to X-Lite

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    Finally, lets SkypeOut, first from Lync! (this illustration wont mean a lot, but you will have to trust me it works!)

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    Profile

    Thats it, whilst Im sure there are better ways of achieving PSTN breakout from OCS or Lync (withhardware/gateways), there is a certain amount of self-gratification from 100% software based VoIP.

    Im sure my configuration could have been applied in a number of different ways and youll probablynotice that whilst X-Lite will permit Asterisk-to-Skype calls (dial 9 + Skype name), at this time Lync willnot only numbers can be passed (Im happy to take suggestions on this). Otherwise let me know ifyou have spotted any errors or need guidance on issues (Ill be moderating the comments below) andabove all good luck and have some fun!

    Leave a comment | Trackback

    or

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    136 Replies 127 Comments 0 Tweets 0 Facebook 8 Pingbacks

    last reply was october 27, 2012

    Notify me of followup comments via e-mail. You can also subscribe without commenting.

    Name

    Not publishedEmail

    Website

    Comment

    Post It

    [...] This post was mentioned on Twitter by Tom Arbuthnot, Jan S. Andreassenand Mike Pfeiffer, Adam Jacobs. Adam Jacobs said: I'm a UC Blog: Step-by-stepMicrosoft Lync 2010, Asterisk and Skype installation/integration guidehttp://retwt.me/1P8gQ #lync #asterisk [...]

    Great and inspiring article.Just at this week I have talk with client. He wanted to integrate Skype with OCS(Lync).Now I can see the way to do it.

    Tweets that mention Step-by-step Microsoft Lync 2010,Asterisk and Skype installation/integration guide | I'ma UC Blog -- Topsy.com

    October 9, 2010

    Andrey Veselov October 9, 2010

    Arman Obosyan October 10, 2010

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    Thank you, great article!

    [...] Step-by-step Microsoft Lync 2010, Asterisk and Skype installation/integrationguide | Im a UC Blog Posted on October 11, 2010 by johnacookhttp://imaucblog.com/archive/2010/10/09/step-by-step-microsoft-lync-2010-aste [...]

    Nice article. Im currently looking for any Remote Call Control help on Lync.

    @Doug Hi Doug, are you referring to RCC functionality within Asterisk?

    Thanks for this much appreciated!

    Nice job

    Awesome Doug, let me try it and wait for my comments..

    [...] [...]

    Im having some trouble routing calls even between Lync and Asterisk. How do I

    Step-by-step Microsoft Lync 2010, Asterisk and Skypeinstallation/integration guide | Im a UC Blog JCsBlog-O-Gibberish

    October 11, 2010

    Doug October 11, 2010

    Adam [I'm a UC Blog] October 11, 2010

    Deane October 12, 2010

    Khani October 12, 2010

    Diego October 14, 2010

    Asterisk 1.8.0 is released to web | I'm a UC Blog October 23, 2010

    Fredrik October 28, 2010

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    configure the mediation server? I cant route from the Asterix out to skype either itseems, but first things first, the internal route.

    Thank you for your great blog posts BTW!!

    @Fredrik Can you make calls Asterisk ext to ext? Which version of Asterisk are you using?

    Hey there, I am having trouble with the dial in. It answers fine, put in the conf id,thats fine. When it try to join the confernce, it says i cant connect to theconfernce. In the event viewer, all I get is:

    User failed to join the conference.

    Microsoft.Rtc.Collaboration.ConferenceFailureException:The operation failed due toa response from the server. For more information, examine the properties on theexception and inner exception.at Microsoft.Rtc.Signaling.SipAsyncResult`1.ThrowIfFailed()at Microsoft.Rtc.Signaling.Helper.EndAsyncOperation[T](Object owner,IAsyncResult result)at Microsoft.Rtc.Collaboration.McuSession.EndSendCommandInternal(IAsyncResultresult)atMicrosoft.Rtc.Collaboration.AudioVideo.AudioVideoMcuSession.EndTransfer(IAsyncResultresult)at Microsoft.LiveServer.Caa.CaaCall.EndTransfer(IAsyncResult asyncResult,Boolean& retry, Exception& caught)Detected at System.Environment.get_StackTrace()at Microsoft.Rtc.Collaboration.ConferenceFailureException..ctor(String message,Exception innerException)atMicrosoft.Rtc.Collaboration.Conferencing.SendCommandAsyncResult.ProcessCccpResponse(SipMessageDatamessageData, responsetype response, Boolean& isPendingResponse)atMicrosoft.Rtc.Collaboration.Conferencing.SendCommandAsyncResult.ProcessStatusMessage(SipMessageDatastatusMessageData, responsetype response)

    Adam [I'm a UC Blog] October 28, 2010

    Calum MacRawe November 23, 2010

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    atMicrosoft.Rtc.Collaboration.Conferencing.StatusMessageReceivedWorkItem.Process()at Microsoft.Rtc.Signaling.AsyncWorkitemQueue.ProcessItems()at Microsoft.Rtc.Signaling.SerializationQueue`1.ResumeProcessing()at Microsoft.Rtc.Signaling.SerializationQueue`1.ResumeProcessingCallback(Objectstate)atMicrosoft.Rtc.Signaling.QueueWorkItemState.ExecuteWrappedMethod(WaitCallbackmethod, Object state)at System.Threading.ExecutionContext.Run(ExecutionContext executionContext,ContextCallback callback, Object state)atSystem.Threading._ThreadPoolWaitCallback.PerformWaitCallbackInternal(_ThreadPoolWaitCallbacktpWaitCallBack)at System.Threading._ThreadPoolWaitCallback.PerformWaitCallback(Object state)Cause: Administration issues.Resolution:Verify that Conferencing Attendant is installed in a supported topology and thedependant Front End servers are functioning correctly.

    Help please!!!

    Im wondering if I need to include Mediation server into this scenario or just PSTNGateway Please, let me know

    @TreeFox The mediation service is deployed during the install, for PSTN termination agateway or SIP trunking is required.

    Call forwarding and simul ring to PSTN/Asterisk number does not work with thissetup.

    TreeFox November 23, 2010

    Adam [I'm a UC Blog] November 24, 2010

    BlaNon November 30, 2010

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    @BlaNon Actually, just the Asterisk extension.Try forwarding your OCS extension to PSTN or Asterisk extension. If you dial fromthe phone connected to Asterisk to the OCS extension, the call will not beforwarded. OCS sends the INVITE with from=@lyncserver, and Asterisk will notauthorize it, except if you set insecure=invite on the Asterisk extension.There must be a better way tho.

    For me trunk between Asterisk & Lync is not showing UP

    asterisk*CLI> sip show peersName/username Host Dyn Nat ACL Port Status1001/1001 192.168.100.100 D 29082 UnmonitoredLync_Trunk 192.168.100.101 5060 UNREACHABLE2 sip peers [Monitored: 0 online, 1 offline Unmonitored: 1 online, 0 offline]

    I am getting below error for my Lync 2010 RTM trunk. I have configured PSTNgateway with TCP 5060 port without any issues.. I am able to make calls betweenasterisk extensions & as well as in between Lync extension is I am missinganything?????

    [Dec 1 11:11:36] ERROR[3294]: tcptls.c:350 ast_tcptls_client_start: Unable toconnect SIP socket to 192.168.100.101:5060: Connection refused

    Now I am able to get my trunk UP,But not able to make calls in between Asterisk & Lync vice versa

    asterisk*CLI> sip show peersName/username Host Dyn Nat ACL Port Status1001/1001 192.168.100.100 D 51890 Unmonitored1002/1002 192.168.100.102 D 5060 UnmonitoredLync_Trunk 192.168.100.101 5060 OK (2 ms)

    3 sip peers [Monitored: 1 online, 0 offline Unmonitored: 2 online, 0 offline]== Using SIP RTP CoS mark 5 Executing [2001@default:1] Dial(SIP/1001-0000000a,

    BlaNon December 1, 2010

    Johnny December 1, 2010

    Johnny December 1, 2010

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    SIP/Lync_Trunk/2001,20) in new stack== Using SIP RTP CoS mark 5 Called Lync_Trunk/2001 SIP/Lync_Trunk-0000000b is circuit-busy== Everyone is busy/congested at this time (1:0/1/0) Executing [2001@default:2] Hangup(SIP/1001-0000000a, ) in new stack== Spawn extension (default, 2001, 2) exited non-zero on SIP/1001-0000000a

    Getting SIP/Lync_Trunk-0000000b is circuit-busy error

    Can you call out from Lync or Asterisk? Which scenarios work for you?

    @Johnny I noticed an error in my Asterisk SIP.CONF, the default Lync Server TCP listeningport is 5068. Change your port and you should be all good (fingers crossed!)

    Thanks Adam for this Awesome post. Now I am able to make calls from Asterisk toLync extension without any issues. Problem was with my Lync extension telephonenumber previously I used default format (i.e. tel:+2001) that was causing theproblem.. I have changed extension to tel:2001 & it works

    Still I have one issue, I am not able to make calls from Lync extension to Asteriskextension, I am working on it

    I would like if you post more on Lync Dial Plan.. This will help newbies like me

    Cheerssss!!!!!!!!!!!!

    Hi Johnny,

    This is more than likely a dial-plan issue (as correctly identified) did you permitcalls to route to 2xxx extentions via your Lync trunk configuration?

    - Adam

    Adam [I'm a UC Blog] December 1, 2010

    Adam [I'm a UC Blog] December 1, 2010

    Johnny December 2, 2010

    Adam [I'm a UC Blog] December 3, 2010

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    Thanks Adam,

    It works by adding PSTN gateway route for Asterisk extensions.

    Cheerss!!!!!!!

    Adam,

    Much thanks. You got me rolling on Lync. Now to play and really dig in.

    Going to do a little more on your Asterisk integration. Im pretty familiar withAsterisk and FreePBX (trixbox, AsteriskNow, even my own UI). Perhaps we canadd a little more on that config. to a real world scenario for those using FreePBX.Should be able to get some alone time in a week or so.

    Hi Adam, Im glad you have picked up Lync! If you have anything youd like tocontibute please let me know happy to run a special guest article

    All the best, another Adam

    @Adam

    Adam,

    This is almost exactly what im looking to do and as a proff of concept was able toget things working with this. However we currently have a decent sized asteriskimplementaion that hooks to the pstn. I want to hook things in to make mymigration seemless but all the articles ive seen say rip out all that is in the cfg filesright now.

    Do you or anyone else have some guidance on how to integrate lync into anexisting asterisk deployment?

    Hi Jim,

    Johnny December 8, 2010

    Adam December 12, 2010

    Adam [I'm a UC Blog] December 12, 2010

    Jim December 13, 2010

    Adam [I'm a UC Blog] December 13, 2010

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    You may be able to take elements of my code and merge with your existing config(taking into account changes to suit your environment). Is there a specific areaswhere you are struggling?

    - Adam

    Hello,

    i geht the same errorERROR[31807]: tcptls.c:367 ast_tcptls_client_start: Unable to connect SIP socketto 172.16.1.155:5068: Connection refused

    but if i make telnet 172.16.1.155 5068 (to my Lync Server)i get the following messageTrying 172.16.1.155telnet: Unable to connect to remote host: Connection refused

    can anybody help me ?

    Adam,

    Im setting up Lync in our test environment. I dont have my SIP trunk yet, but dohave enterprise voice enabled. I have X-Lite 4 downloaded but cannot get it toconnect to the Lync server. A sniffer shows X-Lite trying to connect to port 5060as expected, but when I go to my Lync server, Netstat shows that it is notlistening on port 5060? Did I miss a step in installation/setup? I have no devicesdefined in the Clients tab.

    Also could you share a screenshot of your X-Lite account setup page so that I cancheck my syntax?

    Thanks for your help and for a great article.

    Bryan Hunt

    Hi Bryan, you cant connect the x-lite client to Lync (only the Lync client can beused here) configure it to point to the Asterisk server.

    Goofy December 16, 2010

    Bryan Hunt December 16, 2010

    Adam [I'm a UC Blog] December 16, 2010

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    - Adam

    Hi Goofy, is the firewall running on the server? Are all the Lync services running?

    - Adam

    Thanks for the response Adam. The Lync client is working perfectly.

    Does this imply that MS plans for Lync to be a somewhat closed platform as faras SIP devices go? In other words, only phones and soft clients with firmwaredesigned specifically for Lync will be able to connect to it? Not all devices thatspeak SIP?

    Thanks.

    Bryan Hunt

    @Bryan Hunt Glad to hear it is working Bryan!

    Now onto your excellent question, OCS/Lync does utilise SIP, but as with mostmajor telephony vendors it has been enhanced to include product specificfunctionality as such device firmware needs to support the OCS or Lync SIPspecification. Typically these devices will only work with these Microsoft products,however there are signs of change one example are Snoms IP Phones, thesehave dual firmware support. See here for more information.

    I hope this helps?

    - Adam

    Hi Adam, have you perhaps experiences that PSTN Media Gateways for HomeOffice and are available and working with Lync? Audiocodes and Ferrari SBAs areout of the question. These are too expensive for me just for testing @ home. Alsoa matching card from Divacom (for example Diva BRI-2 PCI v2, Diva V-BRI-2 PCI

    Adam [I'm a UC Blog] December 16, 2010

    Bryan Hunt December 17, 2010

    Adam [I'm a UC Blog] December 17, 2010

    Ralf December 19, 2010

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    v2) eliminated for cost reasons.

    Thanks for suggestions,

    Ralf

    Hi Ralf,

    I am playing around with an AudioCodes MediaPack 114 gateway (chances are I willprobably upload config guides in due course) this device isnt what I would callexpensive approximately 250?

    - Adam

    Thank you Adam for the tip with the small audio codes device and of course a bigcompliment for your How-Tos on this Site. Thanks especially for the Lync AsteriskHowto.

    Ralf

    @Johnny

    Hi Adam!

    Where do I add the PSTN gateway route for Asterisk extensions?

    ThanksChris

    Chris :@Johnny Hi Adam!Where do I add the PSTN gateway route for Asterisk extensions?ThanksChris

    Solved On Lync Server under Voice Routing -> Route -> Add Associatedgateways

    Adam [I'm a UC Blog] December 19, 2010

    Ralf December 20, 2010

    Chris December 22, 2010

    Chris December 22, 2010

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    I just implemented this for OCS 2007r2, and, after a few modifications, it workslike a charm!

    When I bring up the Lync Control Panel, under Topology, what should my AsteriskPBX status be listed as?

    Right now I am able to communicate internally between Lync Clients and Tanguaydesk phones, but I seem to be having some troubles integrating Asterisk.

    I currently use PBX-In-A-Flash for my Asterisk needs. It is Asterisk v1.8 withFreePBX v2.8.

    I changed the dial plan to the following (since I live in North America, and myAsterisk extensions are in the 7xx range):http://img24.imageshack.us/img24/500/18534005.jpg

    Right now when I try to call externally through my Tanguay phone I get a Callunsuccessful. Cannot complete the call due to restrictions on your account error.

    And when I try to call through the Lync Client I get this:http://img443.imageshack.us/img443/540/captureodf.jpg

    Not sure where to start in troubleshooting this problem.

    Any help would be appreciated.

    Thanks.

    Hi Wayne,

    First things first is there a SIP trunk successfully established betweenLync/Asterisk? In Asterisk you can check this via the CLI on Lync the serverevent log will report trunk related errors. Also ensure your PBXIAF is set to allowTCP this is not enabled by default.

    Let me know how you get on.

    - Adam

    Michael December 22, 2010

    Wayne December 24, 2010

    Adam [I'm a UC Blog] December 24, 2010

    JOhnny December 29, 2010

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    Hi Adam,

    I am using Linksys 3102 as my asterisk gateway to make outgoing calls to externalworld.. I am able to make calls in between asterisk & Lync extension vice versawithout any issue.Also I am able dial outside numbers i.e. local mobile number from my asteriskextension by dialing 8 then local mobile number & phones .. But i am not able todial 8 + local mobile number/phone number via Lync clientI have addedd requiredroute on lync control panel..is I am missing anything?

    thanks in advance..

    Cheers!!!!

    Hi Johnny,

    There a number of ways this can be achieved, my lab setup was configured toautomatically prefix Lync PSTN routes with 9 as per my config this will route viaSFA. I hope this helps?

    - Adam

    @Calum MacRawe did you ever get this figured outIm having the exact sameissue on the final release of Lync.

    Calum MacRawe :Hey there, I am having trouble with the dial in. It answers fine,put in the conf id, thats fine. When it try to join the confernce, it says i cantconnect to the confernce. In the event viewer, all I get is:User failed to join the conference.Microsoft.Rtc.Collaboration.ConferenceFailureException:The operation failed due toa response from the server. For more information, examine the properties on theexception and inner exception.at Microsoft.Rtc.Signaling.SipAsyncResult`1.ThrowIfFailed()at Microsoft.Rtc.Signaling.Helper.EndAsyncOperation[T](Object owner,IAsyncResult result)at Microsoft.Rtc.Collaboration.McuSession.EndSendCommandInternal(IAsyncResultresult)at

    Adam [I'm a UC Blog] December 31, 2010

    Jeremy January 3, 2011

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    Microsoft.Rtc.Collaboration.AudioVideo.AudioVideoMcuSession.EndTransfer(IAsyncResultresult)at Microsoft.LiveServer.Caa.CaaCall.EndTransfer(IAsyncResult asyncResult,Boolean& retry, Exception& caught)Detected at System.Environment.get_StackTrace()at Microsoft.Rtc.Collaboration.ConferenceFailureException..ctor(String message,Exception innerException)atMicrosoft.Rtc.Collaboration.Conferencing.SendCommandAsyncResult.ProcessCccpResponse(SipMessageDatamessageData, responsetype response, Boolean& isPendingResponse)atMicrosoft.Rtc.Collaboration.Conferencing.SendCommandAsyncResult.ProcessStatusMessage(SipMessageDatastatusMessageData, responsetype response)atMicrosoft.Rtc.Collaboration.Conferencing.StatusMessageReceivedWorkItem.Process()at Microsoft.Rtc.Signaling.AsyncWorkitemQueue.ProcessItems()at Microsoft.Rtc.Signaling.SerializationQueue`1.ResumeProcessing()at Microsoft.Rtc.Signaling.SerializationQueue`1.ResumeProcessingCallback(Objectstate)atMicrosoft.Rtc.Signaling.QueueWorkItemState.ExecuteWrappedMethod(WaitCallbackmethod, Object state)at System.Threading.ExecutionContext.Run(ExecutionContext executionContext,ContextCallback callback, Object state)atSystem.Threading._ThreadPoolWaitCallback.PerformWaitCallbackInternal(_ThreadPoolWaitCallbacktpWaitCallBack)at System.Threading._ThreadPoolWaitCallback.PerformWaitCallback(Object state)Cause: Administration issues.Resolution:Verify that Conferencing Attendant is installed in a supported topology and thedependant Front End servers are functioning correctly.Help please!!!

    @Goofy

    otanger January 4, 2011

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    - firewall is down- Restart Lync Server Mediation service or all Lync service after publishing thetopology- you could be able to telnet your lync server on 5068

    This guide is absolutely awesome. I used your Lync step-by-step guide to get abasic Lync server up and running and Ill probably use this to get some awesomeintegration going.

    Thanks for your feedback!

    Hi adamfirst i want to say this and the previous guide for exchange um are amazing:)the coolest thing i ever saw:)BUT in this guide i just wanted to test lync and asterisk going(no skype)so i did exactly what you said(besides registering skype part)and i just cant get this thing to work:(i cannot dial not from the asterisk and not from lynci get network busy and busy dial tone.do you have any idea what i am missing here:)?(can provide access to my lab if u have time:))Thanks

    Turbomcp :Hi adamfirst i want to say this and the previous guide for exchange umare amazing:)the coolest thing i ever saw:)BUT in this guide i just wanted to testlync and asterisk going(no skype)so i did exactly what you said(besides registeringskype part)and i just cant get this thing to work:(i cannot dial not from theasterisk and not from lynci get network busy and busy dial tone.do you have anyidea what i am missing here:)?(can provide access to my lab if u havetime:))Thanks

    Rosewood January 18, 2011

    Adam [I'm a UC Blog] January 18, 2011

    Turbomcp February 2, 2011

    Turbomcp February 2, 2011

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    small update, i rebooted the lync server and now i can call from lync to asteriskusing 1001but i still cannot dial from asterisk and x-lite to lync, i get busy signal like before

    Hi there, firstly thanks for the feedback!

    Chances are you have issues with your call routing, specifically within Lync. Doesyour Lync enabled user have an extension assigned? When calling what is theerror reported within the Asterisk CLI type asterisk -r on your Asterisk commandline. Let me know how you get on.

    - Adam

    mm,my user name is testand his line uri is tel:2001on the asterisk i dont see any specific error(i think) besides:unable to connect sip socket to 192.168.10.4:5068: network is unreachable.so i checked my lync server(forgot i had to reinstall my asterisk)my subnet is 192.168.25.0255.255.255.0i changed the lync server entry ofcourse to point to my lync server which is192.168.25.4and set all other options and rebooted and still busy signal from x-lite 2001 tolync.is there something else i need to do like register the 2001 number at asterisks(thisis a brand new lab so not the one used for exchange um)

    Turbomcp :mm,my user name is testand his line uri is tel:2001on the asterisk idont see any specific error(i think) besides:unable to connect sip socket to192.168.10.4:5068: network is unreachable.so i checked my lync server(forgot ihad to reinstall my asterisk)my subnet is 192.168.25.0255.255.255.0i changedthe lync server entry ofcourse to point to my lync server which is 192.168.25.4and

    Adam [I'm a UC Blog] February 2, 2011

    Turbomcp February 2, 2011

    Turbomcp February 2, 2011

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    set all other options and rebooted and still busy signal from x-lite 2001 to lync.isthere something else i need to do like register the 2001 number at asterisks(this isa brand new lab so not the one used for exchange um)

    quick question(i know its stupid but still)when im configuring the x-lite phone i configure it to register/login to the asteriskas 1001 right?so when i dial 2001 how does it know to forward that to lync because of the trunkand rule we confiured?another thing:on my lab i only have 2 things under pstn usage and not 4 like your printscreenshowsi have local route and local extensions(both as global)

    now for the weirdest thing:)i added another xp machine with test2 user.duplicated the 1001 to be 1002(so i have 2 locally attachwed extensions)i configured it and logged on and bamthat one works perfect:)how weird is that:)i dial 1001 from lync get to x-lite dial 2002 from x-lite get to 1002:)at this point im clueless as to what the heck is going on with the first user:)

    found it:)i configured user one(test) with topologhy tabstupid i knowanyway when is set this thing to none all is good.Thanks againyour hard work is highly appreciateddaily watcher of this web site:)

    Used this article (which is brilliant by the way) and have got skypeout working fine,however I have got an online number setup on the skype account but having some

    Turbomcp February 2, 2011

    Turbomcp February 2, 2011

    Craig Gauntlett February 21, 2011

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    issues routing the inbound to the lync client.

    Here is what I see in the debug

    [Feb 21 20:13:49] NOTICE[3362]: core.cpp:2146 sfa_call_hangup: ending call Executing [2001@default:1] Dial(Skype/{skype-signin-name}-1f762d98,SIP/Lync_Trunk/2001,20) in new stack== Using SIP RTP CoS mark 5 Called Lync_Trunk/2001 SIP/Lync_Trunk-00000006 is circuit-busy== Everyone is busy/congested at this time (1:0/1/0) Executing [2001@default:2] Hangup(Skype/{skype-signin-name}-1f762d98,) in new stack== Spawn extension (default, 2001, 2) exited non-zero on Skype/{skype-signin-name}-1f762d98

    Any help would be much appreciated!

    @Craig Gauntlett

    Hi Craig, now if you are trying to get assistance on account of your flattery thenyou are going the right way about it!

    First off have you given the extension number 2001 to your Lync client? Next howhave you triggered your trunk, the busy tone usually indicates a trunk/routingissue.

    - Adam

    Dear Adam, I have interesting issue.

    My Setup:Asterisk Lync AudiocodesMPNo direct routes between Asterisk and AudiocodesMP, both configured as voicegate in Lync.

    From Lync I can call extensions on both Asterisk and AudiocodesMP.

    From AudiocodesMP I was not able to call any extensions on Asterisk until iveconfigured New-CSAnalogDevice account in Lync for AudiocodesMP (TEL:+900).

    Adam [I'm a UC Blog] February 21, 2011

    Igor March 16, 2011

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    Now using +900 as CallerID I can call any number from AudiocodesMP. Whencalling +900 from Lync I can reach AudiocodesMP.

    But when I call +900 from Asterisk, always get SIP 404 Not Found error. Whilemonitoring Asterisk SIP log, ive noticed what when I call +900 from Asterisk,Lync is trying to call +900 extension on Asterisk instead of AudiocodesMP.

    Ive tried to create CSAnalogDevice account for Asterisk, when use its TEL:+950us CallerID when I call from Asterisk to TEL:901 (which is routed toAudiocodesMP, but this number is not assigned to any Lync account). This Call isrouted. But in this case im loosing my original Asterisk CallerID and this is notacceptable. Also, call to +900 still fails.

    How can I solve my problems: enable calls from Asterisk to AudiocodesMP thruLync and keep original CallerID?

    Wow Igor, this one threw me a little (lets put it this way I had to get Visio out!)

    Q. For you, why are you not using the AudioCodes as a gateway for Lync andAsterisk? If you took this approach you could establish cross extension capabilityvia a Lync to Asterisk trunk.

    - Adam

    Im currently testing, but is there any way for Asterisk and Lync to share the sameextension? What Id like to accomplish is to ring our existing Asterisk IP deskphone and ring/show the incoming call on the users Lync client, basically asimultaneous ring using the same extension. Cant figure out how to do it or if itseven possible.

    Thanks!

    Would a simultaneous ring to yor Lync extension not achieve this? I dont havethe code to hand, let me know if I am missing something on this?

    Adam [I'm a UC Blog] March 20, 2011

    Billy Bob March 22, 2011

    Adam [I'm a UC Blog] March 22, 2011

    Alex March 24, 2011

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    Does Skype Connect or SFA (described in article) allow two-way audiocommunication between cloud of Lync users and cloud of Skype users?

    What about the same question about messages exchange between that clouds?

    Hi Alex,

    Unfortunately Skype does not allocate cloud-based DIDs, therefore Lync isunable to normalise the calls for Lync-2-Skype purposes (Asterisk can handlenames so this is not an issue here). Potentially you might be able to setup aspeedial within Asterisk and assign a number that could be reached via Lync butthis starts to get complex.

    The biggest win is being able to utilse Skypes PSTN for outbound and for inboundyou can use Skype-in or your Skype ID for other Skype based clients.

    I hope this helps?

    - Adam

    Thanks, Adam,

    Surely, we got an comfortable long distance prices from our provider, so costoptimisation via Skype is not an issue.

    Problem is that users are requiring Skype to talk, chat and use videoconferencewith contragents and to minimise long-distance expenses, but this requires Skypeclient installation and interfere with security policies. Lync 2010 instead, fits thecorporate security, meets all the internal corporate needs, but were stuck withSkype interoperability.

    Potentially, there are number of solutions to integrate Skype and Lync, forexample Skystone and Skystone Video. Will evaluate it.

    Let me know how you get on Alex.

    - Adam

    Adam [I'm a UC Blog] March 24, 2011

    Alex March 25, 2011

    Adam [I'm a UC Blog] March 25, 2011

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    Hi,

    I am trying to set up a test environment (XLite>Asterisk>MS Lync Server 2010>Lync Client) similar to that in this excellent guide,but Im having trouble calling from XLite to the Lync client.

    1. According to wireshark on MS Lync Server, the header checksum of the InternetProtocol in each SIP packet sent by MS Lync Server is 00000.2. Im also getting the following error according to Lync Server Logging Tool,:TL_WARN(TF_COMPONENT) [2]143C.133C::04/04/2011-22:45:37.959.00000746(SIPStack,CSIPRequest::RouteRequestUriOnNonEdgeProxy:SIPRequest.cpp(3441))(0000000006370440 ) User [[email protected]] is not in enterprise or we donot serve this domain using 404TL_WARN(TF_DIAG) [2]143C.133C::04/04/2011-22:45:37.977.00000747(SIPStack,SIPAdminLog::TraceDiagRecord:SIPAdminLog.cpp(145))$$begin_recordLogType: diagnosticSeverity: warningText: Non-trusted source sent an FQDN/IP that doesnt match a routing table ruleResult-Code: 0xc3e93c5e SIPPROXY_E_ROUTINGSIP-Start-Line: INVITE sip:[email protected];user=phone SIP/2.0SIP-Call-ID: 5f803ac8-ece1-47f8-9ac4-0981e5b3b617SIP-CSeq: 57 INVITEData: [email protected]$$end_record

    Any idea what might be causing these problems? Thanks.

    Hi Max,

    Stating the obvious first, have you properly assigned the extension no? Next haveyou looked at the Asterisk logging? Type asterisk -r via the command prompt. Isthe trunk up? (again you can check this via the asterisk command prompt sipshow peers)

    Let me know how you get on?

    - Adam

    Max April 5, 2011

    Adam [I'm a UC Blog] April 6, 2011

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    Hi, thanks for a great guide, just walked through this and got it all working,Thanks!

    The only problem I ran into was that I got no audio from the Skype client to Lync,X-lite -> Lync and mobile (via SkypeIn) -> Lync where fine. The fix I found was toadd the following to to chan_skype.conf in the user section

    allow=ulaw,alaw

    -Stephen.

    I have disabled the firewall on Lync Server now the error is

    Unable to connect SIP socket to 192.168.22.243:5068: Connection refused

    Thanks for posting your workaround Stephen was this not enabled by default?

    - Adam

    Hi Syed,

    Apologies for not getting back to you sooner (I was on vacation) and thanks foryour previous message, given that Windows Firewall is disabled you may want tocheck the ports sometimes there can be some confusion on incoming/listeningports.

    Ild suggest you follow defaults and refer to this TechNet documentation fordefault port definitions.

    - Adam

    [...] for Skype (R.I.P. my Skype-to-Lync integration blog post) okay so it was aworkaround and PIC would be far [...]

    Stephen April 23, 2011

    Syed Gulzar Hussain April 29, 2011

    Adam [I'm a UC Blog] April 29, 2011

    Adam [I'm a UC Blog] May 3, 2011

    Microsoft buys Skype, what could this mean for Lync? |I'm a UC Blog

    May 10, 2011

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    I dont have a Chan_skype.conf file in the asterisk directory. Is this something Ishould create manually?

    Hi David,

    This is usually created when you add SFA is this installed correctly?

    - Adam

    Far as I can tell. I added the License Key for the SFA and that didnt give me anyerrors and it created the License File.

    Id strongly suggest re-installing something has gone wrong. This shoulddefinately be created as a part of the install.

    - Adam

    [...] http://imaucblog.com/archive/2010/10/09/step-by-step-microsoft-lync-2010-asterisk-and-skype-installa [...]

    GREAT POST!!!!!! Thanks to your hard work I got my environment up andrunning. Lync users can call X-Lite. X-Lite users can call Lync. X-Lite users canconnect out via SIP. Lync users can connect out via SIP. All working like a charm.Not that it happened easily. Some changes were required.

    As Im using another SIP provider and not Skype my dial plan looks like this:[general]static=yeswriteprotect=no

    David May 11, 2011

    Adam [I'm a UC Blog] May 11, 2011

    David May 11, 2011

    Adam [I'm a UC Blog] May 11, 2011

    Step-by-step Microsoft Lync 2010, Asterisk and Skypeinstallation/integration guide : Lync Guru

    May 30, 2011

    Alex Dean June 21, 2011

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    [globals]

    [default]

    ;receive incoming calls to a connected phone

    exten => s,1,Dial(SIP/1001)

    ; outbound calls (outside of your own PBX)

    exten => _1XXX,1,Dial(SIP/${EXTEN},20)exten => _1XXX,2,hangup()

    exten => _0.,1,Dial(SIP/${EXTEN:1}@2talk)exten => _0.,2,hangup()

    exten => _2XXX,1,Dial(SIP/Lync_Trunk/${EXTEN},20)exten => _2XXX,2,hangup()

    [from-lync]

    ;dialling other extensions starting with 1 followed by three digitsexten=>_1XXX,1,Dial(SIP/${EXTEN},20)exten=>_1XXX,n,hangup()

    ;send other calls to 2talk for Asteriskexten => _.,1,Dial(SIP/${EXTEN}@2talk)exten => _.,2,hangup()

    This way all calls get routed nicely.

    I found following commands very useful:enter Asterisk: asterisk -rReload all config files: reloadReload only the dial plan: dialplan reload

    rebooting my asterisk server takes AGES. So reloading the configs is much muchfaster. Especially when testing different dial plans.

    Thanks Alex (sorry for not getting back to you sooner), really appreciate yousharing this info for other readers.

    - Adam

    Adam [I'm a UC Blog] July 18, 2011

    Andres July 22, 2011

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    Hi Adam

    Nortel CS1000M/Great post, I will try this on a topology Elastix Cisco\Nortel BCM50

    I guess it will be enough setting up the Lync-Asterisk part, I only have my doubtsin the following:

    1. Is it possible to have trouble using Asterisk 1.8?2. Is there any codec support issue with Lync, like using codec g.729?3. Will this have the same behavior when calling to an Asterisk Queue? because Imusing Elastix call center module and it works based on queues.4. Is there a how-to for connecting Lync Server with Microsoft Dynamics CRM andOutlook?

    If someone has any suggestion on this to be of consideration I will be great full ifyou share before I start deploying. I shall share the results and hopefully goodanswers to all this.

    Thanks again for the great post.

    Andres :Hi AdamNortel CS1000M/Great post, I will try this on a topology Elastix Cisco\Nortel BCM50

    hehe I guess it didnt show up as I meant. I will try this in a topology with Elastixworking with Cisco, Nortel CS1000M and Nortel BCM50. Wish me luck xD

    Hi Andres,

    A1. Asterisk 1.8 is absolutely possible for Lync IntegrationA2. Lync supports g.711 ulaw/alaw (supported by Asterisk too)A3. I have not used Elastix, but I dont see why not?

    Andres July 22, 2011

    Adam [I'm a UC Blog] July 22, 2011

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    A4. So far as I am aware only an OCS -> CRM 4 out of the box integration isavailable at this time, see here

    - Adam

    I am really trying to work through this in my lab. I am running 2008 R2 SP1 Hyper-v server. The Linux Integration Tools do not install at all!

    I can install Centos 5.2 fine but when I get to the integration tools I cannot accessthe command line nor install the tools. Any ideas?

    Hi Bob,

    I didnt need to install the Linux integration tools, sorry.

    - Adam

    Hello Adam pls i will like if u can suggest to me a solution to this i got this fromeventvwr

    The Mediation Server service has received a call that does not support comfortnoise. This event is throttled after 5 calls from a single Gateway peer.

    The Mediation Server service has received a call that does not support comfortnoise from the Gateway peer, 192.168.10.105Cause: The Gateway peer does not support comfort noise.Resolution:Please ensure the comfort noise option on the Gateway has been enabled.

    I cant call from my xlite to lync but i can call from lync to xlite

    Hi Olay,

    The comfort noise issue is unlikely to be the root cause, suggest as a first port ofcall you look into the Asterisk routing error. Access the Asterisk command line andexamine the logging generated wen you try to initiate a call failure. The command

    Bob K August 10, 2011

    Adam [I'm a UC Blog] August 10, 2011

    ojay August 15, 2011

    Adam [I'm a UC Blog] August 15, 2011

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    line can be accessed by typing asterisk -r via the terminal.

    - Adam

    hi AdamsThanks a lot i av gptten the error but what am i to dothe error is tcptls.c 350 ast_tcptls_client_start unable to connect sip socket to192.168.10.20:5060 : no route to host

    Within the Asterisk CLI type sip show peers is your Lync trunk up?

    - Adam

    AdamI type the command but it returns an error (-bash: sip : command not found)

    Hi Ojay,

    Try the Asterisk CLI, this is enabled by typing asterisk -r from your Linuxterminal.

    - Adam

    HI Adam i am so sorry for disturbing you. i can get the sip peers now the trunk isunreachable. pls go through my configuration

    [general]context=default ; Default context for incoming callsallowoverlap=no ; Disable overlap dialing support. (Default is yes)udpbindaddr=0.0.0.0 ; IP address to bind UDP listen socket to (0.0.0.0 binds toall)bindport=5060

    ojay August 16, 2011

    Adam [I'm a UC Blog] August 16, 2011

    ojay August 17, 2011

    Adam [I'm a UC Blog] August 17, 2011

    ojay August 18, 2011

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    bindaddr=0.0.0.0tcpenable=yes ; Enable server for incoming TCP connections (default is no)tcpbindaddr=0.0.0.0 ; IP address for TCP server to bind to (0.0.0.0 binds to allinterfaces)srvlookup=yes ; Enable DNS SRV lookups on outbound callsnotifyhold = yes ; Notify subscriptions on HOLD state (default: no)

    [1001] ; A locally attached SIP extensiontype=friendcallerid=1001canreinvite=nodtmfmode=rfc2833mailbox=1001disallow=allallow=ulawtransport=udpsecret=passwordhost=dynamiccontext=default

    [Lync_Trunk] ; Our Lync trunktype=friendport=5068 ; This is the default Lync Server TCP listening porthost=192.168.10.20 ; This should be the IP address of your Lync Serverdtmfmode=rfc2833context=from-lyncqualify=yestransport=tcp,udp

    Name Host Port StatusLync_trunk 192.168.10.20 5068 unreacheable

    My PSTN GATE is using port 5060My Mediation Tls listening port:5067My Mediation TCP listeneing port:5068

    i even try to change the PSTN gateway port to 5068 all to no avail all i can get is acall from lync to xlite and not the other way round

    Adam [I'm a UC Blog] August 22, 2011

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    Ojay,

    You config looks good, something is stopping your Lync trunk from beingestablished (from the Asterisk to Lync) this is the root cause. Not sure if I haveasked, do you have Windows Firewall enabled, could this be blocking the port?Also is 192.168.10.20 the IP address of your Lync server?

    - Adam

    Here is my issueI have freepbx and OCS 2007r2I just upgraded to Lync in parralelnote my connect-with-OCS trunk works finemy connect-with-Lync trunk for some reason does notI did reset the TCP listener from 5068 to 5060 on Lync and published it andverified ityet when I route from-internal to Connect-with-Lync context I get no loveNo firewalls are on and there on the same subnet.

    If i revert to the working Connect-with-OCS trunk here is what works and whatdoesntand is my real issue.from PBX sip client (PSC) to Lync user (LU) ext to ext work finefrom LU to PSC client ext to ext work finefrom LU to dial out PBX to my mobile phone works fineBLOCKERon the LU i set call forwardingOCS to LU call forwarding works to mobile fineLU to LU call forwarding works to mobile finePSC client then calls LU ext with call forwarding enabledand it rings tries to route and fails.

    So first issue is How do I get Lync to accept traffic from freepbxwhen it has the same settings of my OCS trunks and configsand my context from internal is pointed to the right trunk?

    How do I get Lync to forward calls from a PSC client out tothe public mobile number.

    Should I just revert and try to use port 5068 and see what happens?

    bacmallard August 31, 2011

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    SIP trace on Lync shows the forward traffic happening but my guess isThe routing rules did not result in a final response for PSTN caller and non-UMenabledcallee;source=site1pool.foo.local;[email protected];appName=InboundRouting

    Im just thinking since lync anc ocs calls forward correctly that somehowI have to tell Lync or OCS to look at the PCS client number and that its ok toforward it off.

    Hi Bacmallard,

    Ill be honest you have lost me a little! Nevertheless I would definately suggest yourevert to 5068, I have this configuration setup and working with the default portconfiguration.

    - Adam

    @Bob K

    How I got Hyper-V Integration Tools to work with AsteriskNOW (Hyper-V R2 SP1Host)Download http://www.microsoft.com/download/en/details.aspx?id=24247 andextract .exeMount extraced .iso file in Hyper-V

    *Login as root*yum -y groupinstall Development Toolsyum -y updateyum -y install kernel-devel*Reboot**Login as root*mkdir -p /mnt/cdrommount /dev/cdrom /mnt/cdromcp -rp /mnt/cdrom /opt/linux_icunmount /mnt/cdromcd /opt/linux_ic/make

    Adam [I'm a UC Blog] August 31, 2011

    TiamaT September 9, 2011

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    make install*Reboot**Done*

    Btw: Fantastic article. Now I can finally get some real hands-on experience withEnterprise Voice.

    Adam, just attempted to purchase license for AsteriskNOW and it seems that it isno longer available? Am I missing something on there website?

    BOO!

    Why is Skype for Asterisk no longer available?Skype for Asterisk was developed as a result of an agreement between Digium andSkype to allow distribution of Skype proprietary software. This software enabledAsterisk to make use of proprietary Skype protocols and participate as a nativeclient on the Skype network. Skype decided not to renew this agreement in 2011,so Digium had to cease sales of the product. Skype for Asterisk will be supporteduntil July 26, 2013.

    http://www.digium.com/en/docs/SFA/sfa_faq.php

    Dang it!!!!

    Hi Ben,

    AsteriskNOW is free, download links here

    - Adam

    Error : SIP/Lync_Trunk-00000004 is circuit-busy Please help me.

    Reloading SIP Unregistered SIP 1001 Registered SIP 1001 at 192.168.1.47 port 23436

    Ben September 15, 2011

    Ben September 15, 2011

    Adam [I'm a UC Blog] September 15, 2011

    Bikash September 17, 2011

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    [Sep 17 17:41:37] NOTICE[3195]: chan_sip.c:23658 sip_poke_noanswer: PeerLync_Trunk is now UNREACHABLE! Last qualify: 1[Sep 17 17:41:47] NOTICE[4035]: chan_sip.c:18912 handle_response_peerpoke:Peer Lync_Trunk is now Reachable. (3ms / 2000ms)== Using SIP RTP CoS mark 5 Executing [2861@default:1] Dial(SIP/1001-00000003,SIP/Lync_Trunk/2861,20) in new stack== Using SIP RTP CoS mark 5 Called Lync_Trunk/2861[Sep 17 17:41:48] WARNING[4035]: chan_sip.c:17726 reply_digest: missingDigest.[Sep 17 17:41:48] NOTICE[4035]: chan_sip.c:18451 handle_response_invite:Failed to authenticate on INVITE to 1001 ;tag=as790ee8f5 SIP/Lync_Trunk-00000004 is circuit-busy== Everyone is busy/congested at this time (1:0/1/0) Executing [2861@default:2] Hangup(SIP/1001-00000003, ) in new stack== Spawn extension (default, 2861, 2) exited non-zero on SIP/1001-00000003localhost*CLI>[Sep 17 17:42:51] NOTICE[3195]: chan_sip.c:23658 sip_poke_noanswer: PeerLync_Trunk is now UNREACHABLE! Last qualify: 3[Sep 17 17:43:01] NOTICE[4039]: chan_sip.c:18912 handle_response_peerpoke:Peer Lync_Trunk is now Reachable. (3ms / 2000ms)[Sep 17 17:44:05] NOTICE[3195]: chan_sip.c:23658 sip_poke_noanswer: PeerLync_Trunk is now UNREACHABLE! Last qualify: 3[Sep 17 17:44:15] NOTICE[4042]: chan_sip.c:18912 handle_response_peerpoke:Peer Lync_Trunk is now Reachable. (3ms / 2000ms)[Sep 17 17:45:19] NOTICE[3195]: chan_sip.c:23658 sip_poke_noanswer: PeerLync_Trunk is now UNREACHABLE! Last qualify: 3[Sep 17 17:45:29] NOTICE[4045]: chan_sip.c:18912 handle_response_peerpoke:Peer Lync_Trunk is now Reachable. (3ms / 2000ms)[Sep 17 17:46:33] NOTICE[3195]: chan_sip.c:23658 sip_poke_noanswer: PeerLync_Trunk is now UNREACHABLE! Last qualify: 3localhost*CLI>

    ThanksBikash

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    @ojay I have same problem trunk is unreachable Please help me

    HI Adam i am so sorry for disturbing you. i can get the sip peers now the trunk isunreachable. pls go through my configuration

    [general]context=default ; Default context for incoming callsallowoverlap=no ; Disable overlap dialing support. (Default is yes)udpbindaddr=0.0.0.0 ; IP address to bind UDP listen socket to (0.0.0.0 binds toall)bindport=5060bindaddr=0.0.0.0tcpenable=yes ; Enable server for incoming TCP connections (default is no)tcpbindaddr=0.0.0.0 ; IP address for TCP server to bind to (0.0.0.0 binds to allinterfaces)srvlookup=yes ; Enable DNS SRV lookups on outbound callsnotifyhold = yes ; Notify subscriptions on HOLD state (default: no)

    [1001] ; A locally attached SIP extensiontype=friendcallerid=1001canreinvite=nodtmfmode=rfc2833mailbox=1001disallow=allallow=ulawtransport=udpsecret=passwordhost=dynamiccontext=default

    [Lync_Trunk] ; Our Lync trunktype=friendport=5068 ; This is the default Lync Server TCP listening porthost=192.168.10.20 ; This should be the IP address of your Lync Serverdtmfmode=rfc2833context=from-lync

    Tarun September 17, 2011

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    qualify=yestransport=tcp,udp

    Name Host Port StatusLync_trunk 192.168.10.20 5068 unreacheable

    My PSTN GATE is using port 5060My Mediation Tls listening port:5067My Mediation TCP listeneing port:5068

    i even try to change the PSTN gateway port to 5068 all to no avail all i can get is acall from lync to xlite and not the other way round

    Hi Bikash,

    At a guess you have some sort of connectivity/performance related issueimpacting the Asterisk -> Lync trunk.

    - Adam

    Hi Adam,

    Great site. Have you ever tried this with Sipxecs?

    I setup a gateway to my sipxecs server and a dial plan that routes the calls (with a46 prefix) but I cant connect to the server. The client gets a fast busy. One of theerrors I see in event viewer on the server is There was no response from agateway to an OPTIONS request sent by the Mediataion Server. Any suggestions?

    Thanks for the feedback Mike. I have not played with sipXecs but I know it ispopular, without looking into it is your trunk UP?

    - Adam

    Thanks for reply Now Asteris is Workinf Fine and Also I have configure Elastix GUIfor LYNC.

    Adam [I'm a UC Blog] September 19, 2011

    Mike September 21, 2011

    Adam [I'm a UC Blog] September 23, 2011

    Bikash September 23, 2011

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    ThanksBikash

    Glad to hear it Bikash!

    - Adam

    Hi!Thanks for this great guide.Im totally new to Lync and SIP telephony in general and have just installed Lyncand Asterisk for the first time.

    I followed your tutorial though using another SIP provider and was able to makecalls to PSTN from X-lite client as well as from Lync clients for a while.Then this morning I was not able to enter numbers longer than 7 digits excludingthe national prefix (in my case +46).When entering a number in the Lync client it starts searching the address bookdirectly and I am able to press the call button as long as I enter less than 8 digits.But when I enter the 9th digit nothing happens when I press the call button.Im not sure but it seems like this happend after I entered my phone numbers inthe Lync client configuration. I removed them but the problem persists.

    Does anybody have a clue where to start troubleshooting this? Cause Im clueless.The only thing that differs from your Lync conf is the regexp for national callswhich is ^(\+46\d{7}\d+)$ instead. A typical Swedish mobile phone number is+46734123456.

    Any help would be greatly appreciated.

    Seems like I solved it.Deleted the GalContacts.db and GalContacts.db.idx files and ran reg addHKLM\Software\Policies\Microsoft\Communicator /v GalDownloadInitialDelay /tREG_DWORD /d 0 /f to force a new address book sync. Also ran the Update-CsAddressBook cmd on the Lync server before starting the client again.And now it seems like I can make >8 digits calls again. Have not been able to try it

    Adam [I'm a UC Blog] September 24, 2011

    Nils October 18, 2011

    Nils October 18, 2011

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    since Im on remote with my lab environment.

    Thanks for sharing Nils.

    Incidentally youre doing pretty good considering youre new to both Lync andAsterisk (my guides are obviously working out too!)

    - Adam

    Hello Adam and Nils,

    Can you please let me know the other SIP vendors which I can use to call PSTN.Also please let me know the configuration.

    I am trying to integrate Microsoft Lync 2010 with Trixbox. I have public linepurchased from VoiP operator. I followed guide from this url to configure Trixbox:http://blogs.breezetraining.com.au/mickb/2009/07/31/FinallyConnectedOCS2007R2ToTrixboxAsteriskToAPSTNPBX.aspxI am able to receive call from public network to my Lync client. However I amunable to call from Lync to anybody in outside world.I examined the logs on Lync side. There is and error:Start-Line: SIP/2.0 504 Cannot connect to gateway. Socket error:ConnectionRefusedI also examined logs on Trixbox side with doing: asterisk -r; sip set debug on.When i was placing a call there was no SIP traffic captured on Trixbox server.I did network trace. I noticed that Trixbox is dropping connection from Lync. Lyncsends SYN packet to port 5060 and Trixbox is replying with RST,ACK packet.

    Here is trunk configuration from Trixbox to Lync and vice-versa:[Connect-with-Lync]disallow=allhost=10.48.22.182 ; Lync server IPtype=friendport=5068 ; Lync listening portinsecure=port,invitedtmfmode=rfc2833

    Adam [I'm a UC Blog] October 18, 2011

    Askwizard October 28, 2011

    pawp November 4, 2011

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    qualify=yestransport=tcp,udpcanreinvite=yesallow=ulawcontext=from-lync

    [from-Lync]host=10.48.22.182 ;Lync IPtransport=tcpport=5060 ;Trixbox portinsecure=port,invitetype=friendcontext=from-Lync

    Could you please help?

    If I understand this configuration correctly you have two Trixbox trunks defined(each for calls in/out) this is not neccessary and will confuse things. Id suggestyou create one and configure Lync accordingly.

    - Adam

    skype

    [...]Step-by-step Microsoft Lync 2010, Asterisk and Skype installation/integrationguide | I'm a UC Blog[...]

    @JOhnny hi, My Lync is still showing unreachable on 5060. can help me

    I apologize for perhaps a dumb question here. I am aware that Asterisk basedsolution is about telephony; SIP/IAX/PSTN, etc. Now, Lync, is pure presence/IMplatform. What benefit exactly do I get with integrating the two? If the answer is

    Adam [I'm a UC Blog] November 5, 2011

    skype November 10, 2011

    Collin November 26, 2011

    Jeff November 27, 2011

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    presence of the phone and IMs then I still do not understand, because I can haveOpenFire server on my Asterisk box providing IM/presence for those sameextension via AsteriskIM plugin. Again, please correct me if I am wrong or missingsomething. IF there is a feature I can further enhance my solution, I am open toadditional information. thank you.

    I am using Bria which has integration with Asterisk, Outlook, and containspresence, click to dial, IM features, etc. Whats the purpose of having a hugeproduct like Lync integrated with Asterisk? From ease of deployment, licensingcost, complexity of management, it seems to be an overkill.

    Hi Jeff,

    Lync is whole lot more than just presence and IM, since Office CommunicationsServer 2007 the platform has very much incorporated voice, a/v conferencing andcollaboration. OCS/Lync integration with Asterisk can deliver a number of benefits,such as the leverage of existing Asterisk PSTN break-out. I can also tell you(based upon traffic statistics that there is a very keen interest around 150vistors daily!

    - Adam

    Hi Jordon,

    Asterisk is a great solution and it certainly offers a lot of capability found withinOCS or Lync, Id also hasten to add that it would never be my recommendation todeploy, support and maintain both products within a production environment. Itmay however be of value if you are looking to migrate to Lync or leverage existingservices already available within your existing Asterisk deployment i.e. PSTN break-out.

    Being familiar with both products I will say that you get what you pay for withAsterisk and Lync is now a mature enterprise-ready product with deep integrationwith the Microsoft stack. Of course if you are a start-up business or ContactCentre running Open Source technology, Asterisk will fit right in.

    Jordan Turner November 28, 2011

    Adam [I'm a UC Blog] November 29, 2011

    Adam [I'm a UC Blog] November 29, 2011

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    I hope this helps?

    - Adam

    [...] VoIP & Gadgets Blog, VoIP & Gadgets Blog. I came across an excellent tutorialon installing and integrating Microsoft Lync 2010, Asterisk and Skype. The tutorialcovers [...]

    [...] Integration Tutorial Posted on December 28, 2011 by VoIP & Gadgets Blog Icame across an excellent tutorial on installing and integrating Microsoft Lync 2010,Asterisk and Skype. The tutorial covers [...]

    Adam, a short question I am trying to integrate 2 x Asterisk as gatewaysassosiated with a Mediation Pool consisting of the 3 FEs (collocated MediationServers) for some failover/redundancy testing. Do you have an idea how toconfigure the peer part of the sip.conf to let Asterisk communicate to all 3 DNSload balanced FEs or is this configuration not achievable at all.Thanks

    Hi Paul,

    Interesting scenario. Id probably try using the DNS name as a host (pointed atthe pool name) not sure how Asterisk will handle this though i.e. will it utiliseround-robin or just fail

    Let me know how you get on?

    - Adam

    IT Business Reviews Archive Microsoft Lync 2010,Asterisk & Skype Integration Tutorial

    December 28, 2011

    Microsoft Lync 2010, Asterisk & Skype IntegrationTutorial | All Things VoIP - VoIP Phones, VoIP Products,VoIP Services, etc...

    December 28, 2011

    Paul January 28, 2012

    Adam [I'm a UC Blog] January 28, 2012

    Favad March 5, 2012

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    Hi Paul,

    Probably one of the best Lync Asterisk integration guides out there. Im workingdedicatedly on Lync since past couple of years, but totally new to Asterisk. Imtrying to do what Alex did in Post #73 below i.e set this up with a Asterisk SipTrunk Provider which unfortunately doesnt work with Lync directly.

    Im using a Public IP on Asterisk and Lync Mediation and using TCP 5060 forcommunication between Lync and Asterisk. Im unable to dial from X-lite or Lyncand get an error Unable to create channel of type SIP (cause 20 Unknown)Also sip show peers command shows Lync using 5060 correctly but also shows1001 client also using 5060 and unmonitored, which should be some random portin my opinion.

    Alex Dean :GREAT POST!!!!!! Thanks to your hard work I got my environment upand running. Lync users can call X-Lite. X-Lite users can call Lync. X-Lite users canconnect out via SIP. Lync users can connect out via SIP. All working like a charm.Not that it happened easily. Some changes were required.As Im using another SIP provider and not Skype my dial plan looks likethis:[general]static=yeswriteprotect=no[globals][default];receive incoming calls to a connected phoneexten => s,1,Dial(SIP/1001); outbound calls (outside of your own PBX)exten => _1XXX,1,Dial(SIP/${EXTEN},20)exten => _1XXX,2,hangup()exten => _0.,1,Dial(SIP/${EXTEN:1}@2talk)exten => _0.,2,hangup()exten => _2XXX,1,Dial(SIP/Lync_Trunk/${EXTEN},20)exten =>_2XXX,2,hangup()[from-lync];dialling other extensions starting with 1 followed by threedigitsexten=>_1XXX,1,Dial(SIP/${EXTEN},20)exten=>_1XXX,n,hangup();send other calls to 2talk for Asteriskexten =>_.,1,Dial(SIP/${EXTEN}@2talk)exten => _.,2,hangup()This way all calls get routed nicely.I found following commands very useful:enter Asterisk: asterisk -rReload all configfiles: reloadReload only the dial plan: dialplan reloadrebooting my asterisk server takes AGES. So reloading the configs is much muchfaster. Especially when testing different dial plans.

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    Hi Favad,

    Is the trunk up between your Asterisk server and Lync? As you previously stated,sip show peers will confirm.

    - Adam

    Hi Adam,

    Thank You for your reply. Yes it is up according to the sip show peers commandon TCP 5060. Also when dialing from Lync to X-Lite I get 480 temporarilyunavailable on Lync Mediation and Sip 404 Not found when I call from X-Lite toLync

    Thank You

    Try asterisk -r at the command line and replicate a call to see what is going on it may be a route issue?

    - Adam

    Thanks for comprehensive and funny howto. Great work!

    arrrgghh okay so I have installed PIAF purple and trying to move off my old pbxthat I had working with Lync just fine.

    Where im at Lync snooper logs simply state when placing a call to PIAFStart-Line: SIP/2.0 503 Service UnavailableCSeq: 1 INVITECall-ID: 37181e8685284502afb58faa5b279eb4VIA: SIP/2.0/TLS10.15.2.39:57786;branch=z9hG4bK62FB59E9.62B9C8E23E28080F;branched=FALSE,SIP/2.0/TLS

    Adam [I'm a UC Blog] March 5, 2012

    Favad March 6, 2012

    Adam [I'm a UC Blog] March 7, 2012

    Rune Strand April 3, 2012

    bacmallard May 9, 2012

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    10.15.16.52:50364;ms-received-port=50364;ms-received-cid=3A49500CONTENT-LENGTH: 0SERVER: RTCC/4.0.0.0 MediationServerms-endpoint-location-data: NetworkScope;ms-media-location-type=intranetms-trunking-peer-state: downms-trunking-peer: 10.15.3.2ms-enable-dns-failover: yesms-diagnostics: 10001;source=site1pool;reason=Gateway did not respond in atimely manner (timeout);component=MediationServerms-diagnostics-public: 10001;reason=Gateway did not respond in a timelymanner (timeout);component=MediationServerMessage-Body: $$end_record

    I have successful results in my sip peers that show OK in my Lync Trunk

    My objective as it was before was to have all calls from lync route to either outsideif a public number dialed and be able to call PBX extensions as well.

    Im not worried about anything right now but having the Lync be able to connectI did switch my old ports from 5060 to 5068 triple checked Lync ports and configpatched and restarted Mediation services

    As long as I can see traffic I can get through the rest. But for the life of me rightnowI cant dechiper why Lync is stating the its trunking peer state is down.

    Also in PIAF purple sip.conf is explicity stated not to edit it and to add your configsto sip_general_custom.conf instead

    mine looks like this

    tcpenable=yestcpbindaddr=0.0.0.0alwaysauthreject=no

    [Connect-with-Lync]type=peerhost=10.15.2.39qualify=yestransport=tcp,udpcanreinvite=yesallowexternalinvites=yes

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    port=5068dtmfmode=rfc2833disallow=allallow=ulawcontext=from-lync

    My Lync trunk has two entries as it did on my old pbx that was working just fineexcept for the port change from 5060 to updated 5068

    Connect-with-Lync

    Outgoing settingstype=peerhost=10.15.2.39qualify=yestransport=tcp,udpcanreinvite=yesallowexternalinvites=yesport=5068dtmfmode=rfc2833disallow=allallow=ulawcontext=from-lync

    INCOMING Settings:User context from-lync

    type=peerhost=10.15.2.39qualify=yestransport=tcp,udpcanreinvite=yesallowexternalinvites=yesport=5068disallow=allallow=ulawcontext=from-lync

    From this it looks at though your Asterisk server is talking to Lync, but Lync is not

    Adam [I'm a UC Blog] May 10, 2012

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    talking to Asterisk. Check your Lync SIP trunk out within topology builder is itset to 5060?

    - Adam

    ok switched it to 5060 that seems to have done the trickThanks ADAMI got traffic now just on to call routing from here so ill see how PIAF purple placescontexts. Ill add my update here as well.

    Question: Subject SIP Trunks:My current sip trunk has only one DID is it possible for a SIP provider to havemulitple DIDs supported on a single sip trunk?

    If so whats the average capacity per sip trunk to support multiple call volume. Iknow its based off of internet bandwidth but that aside whats the ball parkcapacity?

    Call forwarding from Asterisk to Lync then forwarding calls from Lync back outAsterisk PBX

    So say I want Lync users to utilize there client as there soft phone. That userwants to forward calls from Lync to their cell phone. That call will route out myAsterisk box.

    I discovered that if you set a password on your Asterisk extension and have Lyncset to Forward the call. It translates the call back to Asterisk as a known extensionfrom an outside source (Lync) in this case that is attempting to say hey Im one ofyour extensions please forward this call.

    The only work around I found wich is not ideal but does work is if you do not set apassword on the extension. This way Asterisk does not try to validate a knownextension from outside and allow it to pass the traffic.

    Anyone try this or have a different way of engineering it to work with the Asteriskextension and having success forwarding Lync calls out?

    bacmallard May 10, 2012

    bacmallard May 10, 2012

    Adam [I'm a UC Blog] May 10, 2012

  • pdfcrowd.comopen in browser PRO version Are you a developer? Try out the HTML to PDF API

    Absolutely, you can have a range of DDIs assigned to a trunk. Capacity is basedupon network capability and any associated service provider restrictions.

    - Adam

    Last at last, Okay so I have everything back on 5060 and now all seems to behappy again.

    My last nudge here is. I want to set the follow me settings on the PBX to the LyncExtension.

    I can dial the Lync number from PBX just fine but when I set the follow mesettings to5516 (lync extension) or 5516# it fails to forward over. Any ideas on how to getthe follow me to ring to the Lync extension?

    @bacmallard Okay so couldnt find any hacks for the follow me to worki set my Lync ext and my mobile in the PBX follow me list and ringall

    It would go to Lync but then roll over to the cell

    bit of duct tape here

    What I did was create to local extensions 5516 and changed the context SIP todial my lync extension over the trunk

    I then set up extension 4416 and changed the context SIP to dial my cell phonenumber over the ExternalProvider trunk

    set co