Hi,
I am trying to restore a existing Bitbucket server and database to a new Bitbucket and database server. Essentially, I would like to test some backups of our existing Bitbucket server.
I have currently loaded up a new Redhat VM to have the new Bitbucket and Postgres Database installed on it. I have got a backup copy of the Bitbucket Home Directory and our Postgres Database backup.
I am not sure what the next steps are in order to perform a new Server and Database restore. Is anyone able to provide any input or a step by step guide?
I have reviewed the following https://confluence.atlassian.com/bitbucketserver/bitbucket-server-backup-client-776640064.html however it does not seem to apply to my Scenario as I want to restore my current BB server and BB database to a whole new BB server and new BB database.
Hi Khang,
As you are using the Home Directory archive and DB dump I would first install the same versions of Bitbucket and Postgres on your new VM.
Next overwrite the new Bitbucket Home Directory with your backup.
Create a new database in Postgres, you can find details on this here depending on your version: https://confluence.atlassian.com/bitbucketserver/connect-bitbucket-to-postgresql-776640389.html
Now Import the DB backup into the new database.
Update bitbucket.properties (<Bitbucket home directory>/shared) so it uses the new DB and url settings etc.
See Step 4: https://confluence.atlassian.com/bitbucketserver/migrating-bitbucket-server-to-another-server-776640406.html
Ensure permissions on the restored home directory are correct.
At this point Bitbucket should now start and have the data from the source Bitbucket.
There can be more to this such as any bespoke config in the previous install directory. The Proxy/SSL/Network setup.
Hopefully that helps
Hi,
Thanks for providing the guide. What i've done is clone our existing psotgres database server and loaded up a brand new Bitbucket server.
I installed the Bitbucket service and pointed the database location to go to our cloned database.
Copied all the bitbucket home directory over to the new bitbucket server and it looks like the restore process went well.
Thank you and all looks to be working now.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.