Problem Description:
The local installed two instances, one is sqlexpress, can operate normally. But another common instance of development MSSQLSERVER but even Windows authentication is an error, the report of the mistake is very wonderful, how can not find administrator that, I log in to the computer to use this account.
Detailed errors are as follows:
Unable to connect to XXX.
===================================
User ' Xxx\administrator ' login failed. (. Net SqlClient Data Provider)
------------------------------
For help information, click: Http://go.microsoft.com/fwlink? prodname=microsoft%20sql%20server&evtsrc=mssqlserver&evtid=18456&linkid=20476
------------------------------
Server name: XXX
Error Number: 18456
Severity: 14
Status: 1
Line number: 65536
Solution:First search Microsoft on 18456, found the detailed description of this error, address https://msdn.microsoft.com/zh-cn/library/cc645917 (v=sql.120). aspx. After reading it came to a conclusion, seems to be related to this account permissions, need to give this administrator a SQL Server inside the administrator's permissions, sysadmin. Then you want to log in with SA first and then give the user the right. But the problem is again, sa password I do not know! No solution, had to ask colleagues, colleagues sent a connection, http://www.cnblogs.com/lyhabc/p/3513560.html. The problem was solved perfectly. Probably the idea is this: 1, first stop service 2, through CMD, in single-user mode login SQL Server, theoretical reference https://docs.microsoft.com/zh-cn/previous-versions/sql/ sql-server-2008-r2/ms180965 (v%3dsql.105) 3, give administrator user 4, turn off CMD, restart Service open SQL Server, log in as Windows, perfect, go in. You can then modify the password for the SA.
SQL Server in the IDE Windows Authentication connection servers error, Login failed for user ' xxx\administrator '. Cause: The login name matching the supplied name could not be found.