Hi Eric,
Yes, it looks like the driver is missing. To make it available to
Tomcat container you need to put it in "$TOMCAT_HOME/common/lib". I
don't recall if this location is Tomcat version specific, so if this
doesn't work, you can try other common "lib" folders under $TOMCAT_HOME.
Andrus
On Sep 8, 2006, at 9:55 PM, Eric Lazarus wrote:
> Jeff
>
> Thanks but it didn't seem to change anything yet. Hmmm...
>
> The error we are getting is "java.sql.SQLException:
> org.postgresql.Driver"... I wonder if this means it didn't find
> the driver ?
>
> Thanks,
>
> Eric
>
>
> Jeff de Vries <jdevrie..frog.com> wrote: This is what we use, and
> it works. One difference I notice is where
> the login and password are located ...
>
>>
>> debug="99"
>> driverName="org.postgresql.Driver"
>> connectionURL="jdbc:postgresql://dbhost/realmdb"
>> connectionName=""
>> connectionPassword="
> "
>> userTable="users" userNameCol="uname"
>> userCredCol="pword"
>> userRoleTable="roles" roleNameCol="role"
>> digest="MD5" />
>
> Hope that helps ...
>
>
> On Sep 8, 2006, at 7:18 AM, Eric Lazarus wrote:
>
>> Hi, Folks
>>
>> Up until now we have been using the memory realm to control user
>> access to our main application.
>>
>> The numbers of users is going to go up so we need to keep that info
>> somewhere and in the database seems like a good place.
>>
>> We are having some difficulty configuring a JDBCRealm, getting the
>> error you see at the bottom of this email but it occurs to me:
>>
>> All our other database access is via cayenne. Should I be doing
>> something more cayenne-ish rather than using the JDBCRealm?
>>
>>
>> Thanks!
>>
>> Eric
>>
>> = = = = = = = = =
>>
>> Still having trouble connecting through tomcat's JDBC REALM.
>>
>> I am trying to use the tomcat JDBC REALM for user log-in.
>> Here is the relevent portion of my server.xml file:
>>
>>
>> driverName="org.postgresql.Driver"
>>
>> connectionURL="jdbc:postgres://localhost/PAX_2005?
>> user=paxlogin&password=paxlogin"
>> serTable="loginuser" userNameCol="emailaddress"
>> userCredCol="password"
>> userRoleTable="loginrole" roleNameCol="role" />
>>
>>
>> HERE 'loginuser' and 'loginrole' are views in my postgres database.
>> They are UNION queries that combine 3 tables of possible users,
>> and distinguish them with different roles.
>>
>> 'paxlogin' is a user in this database who has 'select' privileges
>> on these two views, and no other previleges.
>>
>> When I start tomcat, I get the following output, which essentially
>> says that tomcat got an SQL Exception when it tired to connect.
>>
>> I would probably be able to solve this easier if I could see the
>> text of the SQLException that is the 'root cause' of the error.
>>
>> Is this an authentication failure on the paxlogin user ?
>> Is somthing wrong with the Views, or the privileges ?
>>
>>
>> Using CATALINA_BASE: /home/pax/2005/tomcat-base
>> Using CATALINA_HOME: /usr/local/tomcat/4.0.6
>> Using CATALINA_TMPDIR: /home/pax/2005/tomcat-base/temp
>> Using JAVA_HOME: /usr/local/java/j2sdk1.4.2_06
>> Starting service Tomcat-Standalone
>> Apache Tomcat/4.0.6
>> Catalina.start: LifecycleException: Exception opening database
>> connection:
>> java.sql.SQLException: org.postgresql.Driver
>> LifecycleException: Exception opening database connection:
>> java.sql.SQLException: org.postgresql.Driver
>> at org.apache.catalina.realm.JDBCRealm.start(JDBCRealm.java:615)
>> at
>> org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1108)
>> at
>> org.apache.catalina.core.StandardEngine.start(StandardEngine.java:
>> 343)
>> at
>> org.apache.catalina.core.StandardService.start(StandardService.java:
>> 388)
>> at
>> org.apache.catalina.core.StandardServer.start(StandardServer.java:
>> 506)
>> at org.apache.catalina.startup.Catalina.start(Catalina.java:781)
>> at org.apache.catalina.startup.Catalina.execute(Catalina.java:
>> 681)
>> at org.apache.catalina.startup.Catalina.process(Catalina.java:
>> 179)
>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>> at
>> sun.reflect.NativeMethodAccessorImpl.invoke
>> (NativeMethodAccessorImpl.java:39)
>> at
>> sun.reflect.DelegatingMethodAccessorImpl.invoke
>> (DelegatingMethodAccessorImpl.java:25)
>> at java.lang.reflect.Method.invoke(Method.java:324)
>> at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:243)
>> ----- Root Cause -----
>> java.sql.SQLException: org.postgresql.Driver
>> at org.apache.catalina.realm.JDBCRealm.open(JDBCRealm.java:538)
>> at org.apache.catalina.realm.JDBCRealm.start(JDBCRealm.java:613)
>> at
>> org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1108)
>> at
>> org.apache.catalina.core.StandardEngine.start(StandardEngine.java:
>> 343)
>> at
>> org.apache.catalina.core.StandardService.start(StandardService.java:
>> 388)
>> at
>> org.apache.catalina.core.StandardServer.start(StandardServer.java:
>> 506)
>> at org.apache.catalina.startup.Catalina.start(Catalina.java:781)
>> at org.apache.catalina.startup.Catalina.execute(Catalina.java:
>> 681)
>> at org.apache.catalina.startup.Catalina.process(Catalina.java:
>> 179)
>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>> at
>> sun.reflect.NativeMethodAccessorImpl.invoke
>> (NativeMethodAccessorImpl.java:39)
>> at
>> sun.reflect.DelegatingMethodAccessorImpl.invoke
>> (DelegatingMethodAccessorImpl.java:25)
>> at java.lang.reflect.Method.invoke(Method.java:324)
>> at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:243)
>>
>>
>>
>> Eric
>> +1 (917) 589-6579
>>
>> ---------------------------------
>> Why keep checking for Mail? The all-new Yahoo! Mail shows you when
>> there are new messages.
>
>
>
>
>
> ---------------------------------
> All-new Yahoo! Mail - Fire up a more powerful email and get things
> done faster.
This archive was generated by hypermail 2.0.0 : Fri Sep 08 2006 - 15:07:21 EDT