Installation of SQL Server Features from the Command Line

I’m installing a line of business application that requires the SQL Server Management Studio and Client Tools Connectivity be installed as a prerequisite. I want to script this instead of having to manually click through the GUI for the installation since this will be installed on several servers. I’ve mounted the SQL Server 2008 R2 ISO on “Z” drive. The following command will produce the desired results:

Setup.exe /qs /ACTION=Install /FEATURES=SSMS,CONN /IACCEPTSQLSERVERLICENSETERMS

ssms-conn11.png

At first, I thought that the CONN parameter was incorrect because it also added the SQL Client Connectivity SDK, but upon further review the GUI installation does the same thing:

ssms-conn12.png

Using the command line or the GUI for the installation will show that the SQL Client Connectivity SDK was installed:

ssms-conn13.png

Let’s say you’re not sure of the feature names of the options you want to install, you want more than these two options installed, or you want to simplify this process even more. Use the GUI on the first server to do the installation. This will create a configuration ini file:

ssms-conn14.png

Copy this configuration file and use it on the other servers to do an unattended installation. You’ll need to change the QUIETSIMPLE parameter to True and remark out the UIMODE property by placing a semicolon at the beginning of that line. Specifying the /QS parameter from the command line won’t work since those options are set in the ini file:

ssms-conn15.png

Setup.exe /CONFIGURATIONFILE="C:\tmp\ConfigurationFile.ini" /IACCEPTSQLSERVERLICENSETERMS

ssms-conn16.png

A list of the parameters to install SQL Server 2012 from the command line can be found on MSDN.

ยต