SQL Server – Unattended Installation of SQL Server 2012 Using Command Line

Many times we face a requirement to perform the unattended installation of SQL Server. In this post we will see the steps to perform the unattended installation of SQL Server 2012 using command line.

There are two ways to install the unattended installation of SQL Server 2012 using command line.

Setup.exe /ACTION=Install /FEATURES=SQL /InstanceID=… /IACCEPTSQLSERVERLICENSETERMS /INDICATEPROGRESS
  • Specify Configuration file that contains all the parameter require for installation :
Setup.exe /ConfigurationFile="C:\SQLConfig\ConfigurationFile.ini" /IACCEPTSQLSERVERLICENSETERMS /INDICATEPROGRESS

Now you can see second method is very and you don’t need to remember the each and all parameter after finalizing the configuration file once.

Now you here you will have question that how to create this Configuration file that contains all the parameter require for installation. It is very easy to create Configuration file.

Let’s create the Configuration file for unattended installation of SQL Server 2012.

  • Run the SQL Server 2012 setup as normally does.
  • Set all the configuration settings you want as per requirement while going through all of the pages of the setup wizard.
  • Once you reach the “Ready to Install” page, Setup will show you screen to review all of your configuration settings. At the bottom of same screen, you will see the path of the configuration file that is created by Installation wizard itself. You can simply copy that file path so that you can grab that configuration file. (Refer below given screenshot.)
SQL Server - Unattended SQL Server 2012 Installation Using Command Line

SQL Server – Unattended SQL Server 2012 Installation Using Command Line

  • Now Cancel Setup.

Now you have to do some changes in configuration file for unattended installation.

  • Removed the UIMODE Parameter that controls the user interface behavior. Valid values are Normal for the full UI,AutoAdvance for a simplied UI, and EnableUIOnServerCore for bypassing Server Core setup GUI block.
  • Set the QUIET = “True” (i.e. Setup will not display any user interface.)
  • Main point you have include all password parameters in this configuration file or you can pass the password parameter during the execution. For demonstration purpose, I have used the all password parameter in the configuration file.

Now you can execute the setup using above created configuration file.

Must refer the given Microsoft article for all the command line parameter and its detail.