deadlock

MySQL deadlocks explanation

▼魔方 西西 提交于 2020-12-07 08:34:08
问题 I need help solving a deadlock situation I'm facing. Thanks for your help. I think the deadlock is related to the SELECT subquery of transaction 2, but I don't understand several things: Why is it holding a S lock and then waiting for a X lock of the same row... why didn't it get an X lock to begin with? In any case, why is transaction 1 blocking anything? I would expect it to just need one lock, therefore not get a lock of anything else, and just wait until that lock is available to be

Windbg - process frozen on SNIReadSyncOverAsync but no deadlock found

馋奶兔 提交于 2020-12-05 10:23:12
问题 I have a strange problem. A process gets frozen/stuck while reading data using System.Data.SqlClient.SqlDataReader on GetValue() function. I am analyzing the process dump using WinDbg. I used SOS commands like !dlk , !SyncBlk , !analyze -v -hang etc. but none of them indicate any deadlocks. The last call on callstack is 000000001a98e8a8 0000000076febd7a [InlinedCallFrame: 000000001a98e8a8] .**SNIReadSyncOverAsync**(SNI_ConnWrapper*, SNI_Packet**, Int32) 000000001a98e8a8 000007fee9e8bca1

SELECT + INSERT + Query Cache = MySQL lock up

混江龙づ霸主 提交于 2020-11-29 04:02:30
问题 MySQL server seems to constantly lock up and stop responding on certain types of queries and eventually (after couple of minutes of not responding) give up with an error " MySQL server has gone away ", then hang again on the next set of queries, again and again. The server is set up as a slave to replicate from a master to dbA , mostly INSERT statements, around 5-10 rows per second. A PHP based application is running on the server that reads the freshly replicated data every 5-10 seconds,