Posts

Showing posts with the label Issues

“sa” account kept being locked out.

  reporting experiencing an issue whereby the “sa” account kept being locked out. In scenarios such as this the SQL Server Error Log is your friend, as it can be configured to record failed login attempts for an instance.  so instead we’re going to take a look at using the lesser known DMV  sys.dm_os_ring_buffers . Executing the query above produces a more readable result set such as the one below. You can see that in the query we joined our ring buffer data to the  sys.messages  catalog view in order to grab the  text  for the Error id. Splendid. Using this information we track down the precise source responsible for the Error: Login failed. ;WITH RingBufferConnectivity as (   SELECT         records.record.value('(/Record/@id)[1]', 'int') AS [RecordID],         records.record.value('(/Record/ConnectivityTraceRecord/RecordType)[1]', 'varchar(max)') AS [RecordType],         records.record.value('(/Record/ConnectivityTraceRecord/RecordTime)[1]', &#