MySQL migration physical server VMware virtual server
You would almost certainly be better off doing a fresh install, taking a backup using xtrabackup, and restoring the config files and the backup into the install inside the VM. That way you could even do it with only seconds of downtime by using replication up to the moment you switch over.