Connecting Mysql with openfire

Hii,

i am trying to connect MySQL database with openfire but in the “Database Settings - Standard Connection” ,I am getting an error as given below

“A connection to the database could not be made. View the error message by opening the “\logs\error.log” log file, then go back to fix the problem”.

I have done the following changes in “Database Settings - Standard Connection”::

Database Driver Presets:
JDBC Driver Class:
Database URL:

I think there is a problem with the host name .I am using Win7 laptop and I got the hostname using ipconfig in the cmd …please suggest to overcome this problem…

tanx in advance//

View the error message by opening the “\logs\error.log” log file
Post the error.log file here, remove your hostname if you don’t want to make it public.

\logs\error.log:

2012.01.15 17:52:28 org.jivesoftware.util.log.util.CommonsLogFactory - Prototype

java.sql.SQLException: null, message from server: “Host ‘10.10.22.23’ is not allowed to connect to this MySQL server”

at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:946)

at com.mysql.jdbc.MysqlIO.doHandshake(MysqlIO.java:1070)

at com.mysql.jdbc.Connection.createNewIO(Connection.java:2775)

at com.mysql.jdbc.Connection.(Connection.java:1555)

at com.mysql.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:285)

at java.sql.DriverManager.getConnection(Unknown Source)

at java.sql.DriverManager.getConnection(Unknown Source)

at org.logicalcobwebs.proxool.DefaultConnectionBuilder.buildConnection(DefaultConn ectionBuilder.java:39)

at org.logicalcobwebs.proxool.Prototyper.buildConnection(Prototyper.java:159)

at org.logicalcobwebs.proxool.Prototyper.sweep(Prototyper.java:102)

at org.logicalcobwebs.proxool.PrototyperThread.run(PrototyperThread.java:44)

2012.01.15 17:52:28 org.jivesoftware.database.DbConnectionManager - null, message from server: “Host ‘10.10.22.23’ is not allowed to connect to this MySQL server”

java.sql.SQLException: null, message from server: “Host ‘10.10.22.23’ is not allowed to connect to this MySQL server”

at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:946)

at com.mysql.jdbc.MysqlIO.doHandshake(MysqlIO.java:1070)

at com.mysql.jdbc.Connection.createNewIO(Connection.java:2775)

at com.mysql.jdbc.Connection.(Connection.java:1555)

at com.mysql.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:285)

at java.sql.DriverManager.getConnection(Unknown Source)

at java.sql.DriverManager.getConnection(Unknown Source)

at org.logicalcobwebs.proxool.DefaultConnectionBuilder.buildConnection(DefaultConn ectionBuilder.java:39)

at org.logicalcobwebs.proxool.Prototyper.buildConnection(Prototyper.java:159)

at org.logicalcobwebs.proxool.ConnectionPool.getConnection(ConnectionPool.java:211 )

at org.logicalcobwebs.proxool.ProxoolDriver.connect(ProxoolDriver.java:89)

at java.sql.DriverManager.getConnection(Unknown Source)

at java.sql.DriverManager.getConnection(Unknown Source)

at org.jivesoftware.database.DefaultConnectionProvider.getConnection(DefaultConnec tionProvider.java:86)

at org.jivesoftware.database.DbConnectionManager.setConnectionProvider(DbConnectio nManager.java:620)

at org.jivesoftware.openfire.admin.setup.setup_002ddatasource_002dstandard_jsp._js pService(setup_002ddatasource_002dstandard_jsp.java:206)

at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)

at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)

at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:530)

at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.ja va:1216)

at com.opensymphony.module.sitemesh.filter.PageFilter.parsePage(PageFilter.java:11 8)

at com.opensymphony.module.sitemesh.filter.PageFilter.doFilter(PageFilter.java:52)

at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.ja va:1187)

at org.jivesoftware.util.LocaleFilter.doFilter(LocaleFilter.java:74)

at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.ja va:1187)

at org.jivesoftware.util.SetCharacterEncodingFilter.doFilter(SetCharacterEncodingF ilter.java:50)

at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.ja va:1187)

at org.jivesoftware.admin.PluginFilter.doFilter(PluginFilter.java:78)

at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.ja va:1187)

at org.jivesoftware.admin.AuthCheckFilter.doFilter(AuthCheckFilter.java:164)

at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.ja va:1187)

at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:425)

at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:119)

at org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:494)

at org.eclipse.jetty.server.session.SessionHandler.handle(SessionHandler.java:182)

at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:93 3)

at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:362)

at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:867 )

at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:117)

at org.eclipse.jetty.server.handler.ContextHandlerCollection.handle(ContextHandler Collection.java:245)

at org.eclipse.jetty.server.handler.HandlerCollection.handle(HandlerCollection.jav a:126)

at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:113)

at org.eclipse.jetty.server.Server.handle(Server.java:334)

at org.eclipse.jetty.server.HttpConnection.handleRequest(HttpConnection.java:559)

at org.eclipse.jetty.server.HttpConnection$RequestHandler.content(HttpConnection.j ava:1007)

at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:747)

at org.eclipse.jetty.http.HttpParser.parseAvailable(HttpParser.java:209)

at org.eclipse.jetty.server.HttpConnection.handle(HttpConnection.java:406)

at org.eclipse.jetty.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:4 62)

at org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.java:436)

at java.lang.Thread.run(Unknown Source)

2012.01.15 17:52:57 org.jivesoftware.util.log.util.CommonsLogFactory - Prototype

java.sql.SQLException: null, message from server: “Host ‘10.10.22.23’ is not allowed to connect to this MySQL server”

at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:946)

at com.mysql.jdbc.MysqlIO.doHandshake(MysqlIO.java:1070)

at com.mysql.jdbc.Connection.createNewIO(Connection.java:2775)

at com.mysql.jdbc.Connection.(Connection.java:1555)

at com.mysql.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:285)

at java.sql.DriverManager.getConnection(Unknown Source)

at java.sql.DriverManager.getConnection(Unknown Source)

at org.logicalcobwebs.proxool.DefaultConnectionBuilder.buildConnection(DefaultConn ectionBuilder.java:39)

at org.logicalcobwebs.proxool.Prototyper.buildConnection(Prototyper.java:159)

at org.logicalcobwebs.proxool.Prototyper.sweep(Prototyper.java:102)

at org.logicalcobwebs.proxool.PrototyperThread.run(PrototyperThread.java:44)

"Host ‘10.10.22.23’ is not allowed to connect to this MySQL server"
Run some GRANT SQL statements which allow access for the user you use for Openfire. Currently the user/host is not allowed to connect. http://dev.mysql.com/doc/refman/5.5/en/access-denied.html should help.

Hey,

I tried many things but nothing workd out at all.

So I used unanimous account for MYSQL without any security and password

For openfire in “Database Settings - Standard Connection”,I wrote ::

your host name:::localhost

database name::test

But to my surprise, it got connected and its working fine…

Does that user authentication in MYSQL is necessary or should I work without it ??

Thank u for guidelines…

Usually want does want to use a user and password. I did never try without auth, if this works make at least sure to reboot the server ans check whether this still works after a restart of Openfire and MySQL.

yeah you are right…

after restart I am not able to log in to openfire server.,its showing invalid username or password …

Any other way to do it ??

thanks 4 ur support

I have solve the problem using PhpMyAdmin. Now I am not getting any error and I checked it by restarting the system…thank you for your help