What is physical to virtual (P2V)?
Physical to virtual (P2V), also called hardware virtualization, refers to the migration of physical machines to virtual machines (VMs).
Developers using a P2V approach transfer their physical environment into a digital one. By doing this, they use less hardware and physical space, and reap the benefits of VMs, including more flexibility because VMs can run on multiple platforms. P2V is commonly used for server virtualization. It is also popular as a way for Mac users to run Windows applications.
Data migrated in P2V includes an operating system (OS), applications, programs and data from a computer's main hard drive. It's moved to a VM or a disk partition. Tools such as Micro Focus' PlateSpin> Migrate and Microsoft's vContinuum save the data gathered from the physical machine as an image, which a hypervisor reinstalls on a VM. The result is a VM with the same data, applications and system configurations as the physical server being virtualized.
How physical to virtual works
Before initiating P2V, IT admins must assess how many resources their physical system uses to determine how many resources a new VM will consume. This is necessary to ensure the host VM has the resources needed to host the virtualized platform.
Performance monitoring tools such as Nagios and Zabbix can be used to determine resource consumption. Information about a server, such as memory, disk space and processor load, provides insight into its resource consumption and what that would look like in a VM.
A P2V tool saves a physical machine's state as an image. Data that composes a physical server or system is electronically copied in the same way that a Docker container creates an image to save data. A hypervisor installs the image in the specified storage space. A person or hypervisor can then determine the location of each required resource.
A virtual infrastructure can't always emulate legacy hardware. For instance, none of the major virtualization platforms support 16-bit guest OSes. As a result, performing a P2V migration with a DOS-based accounting package running on 16-bit hardware isn't an option.
Manual vs. automated P2V
P2V migration can be manual, automated or semiautomated. Here's how each of those approaches works:
P2V involves creating or defining a virtual environment and then reinstalling the OS, applications and data on it. This can be a tedious, uncertain process, especially if the new environment contains substantially different hardware than the old environment.
A semiautomated P2V tool assists with only certain phases of migration, as opposed to automating the full migration. For example, the VMware vCenter Converter is a centralized management utility that can convert both Windows- and Linux-based physical machines and support numerous image formats. It features a centralized management console and can convert both local and remote machines. Local installation enables a user to migrate local machines to a VM, while remote installation lets a user migrate a system remotely via a client system. It is semiautomated because the user still intervenes manually to move the physical server to the virtual environment in some phases, such as moving specific applications to a virtual server.
VMware vCenter Converter can also perform hot and cold migrations. It's helpful to understand the differences between the two. A hot migration occurs when the system being migrated is in a running state; a cold migration is when the system is offline. Some physical machines, such as Active Directory controllers, aren't recommended for a hot migration. Cold migrations are recommended for systems that update regularly, such as SQL servers. VCenter Converter will convert various types of machines, including physical ones and Hyper-V VMs. However, VMs that vCenter Converter creates will only support other VMware software as a destination.
P2V uses specialized programs called migration tools. This approach is much faster than manually rebuilding the contents of a physical system in a VM. Fully automated P2V tools migrate a physical machine to a VM without user assistance. The image is then customized if necessary.
PlateSpin Migrate is a fully automated P2V tool that automatically discovers Windows and Linux machines. If installed on a Windows server and on the same domain as other Windows servers, it adds those machines to workgroups, and captures and deploys server images. It also can perform multiple scheduled and manual migrations. And it supports other migration types, such as migrating VMs through different virtualization formats and migrating systems and data from VMs to physical machines.
P2V migration has many advantages, including the following:
- Efficiency savings. VMs require less hardware, physical space, power consumption and repairs to run. So, migrating to them saves operating expenses.
- Flexibility. VMs can run on multiple platforms, expanding migration options. Old hardware can be phased out and space can be saved because multiple VMs can run on a single server.
- Availability. If the hardware a VM runs on fails, the VM can be placed on a working server with minimal downtime. VMs are not tied to any one physical component, and therefore can be migrated as necessary.
- Testing. Developers can use VMs as a sandbox to test new and potentially hazardous component changes or code before putting them in a live environment.
- Lifespan. Physical enterprise hardware will eventually wear out. Virtual machines are abstracted from underlying hardware and can last much longer. As hosts age, become obsolete or die, the VM can be migrated to a new one.
P2V methodologies do come with challenges, such as the following ones:
- Configuration issues. P2V doesn't remove any configuration issues with the system or applications when migrated. Specialized hardware such as USB devices or video cards might require significant configurations or may not migrate correctly.
- Legacy hardware. Some legacy hardware cannot be emulated in a virtual infrastructure.
- Performance. Bare-metal servers typically outperform virtualized servers. Bare-metal servers are often preferred in applications where it's critical to have as much performance power as possible. VMs on the same server can contend for resources, which can hamper performance.
- Risk. Certain server types or servers used in different applications don't lend themselves to virtual conversion. For example, domain controllers must be in sync with each other, and virtualizing one could cause synchronization issues.
P2V use cases
A business might implement P2V for a variety of reasons such as the following:
- Infrastructure simplification. Virtualized infrastructure maintenance and management is easier than physical infrastructure management. Users can access servers via a single login as opposed to accessing them physically. Other IT infrastructure management tasks like disaster recovery, server consolidation, monitoring and security are also easier with virtualization.
- Going green. Because virtual servers require less hardware, they produce less greenhouse gas emissions, making P2V a viable way to achieve a greener data center and reduce its carbon footprint.
- Disposing of legacy hardware. Legacy hardware increases maintenance costs and decreases overall system performance. Virtualization is one way to replace aging hardware.
- Future-proofing. If an organization anticipates its infrastructure might change in scale in the future, going virtual could be a smart move. Physical instances have set random access memory and other resource limits; virtual hard disks (VHD) are more scalable and flexible.
- Testing environments. Virtual machines can bring images of production environments into virtual sandboxes to troubleshoot issues without putting the production environment at risk.
P2V conversion tools
P2V conversion tools include the following:
- Microsoft Disk2VHD. This is free software that lets users convert a physical disk into a corresponding VHD or VHDX file. It creates a virtual instance for the Hyper-V environment and can be used to create an image backup of a system.
- Microsoft System Center Virtual Machine Manager. The successor to Microsoft Virtual Machine Converter, it supports Microsoft Hyper-V and Microsoft Azure Users can choose to create a VM that one of those two supports. This tool offers a single pane of glass for managing Hyper-V infrastructures.
- PlateSpin Migrate. This tool helps users manage both physical and virtual workloads for VMware, Hyper-V and Citrix XenServer.
- VMware P2V Assistant. This is a VM migration tool for Windows that can turn existing images of physical systems into VMware VMs without the need to reconfigure software environments or reinstall applications.
Once an organization abstracts software from the physical hardware, it can choose from multiple hypervisor types. Learn the difference between hosted and bare-metal virtualization and how to choose between them.