Event ID - 18456

Event Id18456
SourceMSSQLSERVER
DescriptionLogin failed for user '%.*ls'.%.*ls
Event InformationAccording to Microsoft:
Cause:

When a connection attempt is rejected because of an authentication failure that involves a bad password or user name, a message similar to the following is returned to the client: "Login failed for user ''. (Microsoft SQL Server, Error: 18456)".

Additional information returned to the client includes the following:

"Login failed for user ''. (.Net SqlClient Data Provider)"
------------------------------

"Server Name: "
"Error Number: 18456"
"Severity: 14"
"State: 1"
"Line Number: 65536"
The following message might also be returned:
"Msg 18456, Level 14, State 1, Server , Line 1"
"Login failed for user ''."

User Action :
If you are trying to connect using SQL Server Authentication, verify that SQL Server is configured in Mixed Authentication Mode.

If you are trying to connect using SQL Server Authentication, verify that SQL Server login exists and that you have spelled it properly.

If you are trying to connect using Windows Authentication, verify that you are properly logged into the correct domain."
------------------------------------------------
" This information from some newsgroups may help you:"
I had this problem because the file system file owner was not a specified user in SQL Server. In my case, the message was "Error: 18456 Severity: 14 State: 16". I resolved this by doing the following on the SQL Server 2005:
  1. Open SQL Server Management Studio.
  2. Expand Databases.
  3. Right Click on the Database with problems and choose "Properties".
  4. Left Click the "Files" node.
  5. Ensure that an appropriate owner is listed. If none is, then set it.

---------------------------------------------------------------------------------------------------------------------------------
After installing SharePoint Services 3.0 with SQL 2005 Embedded Edition on a member server W2K3 R2 and updating the server to a Domain Controller, it was not possible to start the SQL services. This can happen, when you install SharePoint Services before upgrading the server to be a DC. I cleared all entries to MSSQL in the registry, rebooted the server, and reinstalled SharePoint Services.
-------------------------------------------------------------------------------------------------------------------------------


SQL server was hosting several MOSS 2007 databases. I found that the SQL agent was trying to login to a database that did not exist. MOSS uses SQL Server Jobs to delete expired sessions on a set schedule, every minute, to free up resources that are not being used. You will need to go into SQL Server management studio and disable the job called SharedServices_DB_job_deleteExpiredSessions. Once this is done you should no longer see those error messages in the event log. If you disable the right job, and the error message no longer appears, you can then delete the job. Always disable first. You do not want to delete until you are sure you got the right job.


-------------------------------------------------------------------------------------------------------------------------------
After migrating WSUS 3.0 SP1 database form Internal Database to SQL 2005 instance installed on the same server you can get the following error: Login failed for user "NT AUTHORITY\NETWORK SERVICE". [CLIENT: ]. This problem may appear because the NT AUTHORITY\NETWORK SERVICE account does not have login permissions to master database in the SQL 2005 instance. Add the NT AUTHORITY\NETWORK SERVICE account to the master database permissions list, restart the SQL server, restart the IIS service, and then restart the Update Services service.


------------------------------------------------------------------------------------------------------------------------------------
I've had this problem in conjunction with WSUS 3.0SP1 after installation of MS SQL 2000 SP4. WSUS could not start because it had no access to \WSUS\UpdateServicesDbFiles\SUSDB.mdf and SUSDB_log.ldf. I've solved the problem by resetting the file acess permission inheritance.



------------------------------------------------------------------------------------------------------------------------------
After migrating WSUS 3.0 SP1 database form Internal Database to SQL 2005 instance installed on the same server you can get the following error: Login failed for user "NT AUTHORITY\NETWORK SERVICE". [CLIENT: ]. This problem may appear because the NT AUTHORITY\NETWORK SERVICE account does not have login permissions to master database in the SQL 2005 instance. Add the NT AUTHORITY\NETWORK SERVICE account to the master database permissions list, restart the SQL server, restart the IIS service, and then restart the Update Services service.
Reference LinksEvent ID 18456 from Source MSSQLSERVER

Catch threats immediately

We work side-by-side with you to rapidly detect cyberthreats
and thwart attacks before they cause damage.

See what we caught

Did this information help you to resolve the problem?

Yes: My problem was resolved.
No: The information was not helpful / Partially helpful.