Getting "Integrated authentication failed" when trying to connect to SQL 2019 DB for first-time setup

I am attempting to install SonarQube 9.3 onto a domain-joined Windows Server 2016 machine. I am attempting to connect to a MS SQL server via the JDBC driver version 9.4.1 to a SQL server that is running SQL Server 2019. Both servers are Azure Virtual Machines, joined to the same domain. When I start up SonarQube, I get the error message “Integrated authentication failed. ClientConnectionId:(random GUID)” in the web log and setup fails. This is being launched via a Windows service. I have used two different privileged accounts that can connect to the SQL database as the context for the Windows service. My connection string is as follows:
sonar.jdbc.url=jdbc:sqlserver://(SERVER NAME REDACTED);databaseName=(DATABASE NAME REDACTED);integratedSecurity=true;
I have even tried replacing the .JAR and .DLL from 9.4 to 10.2. In that case, I got a SSL certificate trust failure, even though I registered the trusted CA certificate in the JDK store. I reverted back to 9.4, and the “Integrated authentication failed” message returned. Our information security team really does not want us to use SQL server credentials, or pass credentials via a connection string, so we really want to see if we can get integrated authentication working.


Welcome to the community!

It’s probably easiest to debug your connection outside the SonarQube setting. Could you try something like this?

Also, and just to be sure, the DB login and password properties were commented out, right? If they’re available, they’ll be used by default.


We tried using this test harness as well and we were still having issues. It looks like it’s an issue with AD Integrated Authentication not working with Azure AD if you are not running ADFS. We switched to a SQL login and it worked. Thanks for the assistance.

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.