Overview of SQL Server Servicing Installation

You can apply an update to any installed SQL Server 2012 component with a SQL Server 2012 servicing update. If the version level of an existing SQL Server 2012 component is later than the update version level, the Setup program will exclude it from the update. For more information on applying a servicing update, see Install SQL Server 2012 servicing updates (https://go.microsoft.com/fwlink/?LinkId=231297).

The following considerations apply when you install SQL Server 2012 updates:

  • All features that belong to an instance of SQL Server must be updated at the same time. For example, when you update the Database Engine, you must also update Analysis Services and Reporting Services components if they are installed as part of the same instance of SQL Server. Shared features, such as Management Tools, SQL Server Data Tools (SSDT), and SQL Server Integration Services, must always be updated to the most recent update. If a component or instance in the feature tree is not selected, the component or instance will not be updated.

  • By default, SQL Server 2012 update log files are saved to %Program Files%\Microsoft SQL Server\110\Setup Bootstrap\LOG\.

  • SQL Server setup can now integrate an update with the original media to run the original media and the update at the same time. For more information, see Product Updates in SQL Server 2012 Installation and What’s New in SQL Server Installation(https://go.microsoft.com/fwlink/?LinkID=219508).

  • Before you apply a SQL Server 2012 servicing update, we recommend that you consider backing up your data.

  • SQL Server updates are available through Microsoft Update. We recommend that you scan for updates regularly to keep your instance of SQL Server updated and secure.SQL Server 2012 SP1 is being provided as a complete SQL Server Installation. Rather than providing the Service Pack in the standard Patch executable package to be applied to SQL Server 2012 RTM instances, for this release, an installation package (consisting of 2 files) is provided. When executed, this will install a new instance of SQL Server 2012 with SP1 pre-installed. For more information, see the SQL Server 2012 SP1 Full Installation.

Requirements and Known Issues

The recommended disk space requirements are approximately 2.5 times the size of the package to install, download, and extract the package. After installing a service pack, you can remove the downloaded package. Any temporary files are removed automatically.

Review the known issues: For more information about the known issues for the current release, see the corresponding release notes topic here: SQL Server Release Notes.

Installation Overview

This section discusses the SQL Server 2012 installation for cumulative updates and service packs, including how to do the following:

  • Prepare for a SQL Server 2012 update installation

  • Install SQL Server 2012 updates

  • Restart services and applications

Prepare for a SQL Server 2012 Update Installation

We strongly recommend that you do the following before you install SQL Server 2012 updates:

  • Back up your SQL Server system databases — Before you install SQL Server 2012 updates, back up the master, msdb, and model databases. Installing a SQL Server 2012 update changes these databases, making them incompatible with earlier versions of SQL Server 2012. Backups of these databases are required if you decide to reinstall SQL Server 2012 without these updates.

    It is also prudent to back up your user databases.

    Important

    When you apply updates to instances of SQL Server that participate in a replication topology, you must back up your replicated databases together with your system databases before you apply the update.

  • Back up your Analysis Services databases, configuration file, and repository — Before you update an instance of Analysis Services, you should back up the following:

    • Analysis Services databases. By default, these are installed to C:\Program Files\Microsoft SQL Server\MSAS11.<InstanceID>\OLAP\Data\. For WOW installation, the default path is C:\ProgramFiles (x86)\Microsft SQL Server\MSAS11.<InstanceID>\OLAP\Data\.

    • Analysis Services configuration setting in the msmdsrv.ini configuration file. By default, this is located in the C:\Program Files\Microsoft SQL Server\MSAS11.<InstanceID>\OLAP\Config\ directory.

    • (Optional) The database that contains the Analysis Services repository. This step is required only if Analysis Services was configured to work with the Decision Support Objects (DSO) library.

    Note

    Failure to back up your Analysis Services databases, configuration file, and repository will prevent you from reverting an updated instance of Analysis Services to the earlier version.

  • Verify that the system databases have sufficient free space — If the autogrow option is not selected for the master and msdb system databases, these databases each must have at least 500 KB of free space. To verify that the databases have sufficient space, run the sp_spaceused system stored procedure on the master and msdb databases. If the unallocated space in either database is less than 500 KB, increase the size of the database.

  • Stop Services and Applications — To avoid a possible restart of the system, stop all applications and services that make connections to the instances of SQL Server that are being upgraded, before installing SQL Server 2012 updates. These include SQL Server Management Studio, SQL Server Data Tools (SSDT). For more information, see Start, Stop, Pause, Resume, Restart the Database Engine, SQL Server Agent, or SQL Server Browser Service.

    Note

    You cannot stop services in a failover cluster environment. For more information, see the failover cluster installation section later in this topic.

  • To eliminate the requirement to restart your computer after update installation, Setup will show a list of processes that are locking files. If the update Setup program must end a service during installation, it will restart the service after the installation finishes.

  • If Setup determines that files are locked during installation, you might have to restart your computer after the installation finishes. If it is required, Setup prompts you to restart your computer.

Install SQL Server 2012 Updates

This section describes the installation process.

Important

SQL Server 2012 updates must be installed under an account that has administrative privileges on the computer where they will be installed. For local installations, you must run Setup as an administrator. If you install SQL Server from a remote share, you must use a domain account that has read and execute permissions on the remote share.

Starting a SQL Server 2012 Update

To install a SQL Server 2012 update, run the self-extracting package file.

Cumulative update package (CU): <SQLServer2012>-KBxxxxxx-PPP.exe

Service pack package (PCU): <SQLServer2012><SPx> -KBxxxxxx-PPP-LLL.exe

  • x indicated service pack number

  • PPP indicates the specific platform.

  • LLL indicates the character abbreviation for the SQL Server language, for example: LLL for English is ENU.

To apply updates to SQL Server 2012 components that are part of a failover cluster, see the section for failover cluster installation. For more information about how to run an update installation in unattended mode, see Installing Updates from the Command Prompt.

Product Updates in SQL Server 2012 Installation

Product Update is a new feature in SQL Server 2012 Setup. It integrates the latest product updates with the main product installation so that the main product and its applicable updates are installed at the same time. Product Update can search Microsoft Update, Windows Server Update Services (WSUS), a local folder, or a network share for applicable updates. After Setup finds the latest versions of the applicable updates, it downloads and integrates them with the current SQL Server setup process. Product Update can pull in a cumulative update, service pack, or service pack plus cumulative update. Product Update functionality is an extension of the Slipstream functionally that was available in SQL Server 2008 PCU1. For more information about Product Updates functionality in SQL Server 2012 Setup, see Product Updates in SQL Server 2012 Installation.

SQL Server 2012 SP1 Full Installation

SQL Server 2012 SP1 is also available as a complete SQL Server Installation package. The SQL Server 2012 SP1 installation package will install a new instance of SQL Server with SP1 preinstalled.

The package has an executable and installation files in compressed format. The package has files of the form: SQLServer2012SP1-<Architecture>-<Language>.exe and SQLServer2012SP1-<Architecture>-<Language>.box.

Review the following instructions while installing SQL Server 2012 SP1:

  • Download the following files from the download page to a temporary directory on your device:

    • SQLServer2012SP1-architecture-language.box

    • SQLServer2012SP1-architecture-language.exe

  • Once the download(s) are complete, double click on the SQLServer2012SP1-<architecture>-<language>.exe to begin the installation process.

  • On the Choose Directory for Extracted Files dialog, the default directory path is prepopulated: <Current drive>\<Current working folder>\<Package name>. For example, %temp%\SQLServer2012SP1-x64-ENU\. Click Browse to change the directory path for the extracted files.

  • The package decompresses to the specified installation path and would be left behind in the selected directory path after the installation completes. A user will be able to use the binaries in the extracted folder for future Installations.

  • The Installation Wizard runs the SQL Server Installation Center. Follow the installation instructions from Install SQL Server 2012 from the Installation Wizard (Setup) (https://msdn.microsoft.com/library/ms143219.aspx).

The following table has some of the command line parameters which can be used for extracting the SQL Server 2012 SP1 package:

For detailed list of supported command line parameters that can be directly provided to the SP1 package, see Install SQL Server 2012 from the Command Prompt (https://msdn.microsoft.com/library/ms144259.aspx)

Parameter

Description

/x or -x

Opens the Choose Directory for Extracted Files dialog, and then extracts the package to the specified path.

It does not run setup.

/x:<path> Or -x:<path>

Extracts the package to the specified path and it does not launch setup.

/q or -q

Specifies that Setup runs in a quiet mode without any user interface. This is used for unattended installations.

/l:<path> Or -l:<path>

By default the log file is stored in the temp directory with the name SQLServer2012SPx-<Architecture>-<Language>_decompression_log.txt

Use this parameter to generate the extraction log file to a specified path.

For example:

SQLServer2012SP1-x64-ENU /x /l:<path>

This option should only be used in conjunction with /x or –x or /x:<path> or -x:<path>

Updating a Prepared Image of SQL Server

You can apply an update to an unconfigured prepared instance of SQL Server without completing the configuration of the prepared instance. Different ways of applying an update to a prepared instance of SQL Server are explained below:

  • Updating a previously prepared instance of SQL Server

    Updates to a prepared instance can be applied to prior to configuration. The update package detects that the instance is in the prepared state and apply the patch to the prepared instance, without completing the configuration.

  • Updates to a prepared instance using Microsoft Update:

    You can apply updates to a prepared instance of SQL Server through Microsoft Update. The Microsoft Update package will detect that the instance is in the prepared state and apply the patch to the prepare instance without completing the configuration.

If you are updating a prepared image of SQL Server, you will need to specify the InstanceID parameter. For more information and sample syntax, see Installing Updates from the Command Prompt.

Updating a Completed Image of SQL Server

Updating a completed and configured instance of SQL Server follows the same processes as any other installed instances of SQL Server.

Rebuilding a SQL Server 2012 Failover Cluster Node

If you must rebuild a node in the failover cluster after updates were applied, follow these steps:

  1. Rebuild the node in the failover cluster. For more information about rebuilding a node, see Recover from Failover Cluster Instance Failure.

  2. Run the original SQL Server 2012 Setup program to install SQL Server 2012 on the failover cluster node.

  3. Run SQL Server 2012 updates Setup on the node that you have added.

Restart Services and Applications

When the Setup program is finished, it might prompt you to restart the computer. After the system restarts, or after the Setup program finishes without requesting a restart, use the Services node in Control Panel to restart the services that you stopped before you applied the SQL Server 2012 updates. This includes services such as Distributed Transaction Coordinator and the Microsoft Search services, or instance-specific equivalents.

Restart the applications that you closed before you ran SQL Server 2012 update Setup. You might also want to make another backup of the upgraded master, msdb, and model databases immediately after successful installation.

Uninstalling updates from SQL Server 2012

You can uninstall SQL Server 2012 cumulative updates or service packs from Programs and Features in Control Panel. To view the list of updates installed, open Installed Updates by clicking the Start button, clicking Control Panel, clicking Programs, and then, under Programs and Features, clicking View installed updates. Each cumulative update is listed separately. However, when a service pack is installed that is higher than the cumulative updates, the cumulative update entries are hidden and become available only if you uninstall the service pack.

To uninstall any service packs and updates, you must start with the latest update or service pack applied to the instance of SQL Server and work backward. In each of the following examples, SQL Server ends up with Cumulative Update 1 after uninstall has been completed for the other service packs or updates:

  • For an instance of SQL Server 2012 with Cumulative Update 1 and SP1 installed, uninstall SP1.

  • For an instance of SQL Server 2012 with Cumulative Update 1, SP1, and Cumulative Update 2 installed, uninstall Cumulative Update 2 first and then uninstall SP1.

See Also

Other Resources

Install SQL Server 2012 from the Command Prompt

Install SQL Server 2012 servicing updates

Validate a SQL Server Installation

View and Read SQL Server Setup Log Files