Author Topic: Queuemetrics and database  (Read 4468 times)

alexandr-e

  • Newbie
  • *
  • Posts: 4
  • Karma: 0
    • View Profile
Queuemetrics and database
« on: January 29, 2008, 12:37:54 »
Hello !

So i did as they say in the tutorial. I did just that different:

 GRANT ALL PRIVILEGES ON queuemetrics.*  TO 'queuemetrics'@'localhost' IDENTIFIED BY 'asterisk';

Show grants:
mysql>  SHOW GRANTS FOR 'queuemetrics'@'localhost';
+---------------------------------------------------------------------------------------------------------------------+
| Grants for queuemetrics@localhost                                                                                   |
+---------------------------------------------------------------------------------------------------------------------+
| GRANT USAGE ON *.* TO 'queuemetrics'@'localhost' IDENTIFIED BY PASSWORD '*7C99FE2524A21E88E9DBE310DB2F754773BF383E' |
| GRANT ALL PRIVILEGES ON `queuemetrics`.* TO 'queuemetrics'@'localhost'                   

in web.xml:
 <param-value>jdbc:mysql://localhost/queuemetrics?autoReconnect=true&amp;zeroDateTimeBehavior=convertToNull&amp;jdbcCompliantTruncation=false&amp;user=queuemetrics&amp;password=asterisk</param-value>


and when I go to thit url:
http://localhost:8080/queuemetrics-1.4.3/dbtest/


I have an error at the step 4 connecting to the database:


Problem encountered:
Please set the correct server address, database name, user name and password to access the MySQL database.
To do so, edit the JDBC_URL property of WEB-INF/web.xml

Java Error:
java.sql.SQLException: Server connection failure during transaction. Due to underlying exception: 'java.sql.SQLException: Invalid authorization specification message from server: "Access denied for user 'queuemetrics'@'localhost' (using password: YES)"'. ** BEGIN NESTED EXCEPTION ** java.sql.SQLException MESSAGE: Invalid authorization specification message from server: "Access denied for user 'queuemetrics'@'localhost' (using password: YES)" STACKTRACE: java.sql.SQLException: Invalid authorization specification message from server: "Access denied for user 'queuemetrics'@'localhost' (using password: YES)" at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:2001) at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:1907) at com.mysql.jdbc.MysqlIO.secureAuth411(MysqlIO.java:2524) at com.mysql.jdbc.MysqlIO.doHandshake(MysqlIO.java:818) at com.mysql.jdbc.Connection.createNewIO(Connection.java:1926) at com.mysql.jdbc.Connection.(Connection.java:452) at com.mysql.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:411) at java.sql.DriverManager.getConnection(DriverManager.java:525) at java.sql.DriverManager.getConnection(DriverManager.java:193) at it.loway.app.queuemetrics.jdbcTester.jdbcTester.testJdbcConn(Unknown Source) at org.apache.jsp.dbtest.index_jsp._jspService(index_jsp.java:187) at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:98) at javax.servlet.http.HttpServlet.service(HttpServlet.java:803) at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:331) at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:329) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:265) at javax.servlet.http.HttpServlet.service(HttpServlet.java:803) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:269) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:174) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:108) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:151) at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:874) at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:665) at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:528) at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:81) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:689) at java.lang.Thread.run(Thread.java:595) ** END NESTED EXCEPTION ** Attempted reconnect 3 times. Giving up.

Asterisk is on the same server than quemetrics. Any idea ?

Thanks for you help
     

alexandr-e

  • Newbie
  • *
  • Posts: 4
  • Karma: 0
    • View Profile
Re: Queuemetrics and database
« Reply #1 on: January 29, 2008, 14:54:55 »
shame on me, I had two copy of the folder /queuemetrics-1.4.3/ One in the webapps and one in my deskop, I didn't edit the xml in the webapps.  ::)
Now it's work better  ;D

QueueMetrics

  • Loway
  • Hero Member
  • *
  • Posts: 2999
  • Karma: 39
    • View Profile
    • QueueMetrics
Re: Queuemetrics and database
« Reply #2 on: January 30, 2008, 15:34:31 »
So it's working now?
 ;D