An AlwaysOn secondary replica crashes or raises error 3961 when the AlwaysOn database has CLR UDT in SQL Server 2014

Van toepassing: SQL Server 2014 EnterpriseSQL Server 2014 EnterpriseSQL Server 2014 Developer


Consider the following scenario:
  • You enable the AlwaysOn Availability Groups feature in Microsoft SQL Server 2014.
  • The AlwaysOn database has common language runtime (CLR) user-defined data type (UDT). Additionally, the same CLR UDT exists in more than one database.
  • You run a query that involves multiple databases that have the CLR UDT.
In this scenario, an access violation error occurs on the secondary replica, and the instance of SQL Server crashes with the following message in the SQL Server error log:
2015-02-17 13:07:36.85 spid27s Shutting down database due to exception 2905 during VLR processing at commit.

2015-02-17 13:07:36.85 spid27s Error: 3449, Severity: 21, State: 1.2015-02-17 13:07:36.85 spid27s SQL Server must shut down in order to recover a database (database ID 2). The database is either a user database that could not be shut down or a system database. Restart SQL Server. If the database fails to recover after another startup, repair or restore the database.
Additionally, you receive the following error message in your secondary replica database, and the error will not go away until you restart SQL Server:
Msg 3961, Level 16, State 1, Line 3
Snapshot isolation transaction failed in database '<DatabaseName>' because the object accessed by the statement has been modified by a DDL statement in another concurrent transaction since the start of this transaction. It is disallowed because the metadata is not versioned. A concurrent update to metadata can lead to inconsistency if mixed with snapshot isolation.


Cumulative Update information

The issue was first fixed in the following cumulative update of SQL Server.

Update information

To resolve this issue, apply the update KB 3043788: An on-demand hotfix update package is available for SQL Server 2014 .


Microsoft has confirmed that this is a problem in the Microsoft products that are listed in the "Applies to" section.