FIX: A latch timeout occurs when you run an online index rebuild or a merge statement in SQL Server

Applies to: SQL Server 2016 DeveloperSQL Server 2016 EnterpriseSQL Server 2016 Enterprise Core

Symptoms


Assume that you run an instance of Microsoft SQL Server 2017, 2016 or 2014. When you run an online index rebuild or a merge statement, you may experience a timeout and an error in the errorlog followed by a stack dump. The error message is similar to the following:

Date/Time spid55 A time-out occurred while waiting for buffer latch -- type 4, bp 000002CA3B245D00, page 1:456, stat 0x408810b, database id: DatabaseID, allocation unit Id: 72057594307215360, task 0x000002C02C45ACA8 : 0, waittime 300 seconds, flags 0x200000001a, owning task 0x000002C02C45ACA8. Not continuing to wait.

Resolution


The fix for this problem is included in the following updates for SQL Server:

Cumulative Update 7 for SQL Server 2017      

Cumulative Update 9 for SQL Server 2016 Service Pack 1

Cumulative Update 12 for SQL Server 2014 SP2

Status


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

References


Learn about the terminology Microsoft uses to describe software updates.