Issues with deadlocks on events table in 3.2.11

So I know this is an old version of octopus deploy but we are seeing deadlocks every now and again when databases get active. The most recent one was with this:

Error from Octopus server (HTTP 500): Octopus Server returned an error: Error while executing SQL command: Transaction (Process ID 143) was deadlocked on lock | communication buffer resources with another process and has been chosen as the deadlock victim. Rerun the transaction.
The command being executed was:
INSERT INTO dbo.[Event] (RelatedDocumentIds, ProjectId, EnvironmentId, Category, UserId, Username, Occurred, Message, Id, Json) values (@RelatedDocumentIds, @ProjectId, @EnvironmentId, @Category, @UserId, @Username, @Occurred, @Message, @Id, @Json)

I went ahead and looked at the event table and it has just under 180k events. Is there anything we can do to help solve these or has this also been addressed in higher versions already?


Hi Brent,

Thank you for getting in touch. Unfortunately we have not been able to nail down the cause of the deadlocks. We have however implemented some diagnostics logging when this occurs. If you do upgrade, and encounter the problem again, a message should be logged to the OctopusServer.txt file, which is usually located in the c:\octopus\logs directory. The information in the log should help us get to the bottom of that.

If you do not want to send the whole file, you can send in the exception message, including the SQL statements below it. The SQL statements we log do not contain the parameters.

We have an issue tracking this problem.

Robert W