Results 1 to 2 of 2
  1. #1
    Join Date
    Jun 2002
    Posts
    2

    Unanswered: JDBCRealm from Tomcat 3.3.1 on RedHat 7.2 --> MySQL 3.23.x ... Please help !!

    Please help anybody !
    Getting mad with this shi...

    For 4 days now Iīm trying to connect my Tomcat 3.3.1 Server on a RedHat 7.2 machine to a MySQL Server 11.15 3.23.x running on the same machine ...

    But no chance, if I call the example sites from Tomcat, alle the examples work fine, but I get the following message in the shell:

    [root@greenbox /]# 2002-06-13 16:00:00 - JDBCRealm: The database connection is null or was found to be closed. Trying to re-open it.

    2002-06-13 16:00:00 - JDBCRealm: JDBCRealm.authenticate: SELECT null FROM null WHERE null = ?

    Finding /admin
    Found DEFAULT:/admin

    2002-06-13 16:00:00 - JDBCRealm: There was an SQLException while in getCredentials: root - java.sql.SQLException: Syntax error or access violation: You have an error in your SQL syntax near 'null WHERE null = 'root'' at line 1

    at org.gjt.mm.mysql.MysqlIO.sendCommand(Unknown Source)
    at org.gjt.mm.mysql.MysqlIO.sqlQueryDirect(Unknown Source)
    at org.gjt.mm.mysql.Connection.execSQL(Unknown Source)
    at org.gjt.mm.mysql.PreparedStatement.executeQuery(Un known Source)
    at org.apache.tomcat.modules.aaa.JDBCRealm.getCredent ials(JDBCRealm.java:247)
    at org.apache.tomcat.modules.aaa.RealmBase.checkPassw ord(RealmBase.java:212)
    at org.apache.tomcat.modules.aaa.RealmBase.authentica te(RealmBase.java:193)
    at org.apache.tomcat.core.Request.getRemoteUser(Reque st.java:575)
    at org.apache.tomcat.modules.aaa.AccessInterceptor.au thorize(AccessInterceptor.java:359)
    at org.apache.tomcat.core.ContextManager.internalServ ice(ContextManager.java:902)
    at org.apache.tomcat.core.ContextManager.service(Cont extManager.java:833)
    at org.apache.tomcat.modules.server.Http10Interceptor .processConnection(Http10Interceptor.java:176)
    at org.apache.tomcat.util.net.TcpWorkerThread.runIt(P oolTcpEndpoint.java:494)
    at org.apache.tomcat.util.threads.ThreadPool$ControlR unnable.run(ThreadPool.java:516)
    at java.lang.Thread.run(Thread.java:536)

    2002-06-13 16:00:00 - JDBCRealm: Authentication unsuccessful for user root

    Below there is the JDBC-Part of the server.xml:

    <JDBCRealm
    debug="99"
    driverName="org.gjt.mm.mysql.Driver"
    connectionURL="jdbc:mysql://localhost/authority"
    connectionName="user1"
    connectionPassword="tomcat"
    autoreconnect="true"
    />

    Below is Tomcats:

    Classpath:CLASSPATH=${TOMCAT_INSTALL}/lib/tomcat.jar:/opt/j2sdk1.4.0_01/lib:/opt/j2sdk1.4.0_01/jre/lib:${TOMCAT_INSTALL}/lib/mm.mysql-2.0.14-bin.jar:${TOMCAT_INSTALL}/lib/tools.jar

    Please help !!

    Thanks, olli

  2. #2
    Join Date
    Oct 2003
    Posts
    1
    Probably you have not used port number in Server.xml file
    localhost:3306/
    Or possibly you did not specify username
    authority?user=root

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •