Lync 2013 Hosting Pack – Tenant Meet & Dialin URLs

If you’ve worked with the Multi-tenant version of Lync Server 2013, known as Lync Hosting Pack, or LHPv2. Then you’ve tried to follow the deployment guide, and likely ran into some issues configuring the Simple URLs for Meet and Dialin for your tenants. This topic came up again recently, which prompted me to recount my experience and provide some additional information.

Symptoms

The first thing you’d notice is the Lync Meeting Add-in for Microsoft Outlook 2013 closes itself a split second after it opens, no error, no pop-up, and no message to say what’s going on. Yet within the Lync client, you can still start an ad-hoc meeting (“Meet Now”), and you’re able to drag other users into the conference, but on closer inspection the Meeting Entry Info looks like this…

LHPv2-SimpleUrl-Wrong

Notice there is a PSTN Dialin Conferencing number as provided in the Lync Server Control Panel (or PowerShell), but no browser link. And a Meeting Link that doesn’t look much like a link at all, for example – conf:sip:graham@sipdomain.co.uk;gruu;opaque=app:conf:focus:id:xxx%3Fconversation-id=xxx

The following errors are also logged in the Event Log on the Front End Server each time a meeting is created…

  • Event ID 32148 – LS User Service
    A user tried to create a conference with no Simple URL of type Meet available. This configuration will not work for scheduled conferences. Ad-hoc conferences may be created but join functionality will be impaired.
  • Event ID 32149 – LS User Service
    A user tried to create a conference with no Simple URL of type Dialin available. This configuration would lead to inability to find local access number for dial-in conferencing.

Where it goes wrong… (and gets confusing)

The deployment guide is a bit fragmented, and towards the end it doesn’t seem to progress in a linear way. But I’m sure everybody who’s deployed LHPv2 is thankful to Microsoft for making it, and writing the guide, it certainly goes a long way.

Firstly, none of this is going to work without your Lync Client building the correct URL for meetings, lets look at what affects that.

Tenant OU Attributes

This part of the guide is correct, and works as expected. Lync creates your Meet URL by using the following Attributes set on the Tenant OU in Active Directory, this can be done with ADSIEdit or PowerShell.

msRTCSIP-Domains needs to contain the domain (or list of domains) the tenant will be using…

tenantdomain.co.uk

msRTCSIP-DomainUrlMap needs to contain a key/value pair for each SIP Domain in the previous attribute, and resulting Meet URL separated by a hash “#”, for example…

tenantdomain.co.uk#https://meet.hosterdomain.co.uk/tenantdomain.co.uk

As soon as you’ve done that, sign out and back into Lync, you’ll now get the correct Meet URL under the Meeting Entry Info e.g.

https://meet.hosterdomain.co.uk/tenantdomain.co.uk/username/A1B2CDEF

IIS URL Rewrite Rules

The guide then describes the process to add the Simple URLs to a specific Tenant by running the following cmdlet (after you’ve built up your SimpleURL variable). Notice the new -Tenant <GUID> parameter.

Yet running Enable-CsComputer doesn’t pick up the new Simple URL, and therefore doesn’t create the relevant URL Rewrite rules in IIS, and you can’t join the conference.

Hold on a minute, the guide also says  UseBackendDatabase needs to be set to $True, what effect does that have? Suddenly you’ll notice your Base URL is listed  meet.hosterdomain.co.uk which rewrites everything that matches to /Meet/Default.aspx. And also, a curious rule appears – meetbeta.online.lync.com, which must be leftover from the Lync Online code this version of Lync is based on, but at least we now have the other rule to rewrite the meeting URLs.

Here’s where things get confusing. Your Lync client is now giving the correct meeting URL, and IIS has a rule that will match the request. So lets try it, and find out what we see… Well, I can honestly say I wasn’t expecting this. Something I’d not seen for a while.

LHPv2-Reach-Lync-Web-App

I did install Lync Server 2013, right? Although everything works as you’d expect from using the 2010 Lync Web App, it’s just not good enough, something is clearly wrong.

Rip it up, and start again

I’ve seen forum posts claiming to answer this issue by creating these Simple URLs in the normal way, i.e. via the Topology Builder, or PowerShell, and to simply omit the Tenant GUID parameter. Where this may bring better results than following the guide to the letter, it’s still not quite 100%.

After methodically trying all combinations for my own curiosity, here’s what works…

msRTCSIP-Domains and msRTCSIP-DomainUrlMap

Firstly, setup the tenant in the normal way, and also configure the msRTCSIP-Domains, and msRTCSIP-DomainUrlMap as the guide describes. For example, something like the following PowerShell cmdlets.

As I said above, this is how the client knows how to build the correct URL.

Setting “Meet” Simple URL

I’ll come back to -UseBackendDatabase after we talk about how to set the Simple URLs, and you’ll see why later.

After all my testing, setting the “Meet” Simple URL using the Tenant GUID, makes absolutely no difference. It only works when the Simple URL is set against the ‘root’ (i.e. not set against a specific tenant) as follows…

This is the normal way you’d do it for an on-premise Lync deployment with multiple SIP Domains.

UseBackendDatabase

This parameter seems to directly influence how IIS has it’s URL Rewrite rules configured. As long as the “Meet” Simple URLs have been configured as above, and without specifying a Tenant GUID.

Lets explore the two options…

As we saw above, with this set to $True, IIS only has a single rule to match the ‘base’ meeting URL (i.e. “https://meet.hosterdomain.co.uk/”) and rewrites everything matching this to “/Meet/Default.aspx” i.e. the Lync Web App(lication).

With this set to $False, IIS is subsequently configured (by running Enable-CsComputer) to include a rewrite rule for every tenant, this means you will have two rules per-domain (one to redirect from HTTP to HTTPS, and the other to rewrite the URL to Lync Web App).

Whereas both do indeed work, I can only assume this is to keep IIS tidy, and reduce the overhead of running through a large number of RegEx tests to match against each and every tenant domain, and therefore offloads the domain/tenant lookup to the Backend Database.

Setting “Dialin” Simple URL

So far we’ve ignored the Tenant GUID, and even though you may have a Dialin URL configured for “*” (All domains), this still isn’t picked up by the Lync client, and not included in the Meeting Entry Info dialog box.

This turns out to be the opposite of the Meet component, and needs to be set against a Tenant GUID using the following PowerShell cmdlets.

This lets you specify the hoster’s default Dialin URL, or even a different and unique URL for each tenant. For example, a page on their own website – so they can use their own branding and wrap “https://dialin.hosterdomain.co.uk/” in an <iframe> to make it look prettier, and still retain the ability to reset Conferencing PINs and Assigned Conference Information.

Enable-CsComputer

I’ve found you need to wait a moment for the changes from the above PowerShell cmdlets to take effect before running Enable-CsComputer, so if things aren’t happening for you, then you need more patience. (or run  Get-CsManagementStoreReplicationStatus in a loop until it’s updated, before running Enable-CsComputer).

Summary

So, lets recap…

  • Add a “Meet” URL for each SIP Domain for each Tenant WITHOUT specifying the Tenant GUID.
  • Add a “Dialin” URL WITH the Tenant GUID.
  • Set -UseBackendDatabase parameter to $True if you want to reduce the amount of rules processed by IIS.
  • Wait…
  • Run Enable-CsComputer

Enjoy.

Tweet about this on TwitterShare on LinkedInShare on Facebook
Pin on PinterestShare on Google+Digg thisShare on RedditShare on StumbleUponEmail this to someone

About Graham Cropley

Working as a Senior Consultant for Skype for Business, Exchange, and Office 365.

21 Comments

  1. Wow! That worked!!! Thanks!!

    Funny because I opened a ticket and Microsoft (Lync team) referenced your article! They are trying to find out what is going on and why the deployment guide is written the way it is and why it doesn’t work. Hopefully I will know something this week or next.

    Have you spoke with Microsoft about this issue?

  2. Hi,
    when i use your procedure, for the meet simple URL i get the following error:
    Set-CsSimpleUrlConfiguration : One Simple URL (“https://meet.hoster.com/”) cannot be a left prefix of another URL (“https://meet.hoster.com/tenantdomain.com/”)

    • Each domain needs to be the same format, and not a folder underneath another URL. This is due to the way the Regular Expression match the url i.e. looking for “https://meet.hoster.com/” would match “https://meet.hoster.com/” and all other meet URLs that start with that i.e. “https://meet.hoster.com/tenantdomain.com/”

      If you want to host users in your domain i.e. “user@hoster.com”, then you need to think of that domain as a tenant too.. e.g. create a Meet URL such as “https://meet.hoster.com/hoster.com/” or perhaps something that looks nicer such as “https://meet.hoster.com/ourmeetingplace/”

      I hope that makes sense?

  3. Hi Graham, that makes sense 🙂

    Should i then change the default meet URL (in topology builder) to “https://meet.hoster.com/hoster.com/” so that other tenant meet urls can be in the same format ? “https://meet.hoster.com/tenant1.com/”

    • Hi Jordan, I covered that in my post, when the Simple URLs are incorrectly configured against the TenantID and not the ‘root’, IIS throws a wobbly and directs you to the /Reach/ URL which is the Lync 2010 Web App. If you follow my steps above, that should bring back the full featured Lync 2013 Web App.

      Thanks for the links, I’ve replied to both of those, hopefully that will get this issue fixed for those people too.

  4. Oh thanks Grahamn, i have read your article a lot of times but miss that point 🙂
    I will test this one this week and come back to tell you if it’s working 😉

  5. Graham,

    Do you know how to remove wrong simple URL entry ?
    I have two wrong meets URL set for my tenantdomain.com. Those URLS were specified using TenantID parameter so i would like to remove it.

    I try this script :

    Import-Module ActiveDirectory,Lync,LyncOnline
    $TenantDomain = “mydomain.com”
    $TenantDN = “OU=$TenantDomain,OU=HOSTING,DC=dc,DC=lan”
    $TenantOU = Get-AdOrganizationalUnit -Identity $TenantDN -Properties msRTCSIP-Domains, msRTCSIP-DomainUrlMap
    $MeetingUrl = “https://meet.hoster.com/$TenantDomain”

    ### Remove URL ###
    $TenantOrgId = (Get-CsTenant -Identity $TenantOU.DistinguishedName).TenantId
    $publishedSimpleUrls = (Get-CsSimpleUrlConfiguration -Tenant $TenantOrgId ).SimpleUrl*
    $publishedSimpleUrls.Remove(($publishedSimpleUrls | Where-Object {$_.Component –like “*meet*”}))

    But it’s not working, i can see my two wrong meeting URL using “Get-CsSimpleUrlConfiguration -Tenant $TenantOrgId”…
    Thanks

    • I’ve just tried that method in my lab, and it worked fine. Although when I’m cleaning up, I tend to do it more manually from a PowerShell prompt, rather than a script.. i.e.

      $publishedSimpleUrls = (Get-CsSimpleUrlConfiguration -Tenant $TenantOrgId).SimpleUrl
      $publishedSimpleUrls.RemoveAt(2) // Index of the URL Entry I want to remove

      I’ve noticed you have been working with $publishedSimpleUrls in memory, but haven’t committed it back using Set-CsSimpleUrlConfiguration… e.g.

      Set-CsSimpleUrlConfiguration -Tenant $TenantOrgId -SimpleUrl $publishedSimpleUrls

      Could that be your issue?

  6. Yeah thanks your cmdlet use and i add “enable-cscomputer” too.
    Now it’s looks fine. Thanks again.

  7. Hi Graham,
    Big thanks for your blog, it is really helpful!
    So many useful things described in professional way.
    I want to ask you a question regarding LHPv2 ( Lync 2013 Hosting Pack). I would appreciate if you can answer it.
    Question is quite simple, but I can’t find information on Microsoft’s sources.
    How LHPv2 can be updated, like Enterprise using Windows Update Service? I’m asking because I heard that in previous version of Lync it was not allowed/supported.
    Looking forward to receive reply from you.

    Best regards,
    Aleksandrs

  8. Hi Graham,
    I’ve run into exactly the same issues. I’ve also found you need to add the meet URL to both the Tenant ID AND globally (in addition for the dialin, which is not officially supported by the way) for is to work as we want it to 😉

    • I think that’s the case if you set UseBackendDatabase to true. Then that’s where IIS pulls it’s rewrite config from rather than directly creating rules by running Enable-CsComputer.

      Thanks!

    • Hi Lasse,

      I am having same issue with some tenants in the Lync 2013 Hosting pack environment. Not all tenants are having the issue. So what were the exact steps you followed in your case to resolve the issue?

      Thanks!

  9. Hi, Graham
    I love your page here, its a life saver. 🙂
    I just have one question;
    I tried to enable the Dialin, according to your walkthrough here, and managed to type in the wrong address.
    Trying to do it over again, with the right address throws me:

    Set-CsSimpleUrlConfiguration : There is a duplicate key sequence ‘DIALIN *’ for the ‘urn:schema:Microsoft.Rtc.Managemen
    t.Settings.SimpleUrl.2008:SimpleUrlKey’ key or unique identity constraint.
    At line:1 char:1
    + Set-CsSimpleUrlConfiguration -Tenant $TenantOrgId -SimpleUrl @{Add=$dialinUrl}
    + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    I cant seem to figure out how to replace this address.
    I managed to type in www. instead of dialin.
    Any help would be greatly appreciated!

    • Hi Einar,

      You need to remove the existing Dialin entry first, before you can add a new one.. It can be a bit tricky, you could do something like this…

      $SimpleURLs = (Get-CsSimpleUrlConfiguration -Tenant $TenantOrgId).SimpleUrl
      $olddialin = ($SimpleUrls | Where-Object {$_.Component -eq “dialin”})
      $SimpleUrls.Remove($olddialin)
      $SimpleUrls.Add($correctdialin)
      Set-CsSimpleUrlConfiguration -Tenant $TenantOrgId -SimpleUrl $SimpleUrls

      Let me know if that helps?

  10. Thanks, but didn’t seem to work.
    Get-CsSimpleUrlConfiguration : Cannot convert ‘System.Object[]’ to the type ‘System.Nullable`1[System.Guid]’ required by parameter ‘Tenant’. Specified method
    is not supported.
    At line:1 char:53
    + $SimpleURLs = (Get-CsSimpleUrlConfiguration -Tenant $TenantOrgId).SimpleUrl
    + ~~~~~~~~~~~~
    + CategoryInfo : InvalidArgument: (:) [Get-CsSimpleUrlConfigurati
    on], ParameterBindingException
    + FullyQualifiedErrorId : CannotConvertArgument,Microsoft.Rtc.Management.I
    nternal.GetHostedSimpleUrlConfigurationCmdlet
    And a few more errors.

    Still get the
    Set-CsSimpleUrlConfiguration : There is a duplicate key sequence ‘DIALIN *’ for
    the ‘urn:schema:Microsoft.Rtc.Management.Settings.SimpleUrl.2008:SimpleUrlKey’
    key or unique identity constraint.
    At line:1 char:1
    + Set-CsSimpleUrlConfiguration -Tenant $TenantOrgId -SimpleUrl @{Add=$dialinUrl
    }
    + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    ~
    + CategoryInfo : InvalidData: (Global:String) [Set-CsSimpleUrlCon
    figuration], XmlSchemaValidationException
    + FullyQualifiedErrorId : InvalidData,Microsoft.Rtc.Management.Internal.Se
    tHostedSimpleUrlConfigurationCmdlet

    Should work if I delete the tenant and remake it, right?
    -Einar

    • Just check that $TenantOrgId contains only the GUID of the Tenant, and not the whole tenant object itself, I just took the variable name from your example below. But if you’ve ran something like “$TenantOrgId = Get-CsTenant etc…” then you need to use “Get-CsSimpleUrlConfiguration -Tenant $TenantOrgId.TenantId etc…” instead.

      I hope that helps?

Leave a Reply

Your email address will not be published. Required fields are marked *