Tag Archives: Lync

Lync Server 2013 – Location Based Routing: Part II


In part I Lync Server 2013 – Location Based Routing aka LBR, I discussed about the basic fundamentals, benefits, capabilities and routing methodologies. To extend the same, part II will cover implementation steps and test cases. As discussed in part I, LBR is a set of rules which handle your PSTN calls to comply with regulations of specific countries such as India. In telephony terms, it prevents toll bypass by blocking or modifying the routes of PSTN calls. Organizations can define the scope for LBR such as specific region, International calls, specific gateways or PBX and set of users. LBR policies can be based on user’s location or PSTN gateways location. LBR applies rules on different scenarios.

To test the LBR scenario, Single Site is deployed with asterisk PBX to generate voice calls. Test scenario will consider enterprise voice calls which are generated by Lync user located @ office and located @ home

Let’s start with deployment process:

1. Process start with Enterprise Voice deployment

Create dial plans and configure Normalization rules

Create and configure trunks, voice policies and define voice routes

2. Test Enterprise Voice setup

3. Create Network Region and Sites, define subnets based on your Lync infra.

4. Create Voice Routing Policy.

New-CsVoiceRoutingPolicy –Identity “Site1VoiceRoutingpolicy” –Name “Site1 Voice Routing Policy”

5. Set Voice Routing Policy and assign PSTN Usage (In lab scenario PSTN usage is created with name “Asterisk”)

Set-CsVoiceRoutingPolicy –Identity “Site1VoiceRoutingpolicy” –PSTNusages @{add=”Asterisk”}

6. Enable and configure location based routing and voice routing policy for Network Site

Set-CsNetworkSite –Identity Site1 –EnableLocationBasedRouting $true –VoiceRoutingPolicy “Site1 Voice Routing Policy”

7. Trunk configuration

Set-CsTrunkConfiguration –Identity Site1Trunk –EnableLocationRestrictions $true –NetworkSiteID “Site1”

8. Change Voice & Routing Configuration

Set-CsVoicePolicy “Site1VoicePolicy” –PreventPSTNTollBypass $true

Set-CsRoutingConfiguration –Enable locationbasedrouting $true

Follow the same steps for multiple sites carefully.

Test multiple calls scenario such as:

Incoming PSTN call while user @ his home location (Site1)

Outgoing PSTN call while user @ his home location (Site1)

Transfer and Forward while both the users @ their home location (Site1)

Simultaneous ring while both the users/endpoint @ their home location (Site1)

Lync users @ their home location are doing conference

Lync users @ their home location are doing Lync conference and PSTN user is joining conference using “Dial-in Conferencing”

Incoming PSTN call while user is logged in from outside

Outgoing PSTN call while user is logged in from outside

Transfer and Forward while both the users or one of them are not @ their home location (Site1)

Simultaneous ring while both the users/endpoint or one of them are not @ their home location (Site1)

Lync users @ their home location are doing conference and one of the conferencing user is trying to conference any PSTN user

These are few examples related to my Lab design, if you have more than one site then you need to test many other scenarios as well which certify that you are compliant with regulation.

Advertisements

Lync Server 2013 – Location Based Routing


Location Based Routing is an impressive feature of Lync Server 2013 which distinct Lync Server 2013 from other UC solutions. LBR allows full fledge Lync 2013 Enterprise Voice deployment for those enterprises who are doing business in regulated countries such as India, UAE, Egypt etc. Lync enterprise voice deployment with LBR requires well-versed planning and designing as your one wrong step can disturb entire voice setup. Now, questions come to every Lync professional if LBR requires planning & designing; it means LBR is not enabled by default or in other ways, LBR configuration part comes later.

Question: If LBR is not enable by default and needs additional configuration, which methodology Lync Server uses by default?

Answer: LCR

Many Exchange professional who are reading this blog, can assume LCR means Local Continuous Replication which was introduced in Exchange Server 2007.

By default Lync server uses Least Cost Routing methodology. Least cost routing can reduce the call rates by minimizing toll charges and maximizing WAN uses, which can benefit to the enterprises but in another ways it is a revenue loss for PSTN service providers.

LBR Benefits:

  • Comply with regulations that restricts IP-to-PSTN routing in pre-defined cases.
  • Routes PSTN calls based on caller’s location to prevent toll bypass.
  • Scoped to specific locations, gateways, and users based on Network configuration.
  • Route call to the gateway closest to the calling party which increase QoS & QoE.
  • Minimize use of WAN which result in better QoS & QoE.

LBR Capabilities:

  • Route outgoing calls to a PSTN gateway local to the caller’s location.
  • Prevent incoming calls if the Lync client is not in the PSTN gateway’s location.
  • Route outgoing calls through international PSTN gateways when there is no local gateway.
  • Ensures that conferences do not have a mix of users from different locations and PSTN dial-out.

Outbound routing:

Trunk-to-trunk routing:

Inbound routing:


There are many test cases involve in LBR implementation which need to be tested. Implementation steps and test cases is explained in the next part of this article.

Courtesy: Lync Conference 2014.

A trusted server….. error while publishing Lync Server 2013 topology


You may see “A trusted server….” error while publishing Lync Server 2013 topology.

In my case, I was adding Archiving and Monitoring role in existing Lync environment and had never faced this issue before.

After searching and looking into the error, I observed this error is occurring because of some existing entries in Active Directory.

To resolve this issue, I followed the below steps.

Note: Please take your AD backup before playing with ADSI Edit or ask your AD expert to perform the same activity.

  1. Open ADSI Edit (adsiedit.msc)
  2. Open Configuration partition and navigate to CN=Services>CN=RTC Service>CN=Trusted Services.

  1. Go to the properties of each entry under “CN=Trusted Services”.
  2. Type “msrtc” to search the Lync attributes in the property.

  1. Cross verify “TrustedServiceType” and “TrustedServerFQDN” with the error.
  2. Close the property and delete the entry.
  3. Publish the topology.
  4. If you get the same error again with different TrustedServiceType, follow the same procedure one more time.

Finally, publish the topology 🙂

Lync Server 2013 Brick Model


Messaging is a business critical application for any enterprise. To increase the productivity, instant or real-time communication is very much required. Lync has become a more suitable option for business productivity which serves all real-time workloads such as IM/Presence, Audio/Video & Web conferencing, Group/Persistent Chat, Application & Desktop sharing and Enterprise Voice.

While enterprises are moving towards an application for real-time communication, services availability is concern for IT decision makers. To avoid complexities and provide more availability Microsoft came up with brick model architecture for Lync 2013. It allows scaling out your Lync FE servers from 1 to 12 and each server can support up to maximum 6666 concurrent users. Lync Server 2013 is loosely coupled with Lync Back End SQL server and use lazy writes feature to write data in SQL Back End server.

Lync Server 2013 divides users in a group and each group is dynamically assigned to three Front End Server, primary secondary and tertiary. Once user logs in, primary server serves the services and replicate the data across secondary and tertiary using synchronous replication as well as update the SQL backend server using asynchronous replication known as lazy writes. In case of primary server failure secondary server serves the services.

In Lync server 2013, Front End server keeps rtc, rtcdyn and xds database in local sql express store. To know more about Lync 2013 databases please go through Lync Server 2013 databases.

Now, we should talk about how brick model works. Basically, brick model is based on windows fabric and it consider nodes majority for availability. That’s why you need minimum three Front End servers to achieve high availability. The majority is considered when n/2 or n+1/2 Front End servers are alive.

For maintenance, you should restart/down one server at a time. If all Front End servers go down due to the power outage or any other reasons, please make sure you are starting all Front End servers at the same time.

Configure DHCP Server options for Lync Phones


Setting up entire Lync Infrastructure is fun for Lync Professionals but real fun always come at last moment when end users start enjoying Lync services from their end user devices. To setup Lync soft client is quite easy while configure Lync phone devices are tricky one.

Trick comes with automate process of Lync phone devices which start from getting an IP address from DHCP server and end with user specific configuration such as selecting Time zone. Most of the companies use DHCP server to provide IP address to the client machine, simply Lync Phone devices can get an IP address from same DHCP server but it needs more to complete the entire configuration.

First of all, we have to understand any Lync client can only login if time is synchronized between Lync Server and Client. To meet this requirement starts with DHCP option 42.

If you have time server in your existing environment, specify the same in DHCP configuration option 42.

Let’s take an example if you don’t have time server in your existing environment then you can configure domain controller (PDC) as a time server.

  1. Create a record as shown below.

  1. Create service record as shown below.

Once you are done with this, specify same server address in DHCP option 004 & 042 and domain name in option 119.



Rest all the options you can see below need to be configured. But 🙂 you’ll not get any option with specific vendor by default in your DHCP server.

To make it simple MS provide dhcputil.exe in Microsoft Lync Server 2013 Front End / Standard Edition Servers.

 

Just copy this dhcputil.exe file in DHCP server and run below command

DHCPUtil.exe -SipServer <Lync Server Pool FQDN > -WebServer <Lync Server Internal Web FQDN> -RunConfigScript

In my case, I have copied dhcputil.exe in c drive of dhcp server.

C:\> DHCPUtil.exe -SipServer se01.insidemstech.com -WebServer sewebint.insidemstech.com –RunConfigScript

Once you will run the above cmdlet, it will add & configure all the required option as shown below

If you want to verify your dhcp configuration, run DHCPUtil.exe –EmulateClient from client computer.

If it doesn’t give any errors. It means you are done.

Now you can set pin for your Lync users and get logged in through Lync Phone Edition devices.

I hope it helped 🙂

 

How does Lync Federation work?


Lync federation also known as external connectivity which allows a lync user to connect with users in other organization as well as public IM domains and XMPP. Lync support two kinds of federation open and close. When an organization allow open federation that means the organization has enabled automatic discovery while closed means the organization has disabled automatic discovery and added specific domain to allow federation.

Lync federation can be configured from Lync Control Panel as well as from Lync Management Shell.

It is time to know “how does lync federation work?” Let’s take an example of two organizations contoso.com and fabrikam.com. Both organizations have open federation.

Below is the step by step procedure:

  1. UserA (sipuri:usera@contoso.com) is looking for UserB (sipuri:userb@fabrikam.com)
  2. First of all it will check the access edge configuration for federated domain.
  3. As UserA request for sipuri: userb@fabrikam.com and in my case both domain is configured for open federation, the request will go to Access Edge Server and Access Edge Server will do lookup for domain name fabrikam.com.
  4. If fabrikam.com domain exists then it will look for the SRV record _sipfederationtls._tcp.fabrikam.com.
  5. Once it will get the destination address of fabrikam.com access edge server then it will try to establish the SIP/MTLS:5061 connection.
  6. Once Fabrikam.com will receive the request from contoso.com, fabrikam.com will check the access edge configuration to verify allow/block federated domains.
  7. Once the connection will be establish between both Lync Front End Pools / Lync Standard Edition Servers via Access Edge Server, UserA and UserB will talk to each other.

 

Note:

  1. All the required ports should be open in both ends.
  2. SRV record entry should exist in External Certificate.
  3. Federated domain should be allowed in both ends.
  4. XMPP doesn’t use SIP/MTLS:5061. It use XMPP/TCP:5269 to connect access edge server from public network and XMPP/MTLS:23456 to connect Front End Pool.

Step by Step Lync 2013 Edge Server


Lync server consists of multiple roles and Edge server role is one of them. Lync server 2013 Edge server role take care of external connectivity of Lync users. It provides connectivity to Remote, PIC, Mobile, Federated and Anonymous users. Edge server deployment provides external access to different communication modalities IM & Presence, Web Conferencing and Audio/Video Conferencing.

Edge server deployment is not as simple as other Lync server roles and requires attentive preparation before jump into the installation. Let’s start the preparation for deploying standalone Edge server role.

IP Address Planning:

I am using 192.168.x.x/16 IP addressing for Internal Network, 172.25.x.x/16 IP addressing for Perimeter Network and 10.x.x.x/8 IP addressing for External Network. IP address on internal firewall is 172.25.33.100 which will act as a gateway for communication between perimeter network and internal network, IP address on External firewall is 10.1.1.100.

As internal NIC of Edge server is behind internal firewall and don’t have gateway in internal network address. So, we will have to route traffic from 172.25.33.10 to internal network via 172.25.33.100.

Follow below steps to add route.

Open command prompt with administrative rights on Edge Server.

Run “ipconfig /all” and note down the physical address and Ethernet adapter description of internal NIC.

 

Now run route print and note the Interface List ID of the internal NIC.

 

Now add the persistent route for internal traffic.

 

Open Lync Server Topology Builder on Lync Front-End / Standard Edition Server.

Right click on Edge Pool and select New Edge Pool.

 

Click on Next.

 

Write Edge Server FQDN.

 

Select appropriate features as per your requirements.

 

Select IP versions and NAT option according to your requirement.

 

Specify external FQDN and associated port numbers. (Note: If you have selected “Use a Single FQDN and IP address” then you will have to use different port numbers for all three FQDNs).

 

Specify the IP address for Edge server internal NIC.

 

Now specify the external IP address for all services.

 

Please specify the Public IP address which will be NAT to the A/V edge service. (In my case, the deployment has been done in LAB and don’t have public IP address. That’s why I am taking a different IP address.)

 

Define the next hop server. Next hop server will be your Lync pool if you don’t have director otherwise next hop will be your director pool.

 

Select pool and click on finish.

 

Now publish your topology.

 

 

 

Open Lync management shell with administrative privilege on Lync FE server and export the configuration.

 

Login to the Edge Server with administrative privilege and run Microsoft Lync Server 2013 setup and follow the steps.

 

 

 

 

After installing Lync 2013 core components, open Lync server 2013 deployment wizard.

 

Click on “Install or Update Lync Server System”.

 

Run “Install Local Configuration Store”

 

Browse Edge configuration file which you had exported in Lync FE server.

 

Click on Next.

 

 

 

Cross verify the installation through log file.

 

Now, Run “Setup or Remove Lync Server Components”.

 

 

 

 

 

Now, it’s time to request and assign certificates.

 

Follow the steps to request the Edge Internal Certificate.

 

 

 

 

 

 

Fill the appropriate information.

 

 

 

 

 

 

 

Now, request External Edge certificate.

 

 

 

 

 

 

 

 

(Note: If you want to use same public certificate for Reverse proxy also, add additional SAN’s for reverse proxy: lyncdiscover.domain.com, lyncwebservicesexternalname.domain.com, dailin.domain.com, meet.domain.com)

 

 

 

 

Once you have generated certificate request, can send these request to your certification authority to generate the certificates for you. As we are doing this setup in our lab, so we will use our internal AD CA.

Once you have generated the certificates open mmc and add certificates (Local Computer) via add/remove snap-in to import the generated certificates.

 

Import root CA onto Trusted Root Certification Authority.

 

Import generated certificates into Personal store.

 

 

 

 

 

Follow same step to import Edge Public cert also.

 

Now, It’s time to assign certificate to Edge services.

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Once certification assignment is done, open Lync control panel in Lync FE server and go to Federation and External access.

 

Change External access policy as shown below.

 

Change Access Edge configuration policy as shown below.

 

Now everything has been done, it’s time to perform last step. Add Front End Pool / FE server entry into Edge server host file.

 

Finally, your external Lync clients will be able to login and you can use Edge services for external connectivity.

But, still you cannot use those services which require Reverse proxy. Therefore, configure your reverse proxy also to get all the things worked seamlessly.