Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Confluence suddenly stopped working

Roget Luo June 22, 2018

Confluence hosted on Windows 2012 VM, stopped working recently, getting Apache Tomcat/7.047 Error report, "HTTP Status 500-java.lang.NullPointerException" when trying to pull up the dashboard URL.  

On the hosting VM, Apache Tomcat 6.0 shows in Services.msc and it's running.  Atlassian Conflence is up and running as well.  Browsed to the Confluence\bin folder, tried to run tomcat7w, got "The specified service does not exists as an install service.  Unable to open service tomcat7".  

No experience in Apache or Confluence, any help is greatly appreciated.

1 answer

1 vote
AnnWorley
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
June 22, 2018

Hi Roget,

Please try:

  1. Shut down the Confluence service in services.msc. There should not be a second service for Tomcat for Confluence so unless the Tomcat service is a known application please shut it down, too.
  2. Start Confluence by running the start-confluence.bat file in the <confluence_install>/bin folder at an elevated command prompt (This will open a command window with startup messages, if you close it, Confluence will shut down)
  3. Try accessing Confluence in the browser
  4. If all is well in the browser, use <confluence_install>/bin/stop-confluence.bat to shut Confluence down
  5. Start the Confluence service and see if the error appears in the browswer
  6. If the error appears with the service and not the manual start-up then reinstall the service as described in Start Confluence Automatically on Windows as a Service - the instructions for removing the old service first are at the bottom of the page.

Since you are using Tomcat 7, I assume you are using an older version of Confluence as Confluence uses Tomcat 8 now.

If you still see an error after starting Confluence manually with the .bat file please let us know the error, what version of Confluence you are running and any relevant looking entries in:
<confluence_install>/logs/ (anything recent in this directory) and <confluence_home>/logs/atlassian-confluence.log.
(note) The <confluence_home> directory is the path defined in the following file: <confluence_install>/confluence/WEB-INF/classes/confluence-init.properties

Thanks,

Ann

Roget Luo June 25, 2018

Hi Ann,

Thank you for the reply.  Followed steps 1 & 2 but still pulling up the java.lang.NullPointerException when trying to pull up the web page, with the following

message java.lang.NullPointerException

description The server encountered an internal error that prevented it from fulfilling this request.

exception

com.atlassian.util.concurrent.LazyReference$InitializationException: java.lang.NullPointerException
 com.atlassian.util.concurrent.LazyReference.getInterruptibly(LazyReference.java:149)
 com.atlassian.util.concurrent.LazyReference.get(LazyReference.java:112)
 com.atlassian.confluence.setup.ConfluenceEncodingFilter.getGlobalSettings(ConfluenceEncodingFilter.java:47)
 com.atlassian.confluence.setup.ConfluenceEncodingFilter.getEncodingInternal(ConfluenceEncodingFilter.java:37)
 com.atlassian.confluence.setup.ConfluenceEncodingFilter.getEncoding(ConfluenceEncodingFilter.java:29)
 com.atlassian.core.filters.encoding.AbstractEncodingFilter.doFilter(AbstractEncodingFilter.java:38)
 com.atlassian.core.filters.AbstractHttpFilter.doFilter(AbstractHttpFilter.java:31)
 com.atlassian.core.filters.HeaderSanitisingFilter.doFilter(HeaderSanitisingFilter.java:44)
 com.atlassian.confluence.servlet.FourOhFourErrorLoggingFilter.doFilter(FourOhFourErrorLoggingFilter.java:65)
 com.atlassian.confluence.web.filter.DebugFilter.doFilter(DebugFilter.java:50)
 com.atlassian.core.filters.AbstractHttpFilter.doFilter(AbstractHttpFilter.java:31)

 

root cause

java.lang.NullPointerException
 com.atlassian.spring.container.ContainerManager.getComponent(ContainerManager.java:33)
 com.atlassian.confluence.util.LazyComponentReference$Accessor.get(LazyComponentReference.java:46)
 com.atlassian.util.concurrent.Lazy$Strong.create(Lazy.java:85)
 com.atlassian.util.concurrent.LazyReference$Sync.run(LazyReference.java:321)
 com.atlassian.util.concurrent.LazyReference.getInterruptibly(LazyReference.java:143)
 com.atlassian.util.concurrent.LazyReference.get(LazyReference.java:112)
 com.atlassian.confluence.setup.ConfluenceEncodingFilter.getGlobalSettings(ConfluenceEncodingFilter.java:47)
 com.atlassian.confluence.setup.ConfluenceEncodingFilter.getEncodingInternal(ConfluenceEncodingFilter.java:37)
 com.atlassian.confluence.setup.ConfluenceEncodingFilter.getEncoding(ConfluenceEncodingFilter.java:29)
 com.atlassian.core.filters.encoding.AbstractEncodingFilter.doFilter(AbstractEncodingFilter.java:38)
 com.atlassian.core.filters.AbstractHttpFilter.doFilter(AbstractHttpFilter.java:31)
 com.atlassian.core.filters.HeaderSanitisingFilter.doFilter(HeaderSanitisingFilter.java:44)
 com.atlassian.confluence.servlet.FourOhFourErrorLoggingFilter.doFilter(FourOhFourErrorLoggingFilter.java:65)
 com.atlassian.confluence.web.filter.DebugFilter.doFilter(DebugFilter.java:50)
 com.atlassian.core.filters.AbstractHttpFilter.doFilter(AbstractHttpFilter.java:31)
Roget Luo June 25, 2018

Confluence version: 5.5 [build 5501]

Java version: 8 Update 171

AnnWorley
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
June 25, 2018

Hi Roget,

The supported Java version for Confluence 5.5 is Java 1.7 (Supported Platforms). I have not been successful running older Confluence instances against newer Java versions so let's get started by installing a supported version of Java:

If Confluence still won't start up after installing a supported version of Java, please check for more clues in the logs at:
* <confluence_install>/logs/ (anything recent in this directory)
* <confluence_home>/logs/atlassian-confluence.log
(note) The <confluence_home> directory is the path defined in the following file: <confluence_install>/confluence/WEB-INF/classes/confluence-init.properties

I should mention that Confluence 5.5 has passed End of Life status: Atlassian Support End of Life Policy. Please follow our guide, Upgrading Confluence when you have a chance.

Thanks,

Ann

Roget Luo June 26, 2018

Hi Ann,

Uninstalled the latest JAVA and installed JAVA 1.7.0_80-b15, set the JAVA_HOME variable but still same HTTP 500-java.lang.NullPointerException.

The atlassian-confluence log file is quite lengthy, is there a way to upload it?  Here are several noteworthy lines:

org.postgresql.util.PSQLException: Connection refused. Check that the hostname and port are correct and that the postmaster is accepting TCP/IP connections

Caused by: java.net.ConnectException: Connection refused: connect

java.sql.SQLException: Connections could not be acquired from the underlying database!

com.mchange.v2.resourcepool.CannotAcquireResourceException: A ResourcePool could not acquire a resource from its primary factory or source.

AnnWorley
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
June 26, 2018

If we need to do file sharing to examine logs I can open a support ticket but it may not be necessary as the errors you posted are startup showstoppers. Confluence cannot connect to it's database. This article reports that a configuration parameter in PostgreSQL can be changed to remedy the issue: Confluence PostgreSQL JDBC direct connection refused

Roget Luo June 27, 2018

Hi Ann,

Thanks for your continue help in this matter.  Looks like PostgreSQL install got corrupted on this server.  It was on version 9.3, should I reinstall the same version, and anything I should look out for during the install?

Also, would it be easier if we just upgrade Confluence to a newer version?

AnnWorley
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
June 27, 2018

The same version of PostgreSQL is a good idea because if you want your data from the old instance you will need to export it from the old database and import it on the new PostgreSQL - I found an article on how to do it but it's not an Atlassian article: How to import and export a PostgreSQL database

Before importing data to the new database, please make sure it is set up as described in Database Setup for PostgreSQL

Since you mentioned you are running Confluence on Windows, I thought this may help for the PostgreSQL install: WINDOWS INSTALLERS

Please make sure your existing instance is stable before upgrading. We have made a lot of improvements in the last few years so I do recommend upgrading. Please go over Upgrading Confluence during the planning stages of the upgrade as it has a good "before you start" section.

Roget Luo June 27, 2018

Sounds like its best to reinstall PostgreSQL 9.3 first and make sure everything is working then perform the Confluence upgrade?

AnnWorley
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
June 27, 2018

Yes, that would be the most methodical way to proceed. That way we won't be left guessing whether any future issues are related to the upgrade or the database incident. :)

Roget Luo June 27, 2018

Thanks!!  Looks like a "fun" weekend project ahead for me.  :-)I will update you soon.  Really appreciated all your help. 

Quick note, I'm looking into renewing annual maintenance, is it really $10 / year?  We have less than 10 users who will access Confluence.

AnnWorley
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
June 27, 2018

Yes, it's just $10/year for 1-10 users: How much is it to renew my Confluence software maintenance?

Shameless plug: Atlassian donates 100% of Starter License payments to charity, absorbing all transactions costs incurred in payment processing.

I am truly happy I was able to help, I hope you will keep us posted on how it goes.

Roget Luo June 28, 2018

Hi Ann,

I located the 5.5-1 .exe file, would it fix the issue if I simply reinstall Confluence on the server?

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events