Sharepoint.

Did you get shivers down your sysadmin spine?  I did.  Years of practice, and I still run into the most intricate and ridiculous problems when administering or deploying a SP install.  15 years in production from MSFT and they still don’t have it right.  Here are some lessons I learned in the last 24 hours of trying to deploy a SP 2013 SP1 server to 2012 R2.

 “The tool was unable to install Application Server Role, Web Server (IIS) Role.” 

  1.  Don’t patch your 2012 R2 server before you try to deploy it.  Why?  If you aren’t paying close attention to different security patches obtained from MS or from your local WSUS, you can run into this issue right here.  I thought I was being a smart fellow having my server set up and patched before running the SP 2013 SP1 (this even happens with the SP1 media) disc and the prerequisite installer.  A few hours of arguing with “Error: The tool was unable to install Application Server Role, Web Server (IIS) Role” will eventually lead you down to a few things.  You may have forgotten to allow your local server install to call home to MSFT to get installation packages; which you can edit the local group policy if you don’t have a gpo for it.  The next is that you likely updated your .net 4.5 installation to 4.6 which causes this behaviour in a SP rollout.
  2. It’s going to be more efficient use of your time to wipe out the virtual machine and start over than try to patch the endless issues you can run into when trying to resolve some of the errors, such as this one.  The post linked is a great resource if you want to try to pull out of the nosedive and it’s relatively easy to perform.  I gave it a shot; to no avail.  The errors persisted.  I even ran the MSFT .net clean up tools.  No love.
  3. In reference to point 1.; The SP install will run perfectly and reboot a few times if you aren’t up to date and have enabled appropriate package retrieval via GPO or security policy.
  4. Once you are all installed and running, you can safely patch the server and SP farm.
  5. Run the prerequisite installer first.  It’s in the root folder of the ISO; and aptly named.
  6. If after using the script from the post over at SomeShinyObject still causes your installation to hang during the “Web Services IIS” portion of the preparation, close the ‘Server Manager’ Window.  That will allow your installation to complete.
  7. Now you can run the setup.exe from the ISO.  Punch in your key, accept the notes on the requirements (SQL 2008 etc.)
  8. Note that you can’t have a licensed copy of SP installed, and then use a trial version of Project Server on top of that.  There is no workaround for that error.  Again, you will be put back to the point where you need to wipe and start over – install SP as a trial so that you can install Project Server as a trial too.
  9. Try not to shed too many tears doing the same work over and over.
  10. Real devs do it in production.  Sysadmins test it on dev first.