Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Cannot connect to SQL Server - login failed [closed]

I am trying to connect to a SQL Server 2008, but I'm getting this error:

Login failed for user "xyz" because the account is currently locked out.The system administrator can unlock it. (Microsoft SQL Server, Error 18486)

Please check the image.

enter image description here

like image 883
Vinod Avatar asked Aug 30 '12 06:08

Vinod


1 Answers

SQL server has local password policies. If policy is enabled which locks down the account after X number of failed attempts then the account is automatically locked down.This error with 'sa' account is very common. sa is default administartor login available with SQL server. So there are chances that an ousider has tried to bruteforce your system. (This can cause even if a legitimate tries to access the account with wrong password.Sometimes a user would have changed the password without informing others.)

If you know another admin account, you can unlock it using this query,

ALTER LOGIN sa WITH PASSWORD='password' UNLOCK

Read more on this link.

like image 157
John Woo Avatar answered Sep 24 '22 04:09

John Woo