Automating FIM Run Profiles for Lync

When deploying Lync in a Central Forest Topology it is recommended to use a directory synchronization product of some sort to synchronize user accounts from user forests to the central resource forest as contact objects. Nowadays this is normally handled by Forefront Identity Manager, and this deployment is discussed in detail in the Technet white paper.

When FIM is deployed, you have to execute Run Profiles on the management agents in the correct order, both import and metaverse synchronization needs to be done on the central forest management agent before any user forest management agents for the data to be exported correctly in the last step. This means that in general the Run Profiles needs to be run in this order: (This applies to both Full and Delta executions)

  • Import  Central Forest Management Agent
  • Import User Forest 1 Management Agent
  • Import User Forest 2 Management Agent
  • Sync Central Forest Management Agent
  • Sync User Forest 1 Management Agent
  • Sync User Forest 2 Management Agent
  • Export Central Forest Management Agent

Also it is a good idea to wait until the last operation is completed before starting the next.

This gets quite tedious rather quickly when you have to right-click the management agent -> run, select the correct profile, then click OK for every operation. In addition you will need to think about automation at some point as well.

So I’ve created this powershell function that will take a sorted array of Management Agent names and run all the Run Profiles in the correct order for you.

Simply load the functions in your current powershell session and run

CsFimMaRun -ManagementAgents @("ResourceForest","UserForest1","UserForest2") -Type Full

or

CsFimMaRun -ManagementAgents @("ResourceForest","UserForest1","UserForest2") -Type Delta

and the run profiles should be executed in order. For automation just add one of the above to the end of the script and run that in a windows task scheduler. One delta update a day is often enough, but if the environment is very dynamic you might want to run it more often.

If you set $debugpreference=”Continue” it’ll display the status after each operation as well.

Download CsFimRunProfileExecution.zip

Script: Set-CsKhiCollectorSet.ps1

Lync Key Health Indicators are an essential tool in health monitoring your Lync deployment, and is the first step in deploying the Lync Call Quality Methodology

After adding the KHI counters to applicable Lync servers, it can be quite the chore to log in to all of them to start the performance counters. It is possible to reach all computers from a Performance Monitor snapin, but with a lot of servers that too can take some time.

This script finds all servers that normally run KHI counters, and starts or stops the counters on them. It can also get the current running status of the counters. It is also possible to supply a csv with servers to run on to the script.

Download here Set-CsKhiCollectorSet.zip

A change of scenery

After eight years at Atea the time has come for a change of scenery. As of today me and Christian Knarvik start a new adventure at Knowledge Factory where we will bring KF to southern Norway. I am really looking forward to starting work with bringing Skype for Business to Norway together with KF.

I want to thank my colleagues in Atea for the last eight years – and to my new colleagues in KF, I can’t wait to get to know you all!

Lync, Skype and Cisco Telepresence clients in the same video conference!

Late afternoon last Friday (In europe at least :)), Microsoft released video calling between Lync and Skype. This has been something that a lot of us has been waiting for for quite some time! You can read more about this release here.

To be able to video call a Lync contact from Skype, and vice versa, the following needs to be set up:

  • The Lync environment needs to be federated wilyncoptionsth Skype – see the Provisioning Guide
  • The Lync user needs to use the Lync 2013 client.
  • The Lync user has to be enabled for Public Access, and will have to set “Contacts not using Lync” to “Allow invites but block all other communications” or “Allow anyone to contact me” under “Alerts” in the Lync options menu.
  • If set to “Allow invites but block all other communications” both the Lync user and the Skype user must add each other to their contact lists
  • Currently it will only work from Skype on a Windows desktop running at least version 7.0.x.100. More Skype clients will be supported in the coming months.

This also brings cool opportunities when using Lync together with for instance Acano or Pexip MCU software. This screenshot is from a video conference using the Acano brigde, and here is a Skype Client, a Lync Client and a Lync mobile Client brought together with a Cisco Telepresence room! Pretty awesome! The screenshot is taken from the Skype Client.lyncskypeciscotp

 

Time to learn appcoding – Range Predictor

Well, the time has come to learn to code Windows apps.

I coded a lot when I went to college, but since then it has only been the occasional PowerShell scripting. I had forgotten how relaxing it is to just sit down and write code, and thats what I’ve been doing this summer – it has more or less replaced the little time I had left for gaming, which usually is my go-to timesink when I need to disconnect from the world around me.

My ‘Hello World’ project ended up being this little range calculator for Electric cars. I’ve recently bought a Renault Zoe, and this seemed like a nice little tool to have, especially considering that the guess-o-meter remaining range display in the car is a bit unpredictable.

The idea originally came from this forum post at myrenaultzoe.com forums, but I’ve also added support for a couple of other cars with battery capacity data sourced from wikipedia. I’ve also put in the Zoe Range rule Trevors android app uses if you select the Zoe as the car.

In the near future I’m probably going to add a Windows 8 store app as well, as it is written as a universal app, and I’m thinking of also adding maps With the range drawn on the map. I might also at some point use the NOBIL API to pull at least Norwegian charging stations and display them on the map. Shouldn’t be too hard to get directions either once you get that far – but now I’m dreaming a bit :)

So without further ado, here’s my first Windows Phone app:

http://www.windowsphone.com/s?appid=e5795f97-b78d-4642-ace9-c36170aa5d7f

Lync Meetings and Transport Neutral Encapsulation Format

One of the small things that make Lync Meetings so simple to join is that Outlook will recognize the meeting and wil give you a small button on the Outlook reminder that lets you join the meeting without even opening the calendar. This is also the same functionality that clickable from the calendar interface on the mobile and desktop clients and makes the meeting joinable from a Lync Room System.

Some might have noticed though that when the Lync meeting invites come from an external organization, none of the clients will actually recognize the meeting as a Lync meeting. For most of the clients this is not a big problem, because the link in the invite will still be clickable, but for the Lync Room System this will actually render the meeting unjoinable.

The method that is beeing used in the meeting invites to identify a calendar object as a Lync meeting is called Transport Neutral Encapsulation Format, or TNEF. TNEF is basically an attachment format that is used by Outlook and Exchange in different situations additional formatting is needed, like voting and meeting invites.

The global settings for sending TNEF to remote domains is default set to false. This means that when sending Lync Meeting invites out of the organization, the TNEF attachment is stripped off and the recieving party does not get the extra data which in turn makes the Lync clients at the recieving party not recognize the meeting as a Lync meeting.

To resolve this, the sending party needs to enable sending of TNEF attachments to the recieving party. This is done via the RemoteDomain settings, and can be turned on for i.e contoso.com like this:

New-RemoteDomain -DomainName contoso.com -Name Contoso
Set-RemoteDomain -Identity Contoso -TNEFEnabled $true

It is also possible to set TNEF on for all remote domains, but be careful with this as TNEF can cause issues if the recieving end does not use Exchange.

Bug in KB 2863908

There seems to be a bug in the Lync update KB 2863908 that breaks integration between Outlook 2010 and Lync 2013.

If you search for a local outlook contact in lync, it will not display a phone number  on the contact card unless you remove the email address from the contact. If an email address is present on the contact, the lync client will not display any phone numbers for the contact.

As far as I have seen it only occurs when you have Lync 2013 and Outlook 2010.

Removing KB 2863908 resolves the issue.

There are also a couple of threads on the technet forums about this:

http://social.technet.microsoft.com/Forums/en-US/4317ec0e-3287-427d-b875-5b9c93997139/lync-client-2013-does-not-get-contact-phone-numbers-from-outlook-2010?forum=lyncprofile

http://social.technet.microsoft.com/Forums/lync/en-US/130ff6ff-54aa-42a2-86c5-69761eec446a/lync-2013-client-does-not-show-outlook-contact-numbers?forum=ocsclients