Now imagine, you have multiple SQL Server 2012 instances to install with the same configuration on the multiple servers and you want this task to be done as quickly and consistently as possible. When this is the case, you may choose the unattended installation option. SQL Server unattended installation option lets administrators install SQL Server on multiple machines with little or no user interactions. SQL Server 2012 unattended installations can be done using command line parameters or configuration files. All SQL Server step-up screen entries and the dialog responses are made automatically by using information stored in the configuration file or by command-line parameters.
This article shows you the steps to perform unattended installation of SQL Server 2012 on a Windows Server 2008 system by using command line and configuration file.
Unattended SQL Server 2012 Installation From the Command Line
Follow the steps below, to perform new unattended installation of SQL Server 2012 instance on a Window Server 2008 from the command line:
Path: Start > All Programs > Accessories > Command Prompt
The Command Prompt window opens:
<Installation media location>\setup.exe /ACTION=install /QS /INSTANCENAME="<MachineName\InstanceName>" /IACCEPTSQLSERVERLICENSETERMS = 1 /FEATURES=SQLENGINE,SSMS /SQLSYSADMINACCOUNTS = "<YourDomain\Administrator>"
These command parameters are explained as follow:
/ACTION
Indicates the action to be performed.
/QS
Indicates that Setup runs and shows the installation progress. It accepts no input.
/INSTANCENAME
Indicates required instance name.
/IACCEPTSQLSERVERLICENSETERMS
Required to acknowledge acceptance of the license agreement.
/FEATURES
Required to specify individual SQL Server components to install.
/SQLSYSADMINACCOUNTS
Required to specify members of the sysadmin role.
Click here to view the complete list of command line parameters.
I executed the following command in the command line to perform stand-alone installation of SQL Server 2012 instance called UnattendedCmd, with the SQL Server Database Engine, Replication, and Full-Text Search components:
F:\setup.exe /ACTION=install /QS /INSTANCENAME="UnattendedCmd" /IACCEPTSQLSERVERLICENSETERMS=1 /FEATURES=SQLENGINE,SSMS /SQLSYSADMINACCOUNTS="IITCUK\SQLAdministrator"
Once the installation is completed, Launch SQL Server Configuration Manager or connect to instance via SQL Server Management Studio to verify installation (see below):
Remember: Make a note of the configuration file path on this final screen.
Open Windows Explorer and navigate to the folder where the configuration file is found:
Search ConfigurationFile.ini and copy it to a folder that can be used for unattended installations. For the purpose of this demo, I’m copying it to D:\ConfigurationFiles\ (see below):
QUIET="True"IACCEPTSQLSERVERLICENSETERMS="True"SQLSYSADMINACCOUNTS="YourDomain\Administrators"ADDCURRENTUSERASSQLADMIN="False"UIMODE="Normal"
<Installation media location>\Setup.exe /ConfigurationFile=<Configuration file location> /Q
I hope you will find the information of this post useful