Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

What is the recommended method of migration for Postgres DB from 9.3 to 9.5.

Ravi GH February 12, 2018

Hi Team,

Since postgres 9.3 is EOL in this year we decided to migrate Bitbucket database from Postgres 9.3 to 9.5.

we are also upgrading Ubuntu OS from 14.04 to 16.04.

Hence this Postgres involved movement of DB from Ubuntu 14.04 server to new Ubuntu 16.04 Server.

Has any one had similar situation. What is the recommended method of migration for Postgres DB from 9.3 to 9.5.
We are using BB DataCenter 4.10.1

 

Regards,

Ravi

 

1 answer

1 vote
Mark A_
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
February 14, 2018

Hey Ravi,

 I think upgrading your database from 9.3 to 9.5 is your standard affair and nothing special is needed of Bitbucket outside of confirming that the database version is supported for your version of Bitbucket Server. You can check this by reviewing our Supported Platforms page.

I do recommend that you stage your upgrades and not perform this all at once as this helps isolate any potential issues you encounter.  I also recommend to perform mock upgrades on a testing or staging platform and perform rollback exercises so that you and your team are aware of your expectations post upgrade and have successfully performed steps to recover your environment should something go wrong.

 

Database Upgrade

I view this as being your least impactful, or at least from my personal experience in upgrading my Postgres database. You’ll want to follow the directions from the vendor, but you will need to ensure you stop the database and application. Take a snapshot of the database server, then perform the database upgrade steps. As long as the proper steps for the database upgrade were followed and the database version is supported on your version of Bitbucket Server, you should not have any issues.

 

OS Upgrade

This could be more complicated given that you are upgrading the operating system.  You’ll need to ensure that you have a snapshot taken before the OS upgrade occurs in the event you need to revert back to Ubuntu 14.x

 

Overall

In short, backups and VM snapshots (if you are on VM) are your friends in changes such as these. As noted, please perform these upgrades on Test or Stage before doing production and spread out the upgrades so that you can isolate any issues. Do the database one weekend for example and the OS two weeks later.

If you have to recover, ensure the application & database are both recovered to the same point in time as they both must be kept in-sync.  I hope this helps. Please let me know if you have any other questions.

Cheers,

Mark

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events