Note
Access to this page requires authorization. You can try signing in or .
Access to this page requires authorization. You can try .
KB5038325 - Cumulative Update 14 for SQL Server 2022
Release Date: July 23, 2024
Version: 16.0.4135.4
Summary
This article describes Cumulative Update package 14 (CU14) for Microsoft SQL Server 2022. This update contains 12 fixes that were issued after the release of SQL Server 2022 Cumulative Update 13, and it updates components in the following builds:
- SQL Server - Product version: 16.0.4135.4, file version: 2022.160.4135.4
- Analysis Services - Product version: 16.0.43.233, file version: 2022.160.43.233
Known issues in this update
Issue one: Patching error for secondary replicas in an availability group with databases enabled replication or CDC
SQL Server 2022 CU13 introduced fix 2998350 to make secondary databases in an availability group (AG) startup more reliably. However, this fix causes a problem where AG databases don't start recovery if SQL Server is running in single-user mode. SQL Server Setup runs in single-user mode. As a result of this, if you run Setup and also have SQL replication or change data capture (CDC) enabled on a database in the AG, when the catalog upgrade scripts try to run but can't access the database, setup fails.
After SQL Server Setup initially fails, the SQL Server service then tries to come online again without single-user mode. At that time, the patch upgrade scripts finish successfully and patching is complete. Once startup completes, the issue is resolved and no user action is required.
The patch fails with the following error:
Error installing SQL Server Database Engine Services Instance Features
Wait on the Database Engine recovery handle failed. Check the SQL Server error log for potential causes.
Error code: 0x851A001A
When you check the SQL Server error log, you see a message with an invalid Group ID. To verify it's an invalid ID, look for previous startup records in the same log file for the problematic database name to compare:
Skipping the default startup of database <DatabaseName> because the database belongs to an availability group (Group ID: <GroupID>). The database will be started by the availability group. This is an informational message only. No user action is required.
If you want to prevent the patch from reporting an initial failure, you can perform one of the following actions before running the patch:
Enable Trace Flag 12347 - reverts the changes made in fix 2998350. You should remove this trace flag after patching.
Drop the CDC or replication enabled database from the AG.
Remove CDC or replication from the database in the AG.
This issue is fixed in SQL Server 2022 CU16.
Issue two: SQL Server VSS Writer might fail to perform a backup because no database is available to freeze
When backup tools such as Azure Recovery Vault perform a backup on a virtual machine (VM), they might fail to achieve application consistency. There might not be any errors. The application runs fast without any backups being done. The SQL Server Volume Shadow Copy Service (VSS) Writer ends up in a non-retryable error state. If you enable SQL Server VSS Writer trace, you might see the following exception, which indicates there's no database to freeze, resulting in an unsuccessful snapshot:
[0543739500,0x002948:011b4:0xb87fa68e] sqlwriter.yukon\sqllib\snapsql.cpp(1058): Snapshot::Prepare: Server PROD-SQL01 has no databases to freeze
Additionally, some databases might be detected with Online:0:
[0543739390,0x002948:0x11b4:0xb87fa68e] sqlwriter.yukon\sqllib\snapsql.cpp(0408): FrozenServer::FindDatabases2000: Examining database <ReportServerTempDB>
Online:0 Standby:0 AutoClose:0 Closed:0
If you use Azure Recovery Vault, you might see an error like the following one in the event list:
App-consistent recovery point generation failed.
The issue arises from a code change in SQL Server 2022 CU14 that checks if a database is online and ready to be frozen. The current solution is to roll back to SQL Server 2022 CU13 and perform the snapshot backup. For more information about how to roll back the package to a previous version, see Uninstall a Cumulative Update from SQL Server.
This issue is fixed in SQL Server 2022 CU15.
Issue three: Incorrect behavior of SESSION_CONTEXT in parallel plans
Queries that use the built-in SESSION_CONTEXT function might return incorrect results or trigger access violation (AV) dump files when run in parallel query plans. This issue occurs because of the manner in which SESSION_CONTEXT interacts with parallel execution threads, particularly if the session is reset for reuse.
For more information, see the Known issues section in SESSION_CONTEXT.
Improvements and fixes included in this update
A downloadable Excel workbook that contains a summary list of builds, together with their current support lifecycle, is available. The Excel file also contains detailed fix lists for SQL Server 2022, SQL Server 2019, and SQL Server 2017. Select to download this Excel file now.
Note
Individual entries in the following table can be referenced directly through a bookmark. If you select any bug reference ID in the table, a bookmark tag is added to the URL by using the "#NNNNNNN" format. You can then share this URL with others so that they can jump directly to the desired fix in the table.
For more information about the bugs that are fixed and enhancements that are included in this cumulative update, see the following Microsoft Knowledge Base articles.
| Bug reference | Description | Fix area | Component | Platform |
|---|---|---|---|---|
| 3217208 | Starting with SQL Server 2022 (16.x) CU14, container images include the new mssql-tools18 package. The previous directory /opt/mssql-tools/bin is phased out. The new directory for Microsoft ODBC 18 tools is /opt/mssql-tools18/bin, aligning with the latest tools offering. For more information about changes and security enhancements, see ODBC Driver 18.0 for SQL Server Released. | SQL Server Client Tools | Command Line Tools | Linux |
| 3110961 | Fixes an issue in which maintenance plan logs might report garbled characters when the message reported involves non-ASCII characters. | SQL Server Client Tools | Management Services | Windows |
| 3278705 | Fixes the following error that you encounter during a Volume Shadow Copy Service (VSS) restore on a SQL Server instance that has previously deleted databases: Volume Shadow Copy Service error: Unexpected error calling routine GetVolumePathName is fail on the path <PathName> ... The system cannot find the file specified. |
SQL Server Engine | Backup Restore | Windows |
| 3285752 | Fixes an issue in which the SQL Server Launchpad service can't shut down properly when certain errors occur during startup. | SQL Server Engine | Extensibility | Windows |
| 2897811 | Fixes an issue in which the remote secondary replica shows Not Synchronizing for several minutes after successive failovers between local replicas. It occurs when configured in multi-subnet, multi-region configurations in the cloud with two or more local replicas and one or more remote replicas. | SQL Server Engine | High Availability and Disaster Recovery | Windows |
| 3088149 | Fixes an assertion dump issue (Location: hadrlogcapture.cpp:<LineNumber>; Expression: m_pFsManager->GetEnqueuedBlockId () < capturedLogBlockId || capturedLogBlockId == m_pDbPartner->GetFirstLogBlockIdToCapture ()) that you encounter when there are FILESTREAM transactions in an Always On availability group (AG). | SQL Server Engine | High Availability and Disaster Recovery | All |
| 3157066 | Adds performance monitor counters to the cluster log report when the health check timeout is reported. | SQL Server Engine | High Availability and Disaster Recovery | Windows |
| 3207515 | FIX: Memory exceeds the configured limits that are specified by memory.memorylimitmb in SQL Server (KB5042369) | SQL Server Engine | Linux | Linux |
| 3155852 | Fixes an assertion failure (Location: sosmemobj.cpp:2744; Expression: pvb->FInUse()) in CVariableInfo::PviRelease that you encounter when you use UTF-8 collations and the WITH RESULT SETS clause. |
SQL Server Engine | Programmability | All |
| 3157452 | Fixes two issues related to cardinality estimation (CE) feedback: plan cache leaks and access violations due to race conditions with statement recompilations. | SQL Server Engine | Query Optimizer | All |
| 3236328 | Improves cardinality estimation (CE) for predicates that request ranges disjoint with column statistics when statistics have only one histogram step. | SQL Server Engine | Query Optimizer | All |
| 3222639 | Fixes an issue in which change tracking auto cleanup consumes CPU in cycles every 30 minutes even if change tracking isn't enabled on any databases. Note: After applying the fix, if you see some rows in sys.syscommittab or dbo.MSchange_tracking_history tables in databases where change tracking is disabled, you need to re-enable and then disable change tracking on these databases. This will clean all tracking data. For more information, see Enable and Disable Change Tracking. |
SQL Server Engine | Replication | All |
How to obtain or download this or the latest cumulative update package
File information
Notes for this update
How to uninstall this update
References
- Announcing updates to the SQL Server Incremental Servicing Model (ISM)
- SQL Server Service Packs are no longer supported starting from SQL Server 2017
- Determine which version and edition of SQL Server Database Engine is running
- Servicing models for SQL Server
- Naming schema and Fix area descriptions for SQL Server software update packages
- Description of the standard terminology that is used to describe Microsoft software updates
Feedback
Was this page helpful?
