# SQL Server Database Connection with Integrated Security

**URL:** <https://forum.inductiveautomation.com/t/sql-server-database-connection-with-integrated-security/2703>\
**Category:** Ignition\
**Created:** [March 1, 2011, 2:14am UTC](https://forum.inductiveautomation.com/t/sql-server-database-connection-with-integrated-security/2703 "2011-03-01T02:14:40Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![MickeyBob](https://avatars.discourse-cdn.com/v4/letter/m/e19adc/32.png) [@MickeyBob](https://forum.inductiveautomation.com/u/MickeyBob)\
**Post date:** [March 1, 2011, 2:14am UTC](https://forum.inductiveautomation.com/t/sql-server-database-connection-with-integrated-security/2703/1 "2011-03-01T02:14:40Z")

</div>

I’m having trouble setting up a SQL Server database connection using integrated security.

I’ve searched the forum for related subjects and found one thread where the symptom was nearly identical ([viewtopic.php?f=70&t=5213&hilit=driver+is+not+configured+for+integrated+authentication](http://www.inductiveautomation.com/forum/viewtopic.php?f=70&t=5213&hilit=driver+is+not+configured+for+integrated+authentication)).

I tried everything suggested there.

I also reviewed Travis’ training video on database connections and tried to do everything required there. I still can’t get it to work.

I’ve successfully configured a connection on the same box using SQL Server security.

My error message is:

[quote] org.apache.commons.dbcp.SQLNestedException: Cannot create PoolableConnectionFactory (This driver is not configured for integrated authentication.)  
org.apache.commons.dbcp.BasicDataSource.createDataSource(BasicDataSource.java:1225)  
org.apache.commons.dbcp.BasicDataSource.getConnection(BasicDataSource.java:880)  
com.inductiveautomation.ignition.gateway.datasource.DatasourceImpl.getConnectionInternal(DatasourceImpl.java:179)  
com.inductiveautomation.ignition.gateway.datasource.DatasourceImpl.runTest(DatasourceImpl.java:135)  
com.inductiveautomation.ignition.gateway.datasource.DatasourceManagerImpl$FaultedDatasourceRetryer.run(DatasourceManagerImpl.java:1030)  
java.lang.Thread.run(Unknown Source)  
com.microsoft.sqlserver.jdbc.SQLServerException: This driver is not configured for integrated authentication.  
com.microsoft.sqlserver.jdbc.SQLServerException.makeFromDriverError(SQLServerException.java:170)  
com.microsoft.sqlserver.jdbc.SQLServerConnection.sendLogon(SQLServerConnection.java:2338)  
com.microsoft.sqlserver.jdbc.SQLServerConnection.logon(SQLServerConnection.java:1929)  
com.microsoft.sqlserver.jdbc.SQLServerConnection.access$000(SQLServerConnection.java:41)  
com.microsoft.sqlserver.jdbc.SQLServerConnection$LogonCommand.doExecute(SQLServerConnection.java:1917)  
com.microsoft.sqlserver.jdbc.TDSCommand.execute(IOBuffer.java:4026)  
com.microsoft.sqlserver.jdbc.SQLServerConnection.executeCommand(SQLServerConnection.java:1416)  
com.microsoft.sqlserver.jdbc.SQLServerConnection.connectHelper(SQLServerConnection.java:1061)  
com.microsoft.sqlserver.jdbc.SQLServerConnection.login(SQLServerConnection.java:833)  
com.microsoft.sqlserver.jdbc.SQLServerConnection.connect(SQLServerConnection.java:716)  
com.microsoft.sqlserver.jdbc.SQLServerDriver.connect(SQLServerDriver.java:841)  
org.apache.commons.dbcp.DriverConnectionFactory.createConnection(DriverConnectionFactory.java:38)  
org.apache.commons.dbcp.PoolableConnectionFactory.makeObject(PoolableConnectionFactory.java:294)  
org.apache.commons.dbcp.BasicDataSource.validateConnectionFactory(BasicDataSource.java:1247)  
org.apache.commons.dbcp.BasicDataSource.createDataSource(BasicDataSource.java:1221)  
org.apache.commons.dbcp.BasicDataSource.getConnection(BasicDataSource.java:880)  
com.inductiveautomation.ignition.gateway.datasource.DatasourceImpl.getConnectionInternal(DatasourceImpl.java:179)  
com.inductiveautomation.ignition.gateway.datasource.DatasourceImpl.runTest(DatasourceImpl.java:135)  
com.inductiveautomation.ignition.gateway.datasource.DatasourceManagerImpl$FaultedDatasourceRetryer.run(DatasourceManagerImpl.java:1030)  
java.lang.Thread.run(Unknown Source)  
[/quote]  
I’m trying to configure it on a VM running Windows Server 2008R2, SQL Server 2008/10 and MS JDBC V3.0 driver.

Configuration screen follows:

 ![](https://us1.discourse-cdn.com/inductiveautomation/original/1X/d59ebdcb5cdd722dec454107881bd2e68dc95be9.png)

---

<div class="post-metadata">

**Author:** ![Robert.McKenzie](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/robert.mckenzie/32/4134_2.png) [@Robert.McKenzie](https://forum.inductiveautomation.com/u/Robert.McKenzie)\
**Post date:** [March 3, 2011, 8:03pm UTC](https://forum.inductiveautomation.com/t/sql-server-database-connection-with-integrated-security/2703/2 "2011-03-03T20:03:55Z")

</div>

Did you try taking a look at [Connecting to MS SQL Server](http://inductiveautomation.com/support/usermanuals/ignition/connecting_to_microsoft_sql_se.htm)? Connecting to SQLServer is sometimes a pain, but it always works after downloading the right sqljdbc\_auth.dll file and turning on the browser, TCP/IP, etc. The error Cannot create PoolableConnectionFactory doesn’t really tell us much about why it can’t connect, but I would double check which sqljdbc\_auth.dll file you loaded and make sure you restarted the SQLServer service after changing it’s settings.

---

<div class="post-metadata">

**Author:** ![y.parashchuk](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/y.parashchuk/32/37781_2.png) [@y.parashchuk](https://forum.inductiveautomation.com/u/y.parashchuk)\
**Post date:** [November 25, 2021, 12:58pm UTC](https://forum.inductiveautomation.com/t/sql-server-database-connection-with-integrated-security/2703/3 "2021-11-25T12:58:42Z")

</div>

I have Ignition 8.1.11.  
Followed instructions in [https://support.inductiveautomation.com/hc/en-us/articles/360047131512-Microsoft-SQL-Server-MSSQL-Connection-Guide-for-Ignition](https://support.inductiveautomation.com/hc/en-us/articles/360047131512-Microsoft-SQL-Server-MSSQL-Connection-Guide-for-Ignition).

Had issue. But fixed it.  
If I followed default instructions I had an error 1(fig 1 File Missing). I have some hard time to figure out what i can do… After i had an idea just not to rename file as they telling in the instruction → Had another issue (fig 2 File missing). Then i just keep 2 files (1 renamed and 1 not) at the folder and all works fine → looks stooping because it’s the same files, but working - so will use until they fix issue.

 ![1 File missing](https://us1.discourse-cdn.com/inductiveautomation/original/3X/3/6/36b1d656ed34b72795d1eb35378022ffd19686f4.png)  
 ![2 File is missing](https://us1.discourse-cdn.com/inductiveautomation/original/3X/0/2/029e1164c06a082fefb6782cf45b7809a55568cf.png)  
 ![3 Rename file](https://us1.discourse-cdn.com/inductiveautomation/original/3X/2/9/29a90584d9853d666662c057355b56f1e34638b8.png)

---

<div class="post-metadata">

**Author:** ![Jerry\_Johnson](https://avatars.discourse-cdn.com/v4/letter/j/aeb1de/32.png) [@Jerry\_Johnson](https://forum.inductiveautomation.com/u/Jerry_Johnson)\
**Post date:** [July 8, 2022, 6:18am UTC](https://forum.inductiveautomation.com/t/sql-server-database-connection-with-integrated-security/2703/4 "2022-07-08T06:18:56Z")

</div>

Thanks. I was facing the same problem. It worked.

---

<div class="post-metadata">

**Author:** ![reed.hoffmaster](https://avatars.discourse-cdn.com/v4/letter/r/ad7895/32.png) [@reed.hoffmaster](https://forum.inductiveautomation.com/u/reed.hoffmaster)\
**Post date:** [December 12, 2022, 7:43pm UTC](https://forum.inductiveautomation.com/t/sql-server-database-connection-with-integrated-security/2703/5 "2022-12-12T19:43:38Z")

</div>

I was having trouble connecting with Windows Authentication as well. I found that I was getting a similar error from the Gateway Status page...

`Cannot create PoolableConnectionFactory (This driver is not configured for integrated authentication.`

I noticed further down in the stack trace however, that the driver version Ignition was looking for did not match the latest version I downloaded (per the User Manual Guide: [Connecting to Microsoft SQL Server](https://docs.inductiveautomation.com/display/DOC81/Connecting+to+Microsoft+SQL+Server), Scenario 2: Connect By Using Instance Name and Windows Authentication)

`java.lang.UnsatisfiedLinkError: no mssql-jdbc_auth-9.4.0.x64 in java.library.path: [lib, lib\core\gateway]`

I sought out, and downloaded the mssql-jdbc\_auth-X.X.X.x64.dll file that matched the mssql-jdbc-9.4.0.jre11.jar file located in _C:\Program Files\Inductive Automation\Ignition\user-lib\jdbc_, which was 9.4.0 in my case. I put that file in the location described by the connection guide and my connection worked.

TL;DR, The connection guide should be updated to specify that the DLL file you want should match the mssql-jdbc JAR file in your user-lib/jdbc directory, instead of just "...it's recommended you use the most recent driver available for your system".

Specs: Ignition 8.1.21, Running on Windows Server 2019.

---

<div class="post-metadata">

**Author:** ![avaughn](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/avaughn/32/38972_2.png) [@avaughn](https://forum.inductiveautomation.com/u/avaughn)\
**Post date:** [December 12, 2022, 9:39pm UTC](https://forum.inductiveautomation.com/t/sql-server-database-connection-with-integrated-security/2703/6 "2022-12-12T21:39:58Z")

</div>

The note in the documentation has been updated and now mentions that the JDBC Driver and DLL versions need to match. Let me know if that seems clear enough.

 ![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/5/f/5f21abf5f6c4c06150d8d9cb6572bb1518670edd.png)

---

<div class="post-metadata">

**Author:** ![reed.hoffmaster](https://avatars.discourse-cdn.com/v4/letter/r/ad7895/32.png) [@reed.hoffmaster](https://forum.inductiveautomation.com/u/reed.hoffmaster)\
**Post date:** [December 13, 2022, 2:08pm UTC](https://forum.inductiveautomation.com/t/sql-server-database-connection-with-integrated-security/2703/7 "2022-12-13T14:08:06Z")

</div>

Thanks for updating that quickly. I just saw the note this morning that thought I may have missed it all along! I think this will be very helpful for folks.

Perhaps a reference to where people can find that jdbc driver would be helpful too. In my case it was found in user-lib within the install directory. I didn't see anything that looked like a version number on the config page of the gateway but perhaps there's an easier way to identify the version.

---

<div class="post-metadata">

**Author:** ![avaughn](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/avaughn/32/38972_2.png) [@avaughn](https://forum.inductiveautomation.com/u/avaughn)\
**Post date:** [December 13, 2022, 2:31pm UTC](https://forum.inductiveautomation.com/t/sql-server-database-connection-with-integrated-security/2703/8 "2022-12-13T14:31:00Z")

</div>

That's a good point! Looking in the install directory is the best way to see it. I know we have a note in [this](https://support.inductiveautomation.com/hc/en-us/articles/4417310204813-TLS-v1-0-and-v1-1-Microsoft-SQL-Server-Database-connection-issue) KBA that mentions the location but it's geared towards a different issue. I'll see if our docs team can get a note added about the location in the install directory on that user manual page as well.

---

<div class="post-metadata">

**Author:** ![avaughn](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/avaughn/32/38972_2.png) [@avaughn](https://forum.inductiveautomation.com/u/avaughn)\
**Post date:** [December 13, 2022, 3:59pm UTC](https://forum.inductiveautomation.com/t/sql-server-database-connection-with-integrated-security/2703/9 "2022-12-13T15:59:11Z")

</div>

> [@reed.hoffmaster](#):
>
> Perhaps a reference to where people can find that jdbc driver would be helpful too.

Okay, that's been added now as well.
