Win a copy of Bad Programming Practices 101 (e-book) this week in the Beginning Java forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Database Access works on a manually started Tomcat but not on a Tomcat started as a Service  RSS feed

Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello JavaRanch People :-)

My problem is the following - i programmed an application which accesses a ms sql server through native authentification (jdbc driver is jtds). everything works fine in my development environment (eclipse) and also directly under tomcat - at least if i start up manually (of course i had to put the native dll file for single sign on in a directory where my java library path points to). BUT (!!!) it doesn't work if i start tomcat as a service!

I already found out where my library path is by adding

to my application which returns:

C:\Program Files\apache-tomcat-6.0.26\bin;
c:\Program Files (x86)\Microsoft SQL Server\100\Tools\Binn\VSShell\Common7\IDE\;
c:\Program Files (x86)\Microsoft SQL Server\100\Tools\Binn\;
c:\Program Files\Microsoft SQL Server\100\Tools\Binn\;
c:\Program Files (x86)\Microsoft SQL Server\100\DTS\Binn\;

I already tried putting the .dll file ("ntlmauth.dll" shipped with the jdbc driver) in some of that places, but the application always throws the following exception:

... which means that the native library for using that driver was not found (SSO = Single Sign On -> needs "ntlmauth.dll" shipped with the jdbc driver). As I said: it works in eclipse or if I start tomcat manually, but it doesn't work if I start tomcat as a service. I also tried starting it as admin... any suggestions? I am sure more ppl are getting this error...

Thanks in advance for any useful tips! :-)
Now I am super curious what sports would be like if we allowed drugs and tiny ads.
Why should you try IntelliJ IDEA ?
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!