Pages

Wednesday, March 6, 2013

Using AutoSPInstall to install SharePoint 2013

 

Overview

In the past most of us doing the SharePoint 2010 development work have used AutoSPInstall from codeplex http://autospinstaller.codeplex.com/.  I have used the AutoSPInstaller successfully for SP 2010 and managed to configure and install for Farm level install as well, although there was no direct support from the tool at that time.

Entering the SharePoint 2013 world, for the past few weeks I had started to experimenting with the latest version (V3 at the time of this blog post), coupled with the new configuration editor tool called AutoSPInstallerGUI to prepare the input xml file at http://AutoSPInstallerGUI.codeplex.com.

Here I have written a detailed preparation and execution of AutoSPInstall for SharePoint 2013.

What to expect?

  • You will have SharePoint 2013 installed and configured with all the Service Applications.
  • Portal and MySite Web Applications created.
  • No Fore Front for SharePoint 2013 yet. (Current version of Fore Front for SharePoint from MSDN expects SharePoint Portal Server, I believe it meant SP 2010)
  • No Office Web Apps 2013 on the same instance, as OWA 2013 is an independent product and will require a separate instance from SharePoint 2013 .

Pre-Requisite

  • You have a new server that is dedicated for this SharePoint install. I had Windows 2012 Std server.
  • The Server is appropriately  named and is joined to the AD (If you are doing a single single server development then add the AD Role, which is what I had done in this case)
  • Either you have SQL Server 2012 installed on the same machine or a separate machine.
  • Windows Software Updates applied.
  • Below Domain level Service Accounts Created (You could further create ExcelUser/PerformancePoint User/ VisioUser, I kept it simple for the purpose of this blog)

Account Type

Rights

Development

Install Account

Full administrator rights on all SharePoint and SQL servers. Will be disabled after install is completed.

SPSetup

SQL Service Account

If not already installed, domain account with no local rights above Domain User.

SqlService

Farm Administrator

SQL roles DBCREATOR and SECURITYADMIN.

SPFarmAdmin

Application Pool

One account per application. For example one per intranet, extranet and public website.

No local rights or SQL rights above Domain User.

SPPortal

 

My Site

No local rights or SQL rights above Domain User.

SPMySite

Services

No local rights or SQL rights above Domain User.

SPService

Search Agent

No local rights or SQL rights above Domain User.

SPSearch

Search Crawl Access

No local rights or SQL rights above Domain User.

SPCrawl

Profile Access

No local rights or SQL rights above Domain User.

Provision Replicating Directory Changes permission (refer below)

SPProfile

Cache Admin

No local rights or SQL rights above Domain User.

SpCacheAdmin

Cache Reader

No local rights or SQL rights above Domain User.

SPCacheReader

Replicating Directory Changes permission to the Profile Service account.

We need to grant the Replicating Directory Changes permission on the domain to the Profile service account. This is the account that will be used to perform the sync.

The steps are as follows:

  • Run Active Directory Users and Computers tool
  • Right Click the Domain, choose Delegate Control… click Next

clip_image001

  • Add the service account in question, click Next

clip_image002

  • Select Create a Custom Task to Delegate, click Next and Next

clip_image003

  • Click Next
  • Select the Replicating Directory Changes permission and click Next
clip_image004
  • Click Finish

This is part of the solution, we also need to grant replicating directory changes on the Configuration Naming Context for the domain using the ADSIEdit.msc management console.

  • Connect to the Configuration Partition

clip_image005

  • Right click the configuration partition and choose properties

clip_image006

  • From the Security tab, add the service account and give it Replicating Directory Changes permissions

This should conclude the required AD changes.

clip_image007

SQL Server configuration for Remote Access

If you have your SQL Server on a separate machine then you will need to ensure you have opened appropriate SQL Server ports for remote access

You can follow     http://support.microsoft.com/kb/968872  ,  http://technet.microsoft.com/en-us/library/cc646023.aspx

From the SQL Server Configuration manager ensure to Enable Named Pipes and TCP/IP

clip_image008

Ensure to Restart SQL Server

On SharePoint 2013 Server

Windows 2012 Installed and Domain Joined

clip_image009

Service Account configuration

  • Login to the your new SharePoint Server with your domain or local administration account.
  • Add the SPSetup service account to be a local administrator.

From the Server Manager Choose Tools>Computer Management

clip_image010

clip_image011

clip_image012

Windows Settings Update

Update Folder settings from Windows Explorer

clip_image013

clip_image014

Prepare for Unattended SharePoint Install

  • Turn off windows prompt by typing “msconfig” and the PowerShell (Powershell can run all commands), “Tools” and launch “Change UAC Settings”.

clip_image015

clip_image016

clip_image017

  • Turn off warning on file open by typing “Run…” (Again from PowerShell prompt) “gpedit.msc”, “User Configuration”, “Administrative Templates”, “Windows Components”, “Attachment Manager”, “Inclusion list for low file types” and add “.exe;” to the list.

clip_image018

clip_image019

clip_image020

  • Restart the SharePoint Server

SQL Server Rights for System Accounts

Add Setup account with SysAdmin

clip_image021

Add the farm Admin domain account SPFarmAdmin to SQL Server with dbcreator and securityadmin roles.

clip_image022

clip_image023

Ensure SQL Connectivity from SharePoint Server

clip_image024

SPAutoInstall Configuration

  • The customized AutoSPInstaller structure requires a server specific installation configuration file.
  • Locate AutoSPInstallerInput.xml file located under the folder \AutoSPInstaller

clip_image025

  • Make a copy of the above side file and rename to with your server name exactly like AutoSPInstallerInput.xml-<YourServerNetBIOSName>.xml (Since the script run will auto pick up the script name based on the current server NetBIOS Name) Below you can see a I have renamed with my server name SP2013-Dev.

clip_image026

  • Next you can edit this base configuration file by following the example from Tobias Lekman blog here http://blog.lekman.com/2012/10/autospinstaller-prepare-scripts.html (Or use the new GUI tool to prepare the input xml file at http://AutoSPInstallerGUI.codeplex.com) which Tobias has mentioned as well.
  • For 2010 we all had hand crafted the XML input file and had taken while for eventually getting the formatting correct and having success with the script auto run. For the first few minutes as I started using the above mentioned GUI tool, I begin to like it how well it has been crafted (Thanks to Ivan). Has great tool tip support. As you select each service account, the program takes you right through the other related settings with highlight to point out other dependent settings. You will discover when you will use it. So I will not go in to more graphics and details. I would highly recommend using the GUI tool.
  • Below I will provide each screen details with GUI tool. Go ahead and run the downloaded (Extract after the download).
  • Open your machine Config file in the GUI tool.

clip_image027

clip_image028

  • The GUI tool tabifies each sections very nicely. So let's go from start…Install Tab.
clip_image029
  • Let the config.xml be as is. This refers to the existing config.xml under the

clip_image030

  • Choose all other options as necessary, ensure to enter you SPSetup Account password.
  • Farm Tab
  • Enter Passphrase where it is complex, otherwise your install will fail!
clip_image031
  • Enter all other settings as appropriate.

clip_image032

  • Let's look at the below settings for all Managed Accounts

clip_image033

  • This setting will require setting each account with your appropriate account. Let's start with the first one.
  • Before
clip_image034
  • After
clip_image035
  • Now click save.
  • Like wise choose the Portal App Pool account. Once you save the Portal App Pool account with the password, you will be switched to WebApplications Tab with the below message.

clip_image036

  • Now choose appropriate Portal App Pool

clip_image037

  • Save this tab and switch back to Farm Tab.
  • Next choose the Profile App Pool, this is nothing but your My Site App Pool
clip_image038
  • Next further ensure to choose My Site Host App pool.
clip_image039
  • Switch back to Farm tab and select and enter the Search Service account.

clip_image040

clip_image041

Update the Index Location to 15.0 from 14.0

C:\Program Files\Microsoft Office Servers\15.0\Data\Office Server\Applications

clip_image042

clip_image043

clip_image044

clip_image045

clip_image046

clip_image047

clip_image048

clip_image049

clip_image050

clip_image051

clip_image052

clip_image053

Review above updates and ensure the xml format is correct by simply opening the xml file in IE.

Skip the Forefront folder

clip_image054

clip_image055

clip_image056

clip_image057

clip_image058

clip_image059

clip_image060

clip_image061

clip_image062

clip_image063

http://www.toddklindt.com/blog/Lists/Posts/Post.aspx?ID=346

clip_image065clip_image064

Config.xml, enter SharePoint product Key

clip_image066

Run SharePoint Auto Install

  • Ensure you have logged in to your server with the SPSetup account.
clip_image067
  • If you Prepared your AutoSPInstaller folder somewhere else then copy the entire folder AutoSPInstaller to your local drive on the installing server.
  • If you are using virtualization this is the best time to take a base line Snapshot so that you can always come back to this point until you perfect your SPAutoInstall
  • Locate the local folder ..\AutoSPInstaller.
  • Run the AutoSPInstallerLaunch.bat script as an administrator.
  • Let the script run and complete (ETA ~40 Minutes)

clip_image068

clip_image069

clip_image070

  • Upon completion of the install, the script will auto run IE and open the Central Admin, Portal and My Site each in a separate tab.
  • Some time the auto browsed applications may result in error as the install and configuration was just taken place and that the services may be still spinning up.
Known Issue

You receive the following error message two times during the update installation process:

Microsoft SharePoint Foundation administration tool has stopped responding

This issue occurs after you put the update in the Updates folder on a Microsoft SharePoint server so that the update is installed automatically. However, the installation process is not affected when this issue occurs. To continue the installation process, click the Close the program button in the error message dialog boxes. Currently, Microsoft does not have a fix for this error.

From <http://support.microsoft.com/kb/2737983>

clip_image071

5-8 such above prompts. After words goes through fine.

Configuration Wizard UI is prompted, but at the powershell windows see below issue.

clip_image072

Cancel Config Wizard, Close all windows gracefully.

Re-run the auto install, this time the install completed with the CA, Portal and My Site opened in IE:

clip_image073

clip_image074

clip_image075

Technorati Tags:

3 comments:

Anonymous said...

Hello. We are using the new web-based gui for our installation, but the downloaded scripts installs the prerequisites, but then it opens up the productkey window - which i think it sholdnt, because we have entered the proper value in the file, and prompts us. From there it would be a default installation process, missing all the preconcofigured settings. Any suggestions why this might be? Help appreciated!

Anonymous said...

Hello. Using the new GUI we get stuck on the productkey window, which we find strange since we have entered the right pid value in the downloaded file. Any suggestions? Help would be appreciated!

Rajesh Agadi said...

@Anonymous above,

I have not used or tested the new Web Based GUI, so I cannot comment on that.
Under the SharePoint setup folder, edit config.xml file. Ensure that there is product key under . If not simply edit manually.

Hope this helps!
Rajesh