sql-server-maintenance-solution icon indicating copy to clipboard operation
sql-server-maintenance-solution copied to clipboard

Deadlock in IndexOptimize returns success

Open toneand opened this issue 5 years ago • 1 comments

Description of the issue Index reorg statement deadlock victim causes IndexOptimize to stop instead of skipping victim statement and continuing with other reorg or rebuilds.

SQL Server version and edition Microsoft SQL Server 2016 (SP2-CU7-GDR) (KB4505222) - 13.0.5366.0 (X64) Jun 15 2019 08:22:25 Copyright (c) Microsoft Corporation Enterprise Edition: Core-based Licensing (64-bit) on Windows Server 2012 R2 Datacenter 6.3 <X64> (Build 9600: ) (Hypervisor)

Version of the script Check the header of the stored procedure

What command are you executing? ALTER INDEX ... REORGANIZE ...

What output are you getting? I have IndexOptimize as part of weekly index maintenance. When a deadlock occurs and the currently executing ALTER INDEX REORGANIZE is the victim, the job finishes as a success, but none of the INDEX reorgs or rebuilds that follow the deadlock victim attempt to run.

toneand avatar Mar 02 '20 16:03 toneand

Deadlock detection appears to be working properly in the current (2022-12-03) version. This issue should probably be closed.

jhardin-accumula avatar May 03 '24 18:05 jhardin-accumula