Hello, I need to migrate Bitbucket (5.15.1) to a different server.
I have tried the 2 options in this doc to no avail: https://confluence.atlassian.com/bitbucketserver0515/migrating-bitbucket-server-to-another-server-961275665.html
This is what happens when I launch bb
[root@atlassian2 bin]# service atlbitbucket status
Bitbucket is not running (pidfile exists)
[root@atlassian2 bin]# service atlbitbucket start
The JRE_HOME environment variable is not defined correctly
This environment variable is needed to run this program
Edit set-jre-home.sh and define JRE_HOME
Startup has been aborted
[root@atlassian2 bin]# nano set-jre-home.sh
Displaying Java information below shows the same path I put in the set-jre-home.sh script.
[root@atlassian2 bin]# echo $JAVA_HOME
[root@atlassian2 bin]# echo $JRE_HOME
Thank you in advance for any assistance.
Hi @Suhas Patil thanks for the response. It went into Spam so I apologize for the late reply.
I have reverted back to a snapshot prior to setting things up. I have done a
sudo ./atlassian-bitbucket-5.15.1-linux-x64.bin to get it to install successfully as a Service.
the results of your query is below, so it appears correct.
[root@atlassian2 bitbucket]# echo $JAVA_HOME
[root@atlassian2 bitbucket]# echo $JRE_HOME
[root@atlassian2 bitbucket]# echo $PATH
Now I need to get my data incorporated into this instance. I was hoping copying the existing Production Home and Install directories and their subdirectories (and import the mysql database) would get me back to where I need to be. Do you have an opinion/suggestion on this approach?
Thank you again.
In reviewing the set-jre-home.sh file it contains a totally different path:
[root@atlassian2 bin]# cat set-jre-home.sh
if [ -z "$JRE_HOME" ]; then
if [ -z "$JAVA_HOME" ]; then
# If JRE_HOME and JAVA_HOME are not defined, edit this line to define JRE_HOME
elif [ -n "$JAVA_HOME" ] && [ -x "$JAVA_HOME/jre/bin/java" ]; then
# If JAVA_HOME points to a valid JDK, use its JRE
elif [ -n "$JAVA_HOME" ] && [ -x "$JAVA_HOME/bin/java" ]; then
# If JAVA_HOME appears to point to a JRE and not a JDK use this anyway
How does that happen?
That explains it, you need to modify the set-jre-home.sh with the correct JRE path. It's referring to the non-existing JAVA version.
Regarding copying prod directories, you can do it as long as it's the same instance (not prod to non-prod). Make sure, your database is reachable from the app server.
you would never be able to get it working in the first shot, you will have to deal with many issues for sure. So i would recommend migrating the non-prod to the non-prod server first, fix all the issues there, document them, and then plan the production.
Hi everyone, We are looking to learn more about development teams’ workflows and pain points, especially around DevOps, integrations, administration, scale, security, and the related challeng...
Connect with like-minded Atlassian users at free events near you!Find an event
Connect with like-minded Atlassian users at free events near you!
Unfortunately there are no Community Events near you at the moment.Host an event
You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events