SQL Server - Patch Installation Failure
Description
SQL Server patch deployment can fail because of system-level or application-level issues. Use the causes and resolutions below to identify pending restarts, conflicting processes, missing system files, antivirus interference, or incorrect SQL Server settings and restore patch deployment.
A system restart is required before patch deployment
Cause
A reboot is pending on the client machine.
Resolution
Restart the affected machine and redeploy the patches.
Cluster problems due to inactivity
Cause
An inactive cluster is preventing the SQL Server patch installation.
Resolution
Open Windows PowerShell as an administrator and run these commands:
Get-WindowsFeature RSAT-Cluster*
Install-WindowsFeature -Name RSAT-Clustering-AutomationServer
Get-WindowsFeature RSAT-Cluster*If the issue persists, install the update manually. If the manual installation also fails, contact Microsoft Support.
Another instance is running
Cause
Another installation instance is already running on the machine.
Resolution
Restart the machine and redeploy the patch. If the issue continues, contact support with the agent logs and SQL Server logs.
SQL Server DLL files are locked
Cause
The installer cannot access one or more locked SQL Server DLL files.
Resolution
Contact support with the agent logs and SQL Server logs to identify the locked DLL and determine the appropriate resolution.
SQL Server registry key is corrupted
Cause
SQL Server registry keys were modified, or the default database and log directories are not defined correctly.
Resolution
Restart the machine and retry the deployment. If the issue persists, repair the SQL Server installation and deploy the patch again.
Restart required for pending file operations
Cause
The system must restart to complete pending file operations. Until it restarts, the affected file operations remain incomplete.
Resolution
Restart the machine up to two times. If the issue persists, follow these steps:
- Open Registry Editor by running regedit.
- Navigate to HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager.
- Delete the PendingFileRenameOperations value.
- Close Registry Editor, restart the machine, and retry the installation.
Windows Installer cache files are missing
Cause
One or more Windows Installer cache files required by SQL Server are missing.
Resolution
Option 1: Restore files from the original source
- Use FixMissingMSI or FindSQLInstalls.vbs from GitHub to identify the missing MSI files.
- Restore the missing files from the original source media.
Option 2: Restore files from the patch package
- Identify the missing files from the error messages, setup logs, or registry entries.
- Download the relevant patch package from the Microsoft Support website.
- Add the required contents from the patch package to the Windows Installer cache.
Deployment is blocked by antivirus software
Cause
Antivirus software is blocking the SQL Server patch deployment.
Resolution
Exclude the required folders from antivirus scans or temporarily disable the antivirus software, and then redeploy the patches. Re-enable protection immediately after testing.
Database engine is offline
Cause
The SQL Server database engine is offline.
Resolution
- Completely uninstall SQL Server using Add or Remove Programs.
- Delete the remnants of previous failed installation attempts.
- Run setup.exe from the SQL Server installation directory to perform a clean installation.
Application is corrupted
Cause
The affected application is corrupted and cannot complete the requested function.
Resolution
Repair the affected application on the client machine and retry the patch deployment.