SQL Server 2012 Installation
SQL Server 2012 Installation
SQL Server 2012 Installation
This article walks the user through installation of SQL Server 2012 on a Windows Server 2008 system using the SQL Server setup installation wizard. The installation process is simple, straight forward and is very similar to SQL Server 2008 / 2008 R2 setup. The procedure described is for a non-clustered server, and can be applied either to a default instance or a named instance. It is intended to be read by Database Administrators and anybody interested in the technical aspects of carrying out this task. Before beginning, you should check that minimum hardware and software requirements to install and run SQL Server 2012 have been met. For operating system and hardware requirements, visit: http://msdn.microsoft.com/en-us/library/ms143506.aspx. Preparing for Installation
Identify drives to which the databases and/or logs will be backed up, ensuring that there is enough disk space to accommodate the backups for the retention period that you choose. Identify drive that will be used for data or log files. These will usually be on SAN storage and hence on a different drive from the operating system and SQL Server installations. Decide which folder will be the primary location for data files: you will need to specify this during the installation. If you are installing Analysis Services, identify drives that will host the data and log files for the cube(s). Create dedicated service account for each of the service to be installed. Ensure that these accounts are not member of Local Administrator because it will give unnecessary rights to these accounts. Note: for the purpose of this tutorial Im using local system accounts as a service start-up accounts. Assign Deny logon locally right to these service accounts. Choose the port number for you SQL Server installation because common TCP\IP ports 1433/1434 ports are well known and are common target for hackers. Therefore it is recommended to change default ports associated with the SQL Server installation.
Installing SQL Server 2012 Insert the SQL Server installation media. From the root folder, double-click Setup.exe. To install from a network share, locate the root folder on the share, and then doubleclick Setup.exe:
The Installation Wizard runs the SQL Server Installation Center. To create a new installation of SQL Server, select the Installation option on the left side, and then click New SQL Server stand-alone installation or add features to an existing installation :
Now Setup Support Rules will run to identify problems that may occur during the Setup Support Files installation:
Once this step finishes click OK to proceed to Product Key window, In the Product Key window, enter the Product license key (if required), and click Next to continue:
In the License Terms window, tick the box I accept the license terms and then click Next to continue:
Note: You must accept the license agreement before you can continue the installation of SQL Server 2012. Send feature usage data to Microsoft option is optional. Click Next and then click Install to Install Setup Files:
These files are necessary to perform the actual installation. Following the installation of the setup support files, you will be presented with another compatibility check. Following dialog appears once you successfully pass these checks. You can click the Show Details button under the green progress bar if you want to see the individual checks listed:
Select SQL Server Feature Installation option and then Next to continue to Feature Selection page:
Im going to select all features so that we can walk through a complete installation process. This will install the Database Engine Services, Analysis Services, Reporting Services, and a number of shared features including SQL Server Books Online. You can also specify the shared feature directory where share features components will be installed. Click Next to continue to the Installation Rules page, Setup verifies the system state of your computer before Setup continues:
Click Next to continue to the Instance Configuration page. Each server machine can host one default instance of SQL Server, which resolves to the server name, and multiple named instances, which resolves to the pattern ServerName\InstanceName. In this sample installation, I will install a named instance of SQL Server 2012 called DEV01:
Note: This screen also report on other instances installed on this machine. Click Next to proceed to the Disk Space Requirements page:
This is just a information page that does not require you to make any choices. Click Next to go to Server Configuration page:
Here you specify service startup and authentication. Microsoft recommends that each service account have separate user accounts as a security best practice as shown in the following figure:
The SQL Server 2012 Books Online makes the following security recommendations:
Run separate SQL Server services under separate Windows accounts. Run SQL Server services with the lowest possible privileges. Associate SQL Server services with Windows accounts. Require Windows Authentication for connections to the SQL Server.
For the purposes of this article, we will authenticate all services using LocalSystem account. You may have noticed the Collation tab here in this page. Click Collation tab and then click Customize button to specify the collation for your Database Engine and Analysis Services instance that best matches your application need:
Click Next to continue to Database Engine Configuration page. The SQL Server 2012 authentication mode was configured for Windows Authentication Mode per Microsoft security best practice. For the purposes of this article, I will be choosing Mixed Mode Authentication. You will also need to specify the SQL Server administrators to be used; in this example I will use the current logged in user by clicking Add Current User button:
Click Data Dictionary tab and specify default database, log, backup, and tempdb locations:
FILESTREAM feature is quiet useful when binaries or other data that does not fit neatly in a table structure. Click Next to proceed to Analysis Services Configuration page, this is similar to Database Engine Configuration page. Specify users or accounts that will have administrator permissions for Analysis Services in Account Provisioning page and specify non-default installation directories in Data Directories page:
Click Next to continue to Reporting Services Configuration page, specify the kind of Reporting Services installation to create. For the purpose of this article, I will use Install and Configure option:
For more information about Reporting Services configuration modes and the options we have, see Reporting Services Configuration Options (SSRS). Click Next to proceed to Distributed Replay Controller page, specify the users you want to grant administrative permissions to for the Distributed Replay controller service and then click Next to continue:
Distributed Replay Client Configuration page appears, here specify setting as shown in next figure:
Click Next to advanced to Error Reporting page, tick the check box if you want to send Windows and SQL Server error reports to Microsoft:
Click Next, Now System Configuration Checker will run some more rules that will validate your computer configuration with the SQL Server features you have specified:
Correct any errors reported in the Installation Rules screen and click on Next to advanced to Ready to Install page. This page shows a tree view of installation options that were specified during Setup. On this page, Setup indicates whether the Product Update feature is enabled or disabled and the final update version:
Click Install button to start SQL Server 2012 installation. The Setup will first install the required prerequisites for the selected features followed by the feature installation. The Installation Progress page provides status so that you can monitor installation progress as Setup continues:
Click on the link to review the installation log if appropriate, then click on Close. This finalizes the installation process for SQL Server 2012.
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:
1. Logon to server as Administrator and then start the Command Prompt or Start the Command Prompt with elevated administrative privileges by right-clicking the Command Prompt icon in Programs list, and then click Run as Administrator:
Path: Start > All Programs > Accessories > Command Prompt
2. The following is the command syntax which you can use to perform the unattended installation of SQL Server Database Engine and SQL Server Management Studio tools:
3. 4. 5. 6. 7. 8. <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"
9. Once the installation is completed, Launch SQL Server Configuration Manager or connect to instance via SQL Server Management Studio to verify installation (see below):
Unattended SQL Server 2012 Installation From a Configuration File 1. The first step of the process is to create a configuration file which the SQL Server 2012 installer will use to answer all installation questions in a silent mode. To do that, insert the SQL Server installation media or locate the installation media on the network share. From the root folder, double click Setup.exe. 2. This Launches SQL Server Installation Center. Specify the options and parameters for your SQL Server 2012 installation by following the setup wizard until the Ready to Install screen and then simply cancel the installation at Ready to Install screen (see below):
Remember: Make a note of the configuration file path on this final screen. 3. Open Windows Explorer and navigate to the folder where the configuration file is found:
4. Search ConfigurationFile.ini and copy it to a folder that can be used for unattended installations. For the purpose of this demo, Im copying it to D:\ConfigurationFiles\ (see below):
5. Now modify ConfigurationFile.ini to prepare the file for unattended installation: o Set QUIET="True" o Add IACCEPTSQLSERVERLICENSETERMS="True" o Set SQLSYSADMINACCOUNTS="YourDomain\Administrators" o Remove ADDCURRENTUSERASSQLADMIN="False" o Remove UIMODE="Normal" 6. The last step is to use the configuration file with the command prompt for an installation of SQL Server 2012. To do that, open a command prompt and navigate to the location of the installation media and then execute the following command to perform the unattended installation of SQL Server 2012 using ConfigurationFile:
<Installation media location>\Setup.exe /ConfigurationFile=<Configuration file location> /Q
7. Once the installation is completed, Launch SQL Server Configuration Manager or connect to instance via SQL Server Management Studio to verify installation.