Migration Path for the VCSA from vPostgres to.. ??

Wait… there is no way to do that – is there? Is there?

Today I would like to address a point that is perhaps pretty obvious but not really well known, and that is the lack of a migration path out of the vCenter Server Appliance installed with an embedded database.

To understand the issue – let us first understand the process if you were to use a vCenter Server installed on a Windows Server machine.

When you want to try out vCenter, you will install the software on a Windows Server, usually with the embedded SQL EXPRESS database that is provided with the software. VMware stress (and rightfully so) that this should not be used for a production environment and this will only be will be suitable only for 5 hosts and 50 VM’s. But since you only want to try out the software – that should not be an issue.

Fast forward a few months (or weeks or perhaps even days because we know that you will want to have this in production as soon as possible) and you see that this will provide great benefit to you and your company – and now you want to move it into production. This will of course require you to move the database out of the embedded SQL Express instance and put it into a proper SQL Server.

The process is pretty straight forward and has been documented a number of times. VMware even has a KB explaining how this should be done.

Once complete you now have the same VMware environment that you started out with and have been using, including the permissions, the folder structure the statistics and all.

So how would we go about doing the same with the VCSA?

You install the vCenter Server Virtual Appliance and follow the steps including the using the embedded vPostgres database. Again this is not for production use and VMware sizes such a deployment for not more than 5 Hosts and 50 VM’s.

Fast forward again…

You now want to move into production – which means the database will have to be migrated to one that will be able to accommodate growth. Supported databases (for the current version 5.1a) are Oracle and vPostgres.

In most companies I have encountered, the databases that are used in production will be either Microsoft SQL or Oracle.

So how can you migrate out of the vPostgres database?

So here is the catch!!

VMware has no documented way to move the data out of the Embedded vPostgres database into a production, supported database.

Actually – there hardly any documentation – except perhaps this KBabout how you should backup a VCSA appliance.

No export, no migration,  nothing. This means that if you made the assumption of trying out a VCSA and then moving into production…

Yep you guessed correctly – everything has to be rebuilt – again. If your database goes kablooie then pray that you have a full image backup.

Re-register all your hosts, re-create permissions, rebuild the folder structure, etc… etc... etc…
(not that this is not possible – I actually wrote a script quite a while back for this - vCenter PowerCLI Migration Script) it just will take a lot of tinkering. Not to mention of course that you will lose all your statistics collected until the migration.

If VMware could create a migration script between DB2 and vPostgres for the upgrade from 5.0 to 5.1 – then I should hope that they will provide a script to move out of vPostgres as well.

As always – if you would like to share your thoughts – please feel free to do so in the comments below.