windows unable to connect to SQL server with windows authentication mode I haven't created SQL authentication.Server name is AYAZ .Server is able to connect with Analysis and Reporting service but unable to connect with Database engine
-
Clearly, this is an authentication error? Wrong username and password. Are you sure you are using same credentials in your reporting service and Database engine? Also, hope you have cross checked configurations. – I_am_Batman Apr 10 '16 at 16:41
-
i am using same name and password – Ayaz Ahmad Tarar Apr 10 '16 at 19:59
2 Answers
Follow the below steps described here
Logon as a local administrator.
Stop the "SQL Server" service and run "C:\Program Files\Microsoft SQL Server\MSSQL10.MSSQLSERVER\MSSQL\Binn\sqlservr.exe" -m" (start SQL Server in Local Only mode.)
Logon to SSMS from the server itself - no password required.
Add my own domain account as a Login, with sysadm server role.
Restart the SQL Server service
- 1,307
- 6
- 26
- 51
-
Whilst this may theoretically answer the question, [it would be preferable](//meta.stackoverflow.com/q/8259) to include the essential parts of the answer here, and provide the link for reference. Please edit your answer to correct this, then flag your post to request un-deletion – Matt Apr 11 '16 at 18:44
Here is another suggestion:
SQL Server allows only SQL logins in the SQL Authentication mode. The logins are defined within SQL Server.
In short, if you want to use Window account to connect to SQL Server, connection string should not have user name and password. It would be something like below. Instead of username and password, we need to use “Integrated Security=SSPI”
Provider=SQLNCLI11.1;Data Source=SQLSERVER2016;Integrated Security=SSPI
For additional information: http://blog.sqlauthority.com/2016/02/17/sql-server-fix-error-18456-severity-14-state-6-login-failed-for-user/
- 440
- 6
- 10
