Script: Set-Lync2010Features.ps1 – Automated Prereq PowerShell Script for Lync Server 2010
If you’ve followed this blog for a while, you may remember one of the more popular posts, Automated prerequisite installation via PowerShell for Exchange Server 2010 on Windows Server 2008 R2. In that script, I used some simple techniques to help take some of the boring tasks out of installing Exchange 2010 servers. It was updated several times, and a new update is coming soon.
Well, Lync Server MVP Stale Hansen took that script and adapted it to installing the prerequisites for Lync Server 2010 and posted the results online. He did some neat things like installing the Best Practice Analyzer and the Resource Kit.
I took the script and added a bunch of functionality, including prerequisites for all Lync related roles, some added third-party tools such as the cool “Find Lync Versions” tool from Stephen Olsen, aka “Stumper”, was added as an option. Note: This automatically installs the .Net 4 framework.
I also added the ability to download some files that are needed – essentially automating some routine tasks. See the changelog file linked below for features added in each version.
For those of you doing Lync voice work, I haven’t done any deployments yet, so if there are tasks you’d like me to automate, please let me know and I can get them added when I have time.
Installation
Execution Policy: Third-party PowerShell scripts may require that the PowerShell Execution Policy be set to either AllSigned, RemoteSigned, or Unrestricted. The default is Restricted, which prevents scripts – even code signed scripts – from running. For more information about setting your Execution Policy, see Using the Set-ExecutionPolicy Cmdlet.
Donations
I’ve never been one to really solicit donations for my work. My offerings are created because *I* need to solve a problem, and once I do, it makes sense to offer the results of my work to the public. I mean, let’s face it: I can’t be the only one with that particular issue, right? Quite often, to my surprise, I’m asked why I don’t have a “donate” button so people can donate a few bucks. I’ve never really put much thought into it. But those inquiries are coming more often now, so I’m yielding to them. If you’d like to donate, you can send a few bucks via PayPal at https://www.paypal.me/PatRichard. Money collected from that will go to the costs of my website (hosting and domain names), as well as to my home lab.
Download
v5.3: Set-Lync2010Features.v5.3.zip
v5.2: Set-Lync2010Features.v5.2.zip
v5.1: Set-Lync2010Features.v5.1.zip
v5.0: Set-Lync2010Features.zip.
Changelog
See the changelog for this script for all version information
Hi Pat,
I saw your Set-Lync2010Features script. Can I use some code of your script? I want to write a script for install Lync CU4 and Lync Mobile. You can use my code to update your tool if you want.
Regards,
Sebastiaan
Sure – if you would include credit in the source code, that would be great.
Hi Pat
I’m using yours/StÃ¥les script and find it very useful! Great work! However, it requires internet access, which is not always available.
It should be fairly easy to include an option for downloading/displaying all the different URLS which are used when downloading the the different executables for the different options. The script would also need to be re-written to support a “OfflineFolder” parameter.
I’m thinking
xx) Download all executables for offline use
xx) Display URLs for executables for manual download
which could be run at another computer with internet access. Then copy the files to a folder on the server, e.g. “c:\atea\offlinefiles”
Run the script
.\Set-Lync2010Features.ps1 -OfflineFolder “C:\atea\offlinefiles”
which would trigger the script to use the local offline files instead of downloading via BITS.
Good idea? Solvable?
Regards Martin
If the file exists in the $TargetFolder, the script doesn’t try to download it. Just put the files in that folder before running the script.
Hi
Great work!
Could you confirm the following:
1.This script Is for preinstallation and does not include CU 4 or mobility bits
2. After updating lync via windows update after installation , I still have to run the database update command then install cu4 and run the same database update command before I install the mobility bits?
3. Can you explain how to put powershell into remote signed or unrestricted mode. Why choose one over the other?
Thank you very much in advance
1. Correct – preinstallation only.
2. Correct – I’m working on a article series on patching Lync servers.
3. Open PowerShell or Lync Management Shell, and type
Set-ExecutionPolicy RemoteSigned
or
Set-ExecutionPolicy unrestricted
RemoteSigned is more secure.
Can you add a switch to skip out any options that require internet access??
Any chance on getting this updated for Lync 2013?
Already working on a new version for 2013. Should have a 1.0 release soon.
Lync 2013 prereq’s on a 2012 server would be awesome
I have it working, including updated SQL express, for standard and enterprise FE servers, and a couple of extra options. Some beta testers have confirmed it works great. Look for a version in the next few days. It will only do Front Ends to start with.
1.0 of the 2013 script is available at http://www.ehloworld.com/1697
1.0 of the 2013 script is available at http://www.ehloworld.com/1697
Just what the doctor ordered.. Pat keep up the good work!