NullPointerException while updating

Happens when entering the (Mysql) database credentials. Does that help?

The database is working. The password given is correct as is the uri. I can connect using the plain mysql client.

HTTP ERROR: 500INTERNAL_SERVER_ERROR

RequestURI=/setup/setup-datasource-standard.jsp

Caused by:java.lang.NullPointerException

at java.util.Hashtable.put(Hashtable.java:396)

at java.util.Properties.setProperty(Properties.java:128)

at org.jivesoftware.database.DefaultConnectionProvider.start(DefaultConnectionProv ider.java:91)

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

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

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

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

at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:487)

at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.ja va:1093)

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.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.ja va:1084)

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

at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.ja va:1084)

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

at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.ja va:1084)

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

at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.ja va:1084)

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

at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.ja va:1084)

at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:360)

at org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216)

at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:181)

at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:726)

at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:405)

at org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandlerCollect ion.java:206)

at org.mortbay.jetty.handler.HandlerCollection.handle(HandlerCollection.java:114)

at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:139)

at org.mortbay.jetty.Server.handle(Server.java:324)

at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:505)

at org.mortbay.jetty.HttpConnection$RequestHandler.content(HttpConnection.java:842 )

at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:648)

at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:211)

at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:380)

at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:395)

at org.mortbay.thread.BoundedThreadPool$PoolThread.run(BoundedThreadPool.java:450)

{noformat

Hey Sakura,

I would guess that the server is not actually connected to the database. What other errors do you see in the log files?

Thanks,

– Gato

The mysql server is on localhost:3306. My ISP set me up with SuSE 9.3. It’s a full server and not a virtual one.

The serverURL is: jdbc:mysql://localhost:3306/allanime_XMPP

Password is empty, Mysql is set up to accept connections only from localhost. Mysql version is: mysql Ver 14.7 Distrib 4.1.10a, for suse-linux (i686)

Currently running: 3.4.1

After updating the admin interface reruns the setup process in which the mentioned error occurs.

Does that information help?

Ok I have to reply to my own post.

The reason for this null pointer exception most likely was a permission problem. When replacing the start script /etc/rc.d/openfired I forgot updating the script and openfire was called with permissions of the current user. This was also why the setup dialog was called - it couldn’t read the openfire.xml configuration file (nor could it write - NullPointerException!)

Sorry for that rookie mistake. Perhaps adding a check for write permissions on openfire.xml is not a bad idea?

Bogus error due to file permission problem. Suggested to add error message when openfire.xml not writeable on setup.