VMWare converter is very powerful tool to provide physical to virtual conversion. It’s quite easy to make P2V of Windows base servers. The last versions of VMware Converter claim to support P2V of Linux based servers. This is true, but there are limits. Linux server running sw raid (mdadm) is one of them.
Here is breif HOWTO:
- stop all important services
- disable these services
- break the mirror
- strip mdadm info from the disk
- change the partition type from fd (Linux raid auto) to 83 (Linux)
- chroot into single disk instance
- rename mdadm.conf
- edit fstab to replace root mountpoint to /dev/sdX
- config the grub to point to /dev/sdX
- build new initrd
- poweroff source server
- remove the proper disk
- boot up with one disk only
These are the steps we performed on SUSE 10 server:
sles10:~ # service oracle-xe stop ... sles10:~ # chkconfig oracle-xe off ... sles10:~ # mdadm --fail /dev/md0 /dev/sdb1 sles10:~ # mdadm --remove /dev/md0 /dev/sdb1 sles10:~ # mdadm --zero-superblock /dev/sdb1 sles10:~ # fdisk /dev/sdb sles10:~ # mount /dev/sdb1 /mnt/ sles10:~ # mv /etc/mdadm.conf{,.old} sles10:~ # chroot /mnt/ sles10:/# vim /etc/fstab sles10:/# vim boot/grub/menu.lst sles10:/# mkinitrd sles10:~ # poweroff
2 Comments
I ran into this issue couple of days back when I was trying to convert a Linux Debian (Lenny) which had a software RAID on it. I did cold cloning and it worked, but I ended up with 2 hard drives. How difficult is it to break the mirror after conversion? I am not overly familiar with Linux so any guidance would be appreciated.
Cheers,
Ranju
Ranju,
It is the very same as on physical. Delete one of virtual disks, and go ahead to destroy SW raid. Remember to create snapshot first…
Regards,
David