Hi all,
I've just completed a vCenter v4.1 to v5.5 upgrade where I had to migrate the vCenter 4.1 server and its database to a new vCenter 5.5 machine. My customer wanted to retire their existing vCenter v4.1 server because it's end-of-life and doesn't have the sufficient CPU/RAM/Storage requirements that vCenter 5.5 demands, but wanted to keep all the config settings and historical performance stats that are held in the VC SQL-Express database. Here's how I did it. Please don't hesitate to make comment on my procedure:-
The following VMware KB articles were referenced for this procedure. I have customized them for this procedure. Please refer to them for full details:-
KB5850444, KB1029864, KB1029864.
1. Install a 64-bit Windows OS on a new vCenter server. Lets call this new server "vc5" and let's call the current vCenter 4.1 server "vc4". Make sure that the hostname/ip address of vc5 is properly registered in DNS - forward and reverse pointer records created and work successfully.
2. On vc4, use SQL Management Studio Express to take a backup of the vCenter database. It is desirable to shutdown the vCenter services beforehand and keep them disabled.
3. Install the SQL-2008-R2-Express software from the "redist" folder on the vCenter 5.5 DVD onto vc5. Also download and install the relevant version of SQL Management Studio Express.
4. On vc5, launch SQL Management Studio, create a "fictitious" vCenter database of the same name as the VC 4.1 database, right-click it and restore the backup.
5. On vc5, create a 64-bit ODBC DSN using the SQL Native Client v10 driver pointing to the restored vCenter database that's still in "vCenter 4.1 format". Ensure ODBC connectivity tests are successful.
6. If the Windows OS version on vc5 and vc4 are the same, the ADAM database must also be migrated to vc5 by first backing it up as follows:-
For example: create full C:\Backup\VMwareVCMSDS
You see output similar to:
ifm: create full C:\Backup\VMwareVCMSDS Creating snapshot... Snapshot set {93758b0e-0b5f-4969-a3ae-c3672b659e08} generated successfully. Snapshot {d3257ca1-cb91-4535-82c0-8aa38bc0b566} mounted as C:\$SNAP_201010251019 _VOLUMEC$\ Initiating DEFRAGMENTATION mode... Source Database: C:\$SNAP_201010251019_VOLUMEC$\Program Files\VMware\Infras tructure\VirtualCenter Server\VMwareVCMSDS\adamntds.dit Target Database: c:\Backup\VMwareVCMSDS\adamntds.dit
Defragmentation Status (% complete)0 1020 30 40 50 60 70 80 90 100|----|----|----|----|----|----|----|----|----|----|...................................................Snapshot {d3257ca1-cb91-4535-82c0-8aa38bc0b566} unmounted.IFM media created successfully in C:\Backup\VMwareVCMSDS
6. Exit dsdbutil:
7.At the ifm: prompt, type quit, then press Enter.
8. At the dsdbutil: prompt, type quit, then press Enter.
7. On vc5, stop and restart the vCenter SQL Database service, then insert the vCenter 5.5 DVD and get it to do a fresh install. Do not select the Simple Install option. Install each component one at a time. When the vCenter Server component installation gets to the database part, you tell it to use the DSN created in step 5 and it will detect that it's a vCenter 4.1 database and prompt you to upgrade it.
8. If the Windows OS version on vc5 and vc4 are the same, the ADAM database must be restored as follows:-
3. Run this command to copy the ADAM backup that was created using dsdbutil.exe in step 6 to the folder that contained the original ADAM database and log files:
Note: In vSphere 5.1 and vSphere 5.5, the VMwareVCMSDS folder is located:
xcopy /os backup_location\adamntds.dit "%ProgramData%\VMware\VMware VirtualCenter\VMwareVCMSDS"Where backup_location is the folder path within which the ADAM database was backed up. For example:
xcopy /os C:\Backup\VMwareVCMSDS\adamntds.dit "c:\Program Files\VMware\Infrastructure\VirtualCenter Server\VMwareVCMSDS"
4. Start these services in this order:
VMware VirtualCenter Server
VMwareVCMSDS
VMware VirtualCenter Management Webservices
9. Check the /etc/hosts files on the ESXi servers and remove any references to vc4 if they exist. Check that the ESXi servers can ping vc5 by name and IP.
10. Using the vSphere 5.5 client, login to vCenter on vc5 as Administrator@vsphere.local. Re-connect the ESXi hosts and monitor that the new vCenter agents and HA agents get installed successfully.
11. Goto vCenter Server Settings and select Runtime Settings. Replace the hostname of vc4 with vc5 and put vc5's IP address as the Managed Server.
12. Still in vCenter Server Settings, select Advanced Settings and carefully change all URL entries to point to the new vc5 server's name.
13. Reboot vc5. Login to vCenter using the vSphere Client and from the Home screen, select vCenter Service Status. Check that all services have big green ticks. If there are any red crosses:-
Follow the instructions in VMware KB 2006132 and NOTE in step 6, replace "cleanup.bat com.vmware.converter" with "cleanup.bat com.vmware.xxxxx", where xxxxx is the name of the service with the red cross.
Thanks a lot for such detailed steps. It is going to help others on community from your experience.
My pleasure. I look forward to others trying this procedure and providing their feedback.
George.
vCenter Server has inter-dependencies with other services. Care must be taken to not break any of these inter-dependencies. As with any major change in your infrastructure, good backups are essential in providing smooth, limited downtime changes.
To move your vCenter Server and SQL database:
Shutdown the VMware VirtualCenter Server service.
Take a backup of the SQL database.
If the SQL database is also being moved, create a second instance of your database and use the vendor's tools to migrate the data.
Note: If you are using an Oracle database, create a second instance of your database and migrate the Oracle database schema, vpxadmin. For more information regarding migrating oracle databases, contact your software vendor.
If you are migrating a vCenter Server 4.x/5.x database, you must also migrate the ADAM database. You can migrate this database if the Windows versions in the source and the destination is the same. If not, vCenter might not operate properly and/or the client might fail during connection.
Create the appropriate System DSN connections on the new vCenter Server host.
To copy the VirtualCenter Server SSL certificates:
- Create the this folder structure on the new server:
C:\ProgramData\VMware\VirtualCenter Server\SSL
Begin the installation of the vCenter Server software on the new server. If you are installing vCenter Server in a virtual machine, see the vCenter Server and the vSphere Client Hardware Requirements section of the ESXi Installable and vCenter Server Setup Guide and Technical Resource Center for guidelines to deploy vCenter Server in a virtual machine, including sizing, installation, functionality, and configuration of VMware High Availability (HA).
When prompted, select Use existing database, and provide the correct credentials to that database.
When prompted, select to not re-initialize the database to preserve all of your inventory data.
Hi Robert,
What you wrote sounds very much like one of the four VMware KB articles that I made reference to in my post. As I mentioned at the top of my post, my procedure is heavily based on a number of VMware KBs I used. I collated all the important things from the KBs in putting together my step-by-step guide. I recommend anyone wanting to follow my guide to read all KBs I made references to and then follow my guide. My guide includes tips & tricks that are not mentioned in the KBs. For example, my step No 7 says "On vc5, stop and restart the vCenter SQL Database service, then insert the vCenter 5.5 DVD and get it to do a fresh install. Do not select the Simple Install option. Install each component one at a time..". This tip isn't mentioned in any of the KBs. Also, my steps 11 to 13 aren't mentioned in any of the VMware KBs.
Many thanks,
George.
Hi gparker,
I just found your thread by random chance.
Very useful information, thank you for your informative post.
My pleasure
Please provide any feedback, I'm happy to tweak my procedure.