powered by Jive Software

Monitoring Service not loading correctly

Monitoring service plugin seems to not be working correctly. I can get to it by typing Servername.net/plugins/monitoring/archive and it’ll work from there however I am unable to get to it through the web ui normally.

2022.11.09 09:37:10 ERROR [Thread-2]: org.jivesoftware.openfire.container.PluginManager - An exception occurred while trying to unload plugin 'monitoring':
java.lang.NullPointerException: null
    at org.jivesoftware.openfire.index.LuceneIndexer.stop(LuceneIndexer.java:208) ~[?:?]
    at org.jivesoftware.openfire.plugin.MonitoringPlugin.destroyPlugin(MonitoringPlugin.java:222) ~[?:?]
    at org.jivesoftware.openfire.container.PluginManager.shutdown(PluginManager.java:151) [xmppserver-4.7.3.jar:4.7.3]
    at org.jivesoftware.openfire.XMPPServer.shutdownServer(XMPPServer.java:1263) [xmppserver-4.7.3.jar:4.7.3]
    at org.jivesoftware.openfire.XMPPServer.access$900(XMPPServer.java:159) [xmppserver-4.7.3.jar:4.7.3]
    at org.jivesoftware.openfire.XMPPServer$ShutdownHookThread.run(XMPPServer.java:1203) [xmppserver-4.7.3.jar:4.7.3]
2022.11.09 09:39:05 ERROR [pool-6-thread-4]: org.jivesoftware.util.XMLProperties - Error reading XML properties
org.dom4j.DocumentException: Error on line 1 of document : Content is not allowed in prolog.
    at org.dom4j.io.SAXReader.read(SAXReader.java:511) ~[dom4j-2.1.3.jar:?]
    at org.dom4j.io.SAXReader.read(SAXReader.java:408) ~[dom4j-2.1.3.jar:?]
    at org.jivesoftware.util.XMLProperties.buildDoc(XMLProperties.java:740) [xmppserver-4.7.3.jar:4.7.3]
    at org.jivesoftware.util.XMLProperties.<init>(XMLProperties.java:111) [xmppserver-4.7.3.jar:4.7.3]
    at org.jivesoftware.openfire.index.LuceneIndexer.loadPropertiesFile(LuceneIndexer.java:454) [monitoring-2.3.1.jar:?]
    at org.jivesoftware.openfire.index.LuceneIndexer.start(LuceneIndexer.java:80) [monitoring-2.3.1.jar:?]
    at org.jivesoftware.openfire.plugin.MonitoringPlugin.initializePlugin(MonitoringPlugin.java:211) [monitoring-2.3.1.jar:?]
    at org.jivesoftware.openfire.container.PluginManager.loadPlugin(PluginManager.java:637) [xmppserver-4.7.3.jar:4.7.3]
    at org.jivesoftware.openfire.container.PluginMonitor$MonitorTask$4.call(PluginMonitor.java:375) [xmppserver-4.7.3.jar:4.7.3]
    at org.jivesoftware.openfire.container.PluginMonitor$MonitorTask$4.call(PluginMonitor.java:363) [xmppserver-4.7.3.jar:4.7.3]
    at java.util.concurrent.FutureTask.run(FutureTask.java:264) [?:?]
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) [?:?]
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) [?:?]
    at java.lang.Thread.run(Thread.java:834) [?:?]
Caused by: org.xml.sax.SAXParseException: Content is not allowed in prolog.
    at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.createSAXParseException(ErrorHandlerWrapper.java:204) ~[?:?]
    at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.fatalError(ErrorHandlerWrapper.java:178) ~[?:?]
    at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:400) ~[?:?]
    at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:327) ~[?:?]
    at com.sun.org.apache.xerces.internal.impl.XMLScanner.reportFatalError(XMLScanner.java:1465) ~[?:?]
    at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl$PrologDriver.next(XMLDocumentScannerImpl.java:978) ~[?:?]
    at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(XMLDocumentScannerImpl.java:605) ~[?:?]
    at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next(XMLNSDocumentScannerImpl.java:112) ~[?:?]
    at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:534) ~[?:?]
    at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:888) ~[?:?]
    at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:824) ~[?:?]
    at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:141) ~[?:?]
    at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1216) ~[?:?]
    at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(SAXParserImpl.java:635) ~[?:?]
    at org.dom4j.io.SAXReader.read(SAXReader.java:494) ~[dom4j-2.1.3.jar:?]
    ... 13 more
2022.11.09 09:39:05 ERROR [pool-6-thread-4]: org.jivesoftware.openfire.archive.ArchiveIndexer[MESSAGE] - An exception occurred while initializing the Lucene index that is expected to exist in: C:\Openfire\monitoring\msgsearch
java.io.IOException: Error on line 1 of document : Content is not allowed in prolog.
    at org.jivesoftware.util.XMLProperties.buildDoc(XMLProperties.java:744) ~[xmppserver-4.7.3.jar:4.7.3]
    at org.jivesoftware.util.XMLProperties.<init>(XMLProperties.java:111) ~[xmppserver-4.7.3.jar:4.7.3]
    at org.jivesoftware.openfire.index.LuceneIndexer.loadPropertiesFile(LuceneIndexer.java:454) ~[monitoring-2.3.1.jar:?]
    at org.jivesoftware.openfire.index.LuceneIndexer.start(LuceneIndexer.java:80) [monitoring-2.3.1.jar:?]
    at org.jivesoftware.openfire.plugin.MonitoringPlugin.initializePlugin(MonitoringPlugin.java:211) [monitoring-2.3.1.jar:?]
    at org.jivesoftware.openfire.container.PluginManager.loadPlugin(PluginManager.java:637) [xmppserver-4.7.3.jar:4.7.3]
    at org.jivesoftware.openfire.container.PluginMonitor$MonitorTask$4.call(PluginMonitor.java:375) [xmppserver-4.7.3.jar:4.7.3]
    at org.jivesoftware.openfire.container.PluginMonitor$MonitorTask$4.call(PluginMonitor.java:363) [xmppserver-4.7.3.jar:4.7.3]
    at java.util.concurrent.FutureTask.run(FutureTask.java:264) [?:?]
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) [?:?]
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) [?:?]
    at java.lang.Thread.run(Thread.java:834) [?:?]
2022.11.09 09:39:05 ERROR [pool-6-thread-4]: org.jivesoftware.openfire.container.PluginManager - An exception occurred while loading plugin 'monitoring':
java.lang.NullPointerException: null
    at org.jivesoftware.openfire.index.LuceneIndexer.getLastModified(LuceneIndexer.java:182) ~[monitoring-2.3.1.jar:?]
    at org.jivesoftware.openfire.index.LuceneIndexer.start(LuceneIndexer.java:153) ~[monitoring-2.3.1.jar:?]
    at org.jivesoftware.openfire.plugin.MonitoringPlugin.initializePlugin(MonitoringPlugin.java:211) ~[monitoring-2.3.1.jar:?]
    at org.jivesoftware.openfire.container.PluginManager.loadPlugin(PluginManager.java:637) [xmppserver-4.7.3.jar:4.7.3]
    at org.jivesoftware.openfire.container.PluginMonitor$MonitorTask$4.call(PluginMonitor.java:375) [xmppserver-4.7.3.jar:4.7.3]
    at org.jivesoftware.openfire.container.PluginMonitor$MonitorTask$4.call(PluginMonitor.java:363) [xmppserver-4.7.3.jar:4.7.3]
    at java.util.concurrent.FutureTask.run(FutureTask.java:264) [?:?]
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) [?:?]
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) [?:?]
    at java.lang.Thread.run(Thread.java:834) [?:?]

It appears that there is file corruption in the metadata of the search index. Those are stored in a directory called monitoring that is in the home folder of Openfire.

Try:

  1. shutting down Openfire
  2. backing up everything
  3. deleting OPENFIRE_HOME/monitoring
  4. restarting Openfire
1 Like

Thank you so much. That fixed the problem

1 Like

Good to hear that! Can you review the files named indexprops.xml in your backup? I wonder what kind of corruption happened.