question

new-dba avatar image
new-dba asked

Error 18452 Severity 14 State 16

Hi,
We have this error 18456 Severity 14 State 16 keep on appearing in the Sql server error log. (we are using sql server 2005 sp 3).Error message occurred everytime when the application log-in from the application server.We have checked and verified that the id is having dbo and is already tag to a default user database.There is only one user database.Not sure what else to check. Appreciate feedback. Thanks

sql-server-2005loginerror-message
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Matt Whitfield avatar image
Matt Whitfield answered

I believe that State 16 means that the user login does not have access to their default database...

Try using ALTER LOGIN to change the default database for the user, for example:

ALTER LOGIN [<name of user>]
WITH DEFAULT_DATABASE = [<name of database>]
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Mandar Alawani avatar image
Mandar Alawani answered

it can also be a simple access issue..

see to it that the login in question has the correct permissions on the sql server as well as the database ..

10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

DaniSQL avatar image
DaniSQL answered

Please check this awesome blog from Microsoft SQL Protocols team on "Understanding "login failed" (Error 18456) error messages in SQL Server 2005". Also Read the comments in the blog.

One comment says "State=16 means that the incoming user does not have permissions to log into the target database. .....This can also happen if for example the default database for user is not online (for example the database is marked suspect)."

Hope this helps!

10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.