How to apply ESU patches to your SQL Server 2012 servers
Tags: azure
Published: 2024-02-16 10:49:26

 ![How to apply ESU patches to your SQL Server 2012 servers](https://www.techielass.com/content/images/2024/02/How-to-apply-ESU-patches-to-your-SQL-Server-2012-servers.png)

When running End of Support servers or SQL installs, it’s important to ensure you are receiving security patches for these servers/installs. It's also important to be actively planning to replace them with newer versions. 

In this blog post we walk through the process of ensuring you are subscribed to the relevant SQL Server 2012 Extended Security Updates (ESU) via [Azure Arc](https://www.techielass.com/tag/azure-arc/). As well as walking you through the process of finding the latest patches and applying them.

## Prerequisites

- Azure Subscription
- [<u>Azure Arc installed on your server</u>](https://www.techielass.com/register-and-manage-linux-servers-with-azure-arc-tutorial/)
- [<u>Azure Extension for SQL Server enabled on the server</u>](https://www.techielass.com/register-and-manage-linux-servers-with-azure-arc-tutorial/)
- Subscribe to Extended Security Updates (ESU) for SQL Server

## SQL Server Configuration

To receive patches for your SQL Server 2012 installs you need to subscribe to receive the Extended Security Updates (ESU).  

You must ensure that you have configured the “Licence Type” correctly and subscribed to the Extended Security Updates (ESU). 

You can check this by following these steps:

Open your Azure Portal

Select the Azure Arc management blade

![How to apply ESU patches to your SQL Server 2012 servers](https://lh7-us.googleusercontent.com/PzFKwNCZCqKQOsTiVHt4FNbafk4Bv2Zbp8lghbKHuqoXfwT5oi68aEQeTdb3SWABjr_iUdXtJ6yQPE05A7Ei649WkBOqrgy4Ry9Io8X2ttF_BT9FV1pVTYnClqF0g0WHItYzCIj2lVmZJ8uxles8gR2PgtGRKuaWS5XmBrnbB3vA2vBkKhNVB3q3W_CK6Q)
_Azure Portal_

Click on SQL Server Instances down the left-hand side

![How to apply ESU patches to your SQL Server 2012 servers](https://lh7-us.googleusercontent.com/w41atqqwLoOVsHeVnDSLEd1MfBHRuLX7WWDIKMBtbSbAzIjGqPSO3d-WwLK_K3IH6G48TnaoUlDhxM5tzzQt3O1APmnJfptFc1pp_Hn7hLZidAnLHAollNorpHplJJY3OenszRyJP049HKSVn38sfclca-TOswMaH3rR2qbuG6WgX5XV6Uac73QYd8gFWw)
_Azure Arc portal._

Select a SQL server

Under SQL Server configuration you should see the licence type has been configured and the ESU subscription is Enabled

![How to apply ESU patches to your SQL Server 2012 servers](https://lh7-us.googleusercontent.com/QO4Qa4fojWv_YIgk-vbac0E1v18wFgXm5DyMMX6ZRrPcUc2oMBWVCeB5H9uBHZx4ZF9iWhex2ttAECJ6PBuxDBYz8ssowUalGEXTwMDp9aTy9x3wlHOgkKJ8efbBoGlC8eoy0QMxEme_bIe1jvn31IxTvY0X23d-ezMN0p86ZmLMkEWIrX-nMZP8syuK1Q)
_Azure Arc enabled SQL server_

If these settings are not applied, or set you can click on SQL Server configuration to correct this and set the required settings. 

## Download the Extended Security Updates for SQL Server 2012

Once you have subscribed to the ESU subscription the service will take a few moments to update and provide feedback to you regarding the available patches for your server.   Once this update has happened under the “Security” section on the left-hand side menu you will see an option called Extended Security Updates. 

If you select this you will be shown a list of updates available for you to download and install on your server. 

![How to apply ESU patches to your SQL Server 2012 servers](https://lh7-us.googleusercontent.com/4XEEj77m5YEoPxJcjycytSOMAY4T05yT76adoubUxVhcDsnDrKAY7u3BD1xUARFZrDTqdWpV55vgVBlK15IzQmUyXJ3iOGp7p_USkpBpJ1McJqYgQfMEgLsyFn1BmW3q2SXw44lirgsD7F356nFM3R4366IYT9M5kDWSmoFpuANZJatWn3rX4bh838RoQw)
_Extended Security Updates for SQL server_

In this example, I am being shown two patches. They are the same patch, but one is relevant to x64 architecture and one for x86 architecture.  _You would only need to download and apply the patch relevant to your architecture. _

In this scenario, I am running a x64 server so I would use the download link for the x64 patch, which is the top one in the screenshot. 

By clicking on the download link I get an .exe file that I can manually install on my server. 

## Install Extended Security Updates for SQL Server 2012

With the patch, or exe file downloaded you can now install it on your server.   To do this double check on the exe. 

You will be prompted by a security warning asking if you want to proceed, click on Run. 

The file will start to extract and launch the install wizard. 

![How to apply ESU patches to your SQL Server 2012 servers](https://lh7-us.googleusercontent.com/pDkFDfqxTzE63N7b32uWKih5gB0-ncf4RDWvJI6m8DhyB_ZDrgrO2FH801HoffLGKB1O2053na1CvLek38dtHGo3asY7C__RyKyH0prpFaisPvZCLWNMHGd4ZMuy4YR7Kqe1nlMTcHqY6sRWwPi0lVov5S9Wqb1dvAmdYe2eZN0I8nxt7VuuZ4gxqETI5A)
_Install extended security update on SQL_

Walk through the install process as directed, and the patch will install successfully. 

![How to apply ESU patches to your SQL Server 2012 servers](https://lh7-us.googleusercontent.com/Y6MLmrJmWpB7JLB5ls65fAOJeCzM5ykxT9ZSzKBtT-64a6wZRO3xPLkvTIvZ6GZWZAcxwE0BnZdY_Dr8d2BnZ1mhiLnNQirjCcZBMXyIXUUYCLsqqn2EP4EiVCWROv0uBgxpfLBmwHMnjOdwBKJD24OoXMIZv4XlzHTrqBQZyxccwQp-FN9njTJuNr8xzg)
_Install extended security update on SQL_

## Check an Extended Security Updates for SQL Server 2012 has been installed

To check if the patch has been installed correctly you can open up SQL Management Studio and connect to your instance. 

Open up a New SQL query and type in:

```
select @@version

```

When you execute this query it will respond with the SQL version.  It should denote the last patch you installed.  In this example the patch I installed was KB5021123 and when I executed the query I got the output:

![How to apply ESU patches to your SQL Server 2012 servers](https://lh7-us.googleusercontent.com/5gd6HI8D6LLkaUMCq-QHkcEJtyyCOZFoEzH3hkv8cOB3F3itjEfjh6cgbtMdEbsInKU1GzBC4T6IglefoNLrGbt0nGOUYirZ0a75HD4n5MDLDSol25QcHWN65DQ5DpiqrYuBbeLPNmZRXPF5yj45Vq21aAC2s1CnHvCK2BaGNM2ajeasH67d8EJ9nJukcw)
_SQL version query_

The version has been updated with the patch. 

## Conclusion

In conclusion, ensuring the security and functionality of your End of Support servers and SQL installs is paramount. 

By following the steps outlined in this blog, from subscribing to Extended Security Updates via Azure Arc to downloading and installing the latest patches, you can confidently keep your environment protected and up-to-date. 

Stay proactive in managing your server infrastructure to mitigate risks and ensure smooth operations for your organization.