SQL Server 2012 silent install

SQL Server 2012 silent install – Install Dozens of them with one click.

This post is for SQL server DBAs who have done SQL server installations before but would like to make it more efficient. Before we get started let’s take a look at the following:

  • Background
  • Why Choose Silent Install
  • Preparation
  • Be careful with

If you can’t wait let’s get down to business here.

Background

One of the responsibilities of a SQL Server DBA is to install & configure Microsoft SQL server. SQL Server stores configuration information in a Configuration.INI file typically in

C:\Program Files\Microsoft SQL Server\110\Setup Bootstrap\Log

We can use this file directly or as a template to install SQL server via CMD without GUI. Especially if you are a DBA in a very large enterprise you might be required to suggest a customization for SQL server install so that it can be installed on dozens of servers. In such situations where you have to install it on multiple servers you can go with silent install and a smart DBA always saves time to invest the same on more challenging issues.

Why Choose Silent Install

  • Unattended

You don’t have to sit there clicking next or configuring database file locations, service accounts etc.

  • Consistency

Often times DBAs receive requests to install SQL server on multiple servers with exact same configuration.

  • Time

You can save a lot of time compared to the traditional installation.

Preparation

Here is some basic prep work you need to be prepared for the silent install

1. SQL Server 2012 Binaries

2. Configuration.ini file

3. Service Account/s Credentials

4. SA password

Here is a template of configuration file for you. You can download this file and edit the file as per your needs.

You can get very specific with configuration file but here are some high level settings you should consider

· Features – Database Engine, BIDS, Services ect

· Data, Log & Backup file locations

· All service accounts & their passwords

Be careful with

Service account getting locked: Please test this install thoroughly because there is a risk of service account getting locked if password is mistyped and the installation is re-tried.

Secure the passwords: You will be invoking the setup.exe of SQL server 2012 via CMD and pass service accounts and SA passwords as parameters; though the passwords are encrypted in the final configuration file is created after the install, the invoking part will expose the passwords so be advised.

SQL server 2012 Silent Install

Prepare INI file

You can use this file or you can go to an existing SQL server installation and locate the INI file here:

INIFilelocaTION

Edit the INI file as follows

; Remove/comment this parameter when using Quiet mode
;UIMODE="AutoAdvance"
A prefix of ; comments the line
; Setup will not display any user interface.
; You can make either QUIET or QUIETSIMPLE to be TRUE not BOTH
QUIET="True"
; Setup will display progress only, without any user interaction.
QUIETSIMPLE="False"

Agree to the terms & conditions by adding this line at the end of the file

; Accept the terms & conditions
IACCEPTSQLSERVERLICENSETERMS="True"

Invoke Setup.exe from command prompt

Once your config file is ready open command prompt & browse to the location of SQL server binaries and when you are in the directory which contains setup.exe, start the install by running the following command:

Setup.exe /SAPWD="Z87C0ptr@n34" /SQLSVCPASSWORD="password" /AGTSVCPASSWORD="password" /ISSVCPASSWORD="password" /ASSVCPASSWORD="password" /RSSVCPASSWORD="password" /ConfigurationFile=C:\ConfigurationFile.ini

The parameters we are providing via above command are

SAPWD Password for System Administrator
SQLSVCPASSWORD SQL Server Service Account’s password
AGTSVCPASSWORD SQL Agent Service Account’s password
ISSVCPASSWORD Integration Services Service Account’s password
ASSVCPASSWORD Analysis Services Service Account’s password
RSSVCPASSWORD Reporting Services Service Account’s password

Monitor the progress

Well, there is no point in monitoring the progress because we did so much just for the reason that our future installs are accurate and unattended. Anyone who installed SQL server knows how much time it takes and how many windows it goes through I would guess approximately a dozen different screens, this is all you get with silent install:

CMDP

Of course INI file you prepared can be used for future installs. So your next install is as simple as copy INI file & binaries on the server and run one command and reboot the server.

For those who do not trust that the install is actually going on, here is what you see when the install is going on:

Screenshot_3

And this is what you should see once the install is complete:

TSKMGR

Enjoy your installation 🙂

More

· Consider putting the command in a BAT file that way

o You can get before & after time to tell you the time taken.

o You can schedule it to run at a time of your choice.

· Getting errors?

o Go to

C:\Program Files\Microsoft SQL Server\110\Setup Bootstrap\Log\Summary.txt
[\code]
to check for the detailed error messages.

· Want to know the A-Z of Silent install?

o Go here: http://msdn.microsoft.com/en-us/library/dd239405.aspx

Let me know here from your comments if it worked or you had problems. Feel free to post any suggestions for improvement.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s