Bitbucket Data Center UI throws error: 404. This page cannot be found.


   

Platform Notice: Data Center - This article applies to Atlassian products on the Data Center platform.

Note that this knowledge base article was created for the Data Center version of the product. Data Center knowledge base articles for non-Data Center-specific features may also work for Server versions of the product, however they have not been tested. Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.

*Except Fisheye and Crucible

Summary

Bitbucket UI displays error 404: This page cannot be found. It also shows unformatted headers (Projects, Repositories) and footers (About, Contact, Bitbucket version) and the user is unable to log in.

The screenshot below shows an unformatted page with partial information, indicating that the page is able to fetch information but is unable to render correctly. 

Environment

All Bitbucket DC versions.

Diagnosis

  • Bitbucket server and services are up and running. Confirm the result of the command:

    Grep for confirming bitbucket application status
    ps -ef | grep java
    
    bitbuck+     7     1  9 19:06 ?        00:01:59 /opt/java/openjdk/bin/java -classpath /opt/atlassian/bitbucket/app -Datlassian.standalone=BITBUCKET -Dbitbucket.home=/var/atlassian/application-data/bitbucket -Dbitbucket.install=/opt/atlassian/bitbucket -Xms512m -Xmx1g -XX:+UseG1GC -Dfile.encoding=UTF-8 -Dsun.jnu.encoding=UTF-8 -Djava.io.tmpdir=/var/atlassian/application-data/bitbucket/tmp -Djava.library.path=/opt/atlassian/bitbucket/lib/native;/var/atlassian/application-data/bitbucket/lib/native -XX:+IgnoreUnrecognizedVMOptions --add-opens=java.base/sun.nio.ch=ALL-UNNAMED --add-opens=java.base/java.lang=ALL-UNNAMED --add-opens=java.base/java.io=ALL-UNNAMED --add-opens=java.naming/com.sun.jndi.ldap=ALL-UNNAMED com.atlassian.bitbucket.internal.launcher.BitbucketServerLauncher start --logging.console=true
  • A malformed home page displays with header and footer details, as shown in the attached screenshot above. 
  • Proxy server, F5, or Load Balancer are up and active with no errors in their logging.
  • Below are the application logs referencing the issue:


bitbucket-application.log
2024-08-14 16:08:31,912 DEBUG [https-jsse-nio-9443-exec-1] @X5227x968x50x0 eht8ts 127.0.0.1,127.0.0.1 "GET /mvc/error404 HTTP/1.0" c.a.s.i.web.ErrorPageController Page not found attempting to access [/bitbucket/dashboard]
atlassian-bitbucket-access.log server.proxy-name=example.com/bitbucket
127.0.0.1,127.0.0.1 | https | i@X5227x968x50x0 | - | 2024-08-14 16:08:31,906 | "GET /mvc/error404 HTTP/1.0" | "" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/127.0.0.0 Safari/537.36" | - | - | - | - | - | eht8ts | 
127.0.0.1,127.0.0.1 | https | o@X5227x968x50x0 | - | 2024-08-14 16:08:31,961 | "GET /mvc/error404 HTTP/1.0" | "" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/127.0.0.0 Safari/537.36" | 404 | 0 | 15459 | - | 55 | eht8ts |  

Cause

Context path not set correctly in <bitbucket_home>/shared/bitbucket.properties file.

Context path was appended at the end of the proxy name and incorrectly included the context path:

server.context-path=/bitbucket
server.proxy-name=http://localhost:7990/bitbucket

Solution

The correct way to set the context path, as also detailed on our Bitbucket context path page, is to add below properties in  <bitbucket_home>/shared/bitbucket.properties file. Note the proxy-name URL no longer includes the context name.

server.context-path=/bitbucket 
server.proxy-name=http://localhost:7990/



Last modified on Sep 30, 2024

Was this helpful?

Yes
No
Provide feedback about this article
Powered by Confluence and Scroll Viewport.