Jul 28, 2019

VMWare : Clonning from Physical to Virtual

Recently I've encounter some problems of converting a CentOS v.5.0 into VMWare ESXi v.6.7, this is particularly due to the tool (vCenter Converter Standalone) doesn't support CentOS v.5.0

So, instead of installing a brand new CentOS v.7.0 and migrate all the Oracle database into the new VM (Virtual Machine) manually, I proceeded to "clone" the physical machine.

There are some considerations before proceeding, the physical server's hardware specifications. How much RAM was installed, how many "Logical Array" is using. This will impact the creation of the VM, as such the ESXi server (host) must have sufficient hardware to support such a move.

The process is relatively easy, as this is done through "Direct Console Login", I was not able to provide the screenshots due to security issues. But nonetheless this are the steps I've taken and was successful.

Assumption :

a) The existing physical server (CentOS 5) hardware is 2 x NICs, 8GB RAM, 300GB x 2 RAID1, 300GB x 2 RAID1, 600GB x 2 RAID1.

(Note : a total of Three (3) logical drives was present, this part is important at the later stage).

b) External USB 2TB or more HDD.


The Steps-by-Steps :

1. Download the latest version of CloneZilla. At time of writing, the latest stable version v.2.6.2-15 and the edition I've downloaded is (i686, ISO) which is compatible with the server's hardware.

2. Using your preferred ISO burner, burn a bootable CDROM disc and you might want to label it for easy references.

3. Shutdown the CentOS 5 server by running command : shutdown now -h

4. Insert the CloneZilla bootable CDROM disc and plugin the External USB HDD into the CentOS 5 server.

5. Power-up the server and Press --> [F12] key.
* Note : Your server might have different key for invoking the "Boot Menu".

6. Select booting from the CDROM drive and wait for CloneZilla to boot automatically.

7. Follow the on-screen instructions, like language & keyboard selection.

8. Next is to select --> device-image option.

9. Then select --> local_dev option, then it will prompt you to press [ENTER] key to continue.

10. At the next screen, you will be shown a list of all the local drives & external USB drives detected. Just press [CTRL] + [C] to continue. You need to ensure the external USB HDD is detected correctly.

11. Next screen is to select "Home/PartImg" location, which in this case is the external USB HDD drive.

12. Next screen when prompt, just select --> OK button to continue, then it will prompt you what is the task you wanted to perform, in this case we select --> save_disk option.

13. Next it will prompt you for the image's filename, put a name that is simple & easy to remember (eg. svr_centos5_28Jul19), next is to ensure the image file size is unlimited, type --> 1000000 to ensure Clonezilla will not split the file according to 4GB limitation.

14. Leave the compression as default at either Z0 or Z1, of course you can have higher compressions but since I have a 2TB drive... so not a problems.

15. Next is the encryption prompt, this all depends on you. But as I'm the only 1 person in-charge & I do not need to keep the image after restoring, I will not encrypt the image files.

16. When prompted, just press --> [Y] to start the clonning process, this may takes a few hours (mine took me 14 hours) and select --> Shutdown when completed.

Note : More information can be found at Clonezilla website, please do visit their website.


17. Once all is completed, we will be moving the VMWare server. First we need to create VM and all the configurations must match exactly as the CentOS 5 server, such 2 x NICs, 3 x Drives & 8GB RAM.

18. For the selection of Guest OS, I've selected --> CentOS 4/5 64-bit version.

19. Also I've configured the CDROM to use an ISO image file instead of the host's drive. I need it to boot into CloneZilla for the image restoration.

20. Next is plugged in the external USB HDD into the host server and add a "USB Device" in the VM, this is to ensure the drive is detected properly.

21. The following is boot the VM into CloneZilla and start restoring "restore_disk" process, leave everything as default will do.

Oh, you might want to select --> "Skip checking source image" option & "Shutdown" after complete.

22. Before power-on the VM, you need to remove the external USB HDD from the settings and also the ISO file.

23. Just power-on the VM like normal & look out for any irregular warnings or critical messages. But thus far I've didn't encounter any error messages or similar and everything just works as it was supposed to.


!!! HAPPY COMPUTING !!!

No comments:

Post a Comment