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:

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:

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

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:

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:

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

µ

2 Comments

  1. Brian Lewis

    Great article Mike! I wondered how to install SQL on a server core installation. Installing from the command line becomes even more important in the next version of Windows Server where I expect a lot more people to work without the GUI. – Thanks Brian

    Reply

Leave a Reply

%d bloggers like this: