2 messages in com.mysql.lists.javaPermission Errors
FromSent OnAttachments
Piotrowski, Brian11 Dec 2000 08:42 
Igor Fedulov11 Dec 2000 08:53 
Subject:Permission Errors
From:Piotrowski, Brian (piot@corp.efni.com)
Date:12/11/2000 08:42:00 AM
List:com.mysql.lists.java

We just moved our site to a new server, but I am having problems connecting to the MySQL database. Whenever our site tries to connect, I get the error message:

Error: 500 Location: /examples/jsp/test/dbquery.jsp Internal Servlet Error: javax.servlet.ServletException: Cannot load connection class 'java.sql.SQLException: Invalid authorization specification: Access denied for user: 'root@localhost.localdomain' (Using password: YES)'. at org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImp l.java, Compiled Code) at jsp.test._0002fjsp_0002ftest_0002fdbquery_0002ejspdbquery_jsp_28._jspService (_0002fjsp_0002ftest_0002fdbquery_0002ejspdbquery_jsp_28.java, Compiled Code) at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java, Compiled Code) at javax.servlet.http.HttpServlet.service(HttpServlet.java, Compiled Code) at org.apache.jasper.runtime.JspServlet$JspServletWrapper.service(JspServlet.ja va, Compiled Code) at org.apache.jasper.runtime.JspServlet.serviceJspFile(JspServlet.java, Compiled Code) at org.apache.jasper.runtime.JspServlet.service(JspServlet.java, Compiled Code) at javax.servlet.http.HttpServlet.service(HttpServlet.java, Compiled Code) at org.apache.tomcat.core.ServletWrapper.handleRequest(ServletWrapper.java, Compiled Code) at org.apache.tomcat.core.ContextManager.service(ContextManager.java, Compiled Code) at org.apache.tomcat.service.connector.Ajp12ConnectionHandler.processConnection (Ajp12ConnectionHandler.java, Compiled Code) at org.apache.tomcat.service.TcpConnectionThread.run(SimpleTcpEndpoint.java, Compiled Code) at java.lang.Thread.run(Thread.java, Compiled Code)

I know there is a password problem, but for the life of me I can't figure out what it is! Here are some specs on the server: server name: enhance.efni.com

in my code, I have this string to connect to the server: Connection myConn = DriverManager.getConnection("jdbc:mysql:///MyDB?user=root&password=XXXXXXX") ;

In my USER table for the MySQL database, I have a few entries including: host: localhost user: root pass: (root password) permissions (Y on all permissions)

host: enhance.efni.com user: root pass: (root password) permissions (Y on all permissions)

Do I have to modify any other tables to give Tomcat access to the MySQL tables?

Thanks,

Brian.

----------------------------------- Brian Piotrowski Developer / Network Administrator Moneyramp.com (705) 475-9531 www.moneyramp.com

-----------------------------------