ldmp2v - command-line interface for the Oracle VM Server for SPARC Physical-to-Virtual (P2V) Conversion Tool
ldmp2v collect [-a flash|none] [-O "flarcreate-options"] [-v] [-x mount-point [-x ...]] -d data-dir ldmp2v prepare [-b zvol|file|disk] [-B backend:volume:vdisk [-B ...]] [-c cpu] [-m mount-point:size [-m ...]] [-M memsize] [-o keep-hostid] [-o keep-mac] [-p prefix] [-s] [-v] [-x no-auto-adjust-fs] [-x remove-unused-slices] -d data-dir domain-name ldmp2v prepare -R guest-root [-c cpu] [-M memsize] [-o keep-hostid] [-o keep-mac] [-v] -d data-dir domain-name ldmp2v prepare -C domain-name ldmp2v convert -i install-image -d data-dir [-v] [-x skip-ping-test] domain-name ldmp2v convert [-j] -n interface -d data-dir [-v] [-x skip-ping-test] domain-name
The Oracle VM Server for SPARC Physical-to-Virtual (P2V) Conversion Tool automatically converts an existing physical system to a virtual system that runs the Oracle Solaris 10 OS in a logical domain on a chip multithreading (CMT) system. The source system can be any sun4u SPARC system that runs at least the Solaris 8, Solaris 9, or Oracle Solaris 10 OS, or a non-Logical Domains sun4v system that runs the Oracle Solaris 10 OS. An image of the source system is converted into an Oracle VM Server for SPARC domain, upgrading to the current Oracle Solaris 10 version during the process, if necessary.
The conversion from a physical system to a virtual system is performed in the following phases:
Collection phase. Runs on the physical source system. collect creates a file system image of the source system based on the configuration information that it collects about the source system.
Preparation phase. Runs on the control domain of the target system. prepare creates the logical domain on the target system based on the configuration information collected in the collect phase. The file system image is restored to one or more virtual disks. The image is modified to enable it to run as a logical domain.
Conversion phase. Runs on the control domain of the target system. In the convert phase, the created logical domain is converted into a logical domain that runs the Solaris 10 OS by using the standard Solaris upgrade process.
The following sections describe how the conversion from a physical system to a virtual system is performed in phases.
ldmp2v collect [-a flash|none] [-O "flarcreate-options"] [-v] [-x mount-point [-x ...]] -d data-dir
The ldmp2v collect command uses the following options:
Specifies the archiving method to use. Valid values are flash or none. The default is flash.
Specifies a quoted list of options to pass to the flarcreate command. The only flarcreate options permitted are –c and –x. The –c option compresses the archive, and the –x option excludes files or directories from the archive. You can specify more than one flarcreate option. The –O option can be used only when you use –a flash to specify the flash archive method.
Uses verbose mode, which increases the verbosity of the messages that are issued by ldmp2v.
Excludes the file system, mounted on mount-point, from the archive.
Specifies the per-system directory in which to store P2V files. For the collection phase, this directory must be writable by root. Any intermediate directories are created automatically.
ldmp2v prepare [-b zvol|file|disk] [-B backend:volume:vdisk [-B ...]] [-c cpu] [-m mount-point:size [-m ...]] [-M memsize] [-o keep-hostid] [-o keep-mac] [-p prefix] [-s] [-v] [-x no-auto-adjust-fs] [-x remove-unused-slices] -d data-dir domain-name ldmp2v prepare -R guest-root [-c cpu] [-M memsize] [-o keep-hostid] [-o keep-mac] [-v] -d data-dir domain-name ldmp2v prepare -C domain-name
The ldmp2v prepare command uses the following operand and options:
Specifies the logical domain on which to operate.
Specifies the back-end type to use. The virtual disks can be backed by ZFS volumes, zvol, plain files, file, or physical disks or volume manager volumes, disk. This option overrides the setting for BACKEND_TYPE in /etc/ldmp2v.conf.
Specifies the name of the back-end device and, optionally, the name of the volume and virtual disk to create. If the volume or vdisk value is omitted, a default name is used. You can omit values by specifying the colon character (:) for each value to omit. For example, these are valid uses of the –B option: –B ::vdisk01 and –B :volume001.
This option is required for the disk back end and should at least specify a back-end device, such as /dev/dsk/c0t2d0s2 or /dev/md/dsk/d100. For the disk back end, specify one –B option for each disk that is present in the manifest for the physical system.
For the zvol and file back ends, you can use backend to specify a file or ZFS dataset that ldmp2v should create for the virtual disk. For example, –B data/ldom1/disk0. Use the –B option to specify the back-end name and override the default name. The default name is generated by the –p option, or by the BACKEND_PREFIX setting in /etc/ldmp2v.config and the domain name.
Allocates the number of VCPUs to the logical domain. By default, ldmp2v allocates a VCPU for each CPU on the physical system.
Cleans up the specified domain.
Specifies the per-system directory where the files required for P2V are located.
Resizes the underlying slice and disk for the file system at mount-point. The size is specified as numunit. num is the amount of space and unit is b for blocks, k for Kbytes, m for Mbytes, or g for Gbytes. You can specify this option more than one time. This option disables the automatic resizing of /, /usr, and /var. If mount-point is swap, the first configured swap device is resized to size.
Specifies the amount of memory to allocate to the logical domain. The memory size is specified as numunit, where num is the amount of memory and unit is one of the following:
m or M represents Mbytes
g or G represents Gbytes
If unit is not specified, the unit is Mbytes.
By default, the ldmp2v command allocates the same amount of memory that is in the physical system to the logical domain. If required, the memory size specified by the –M option is adjusted upward to 1 Gbyte to satisfy the minimum memory size for a guest domain.
Transfers the host ID of the physical system to the logical domain. By default, the Logical Domains Manager assigns a new unique host ID.
Transfers the MAC addresses of the physical system to the logical domain. By default the Logical Domains Manager assigns a new unique MAC address.
Specifies the location where backend devices will be created. Denotes the ZFS dataset for the zvol backend, or a directory relative to / for the file backend. This option overrides the BACKEND_PREFIX parameter in /etc/ldmp2v.conf.
Selects non-automatic mode. The OS image modification steps are applied to the file system rooted at guest-root. Updates the /etc/vfstab of the logical domain to match the file system layout below guest-root.
Creates sparse backend devices. This option overrides the BACKEND_SPARSE parameter in /etc/ldmp2v.conf.
Uses verbose mode, which increases the verbosity of the messages that are issued by ldmp2v.
Prevents the automatic size adjustment of the /, /usr, and /var file systems to 10 Gbytes total. Use this option with care because the size of the existing file systems might not be sufficient to upgrade to a newer Solaris release.
You can manually resize file system sizes by using the –m option.
Reduces the size of the virtual disk by not creating slices that do not hold a file system or a swap device.
ldmp2v convert -i install-image -d data-dir [-v] [-x skip-ping-test] domain-name ldmp2v convert [-j] -n interface -d data-dir [-v] [-x skip-ping-test] domain-name
The ldmp2v convert command uses the following options:
Specifies the per-system directory where the files required for P2V are located.
Specifies the path to the Solaris 10 OS DVD ISO image to use for upgrade.
Uses Custom JumpStart, which requires that a JumpStart server and JumpStart client are properly configured.
Specifies the virtual network interface from which to boot when using a network install server.
Uses verbose mode, which increases the verbosity of the messages issued by ldmp2v.
Skips the ping test that is performed to determine whether the IP addresses of the source system are up. Use this option only if you are certain that no duplicate IP addresses will exist, such as when the original system is not active.
![]() | Caution - Before you begin the conversion phase, shut down the original physical system, as the logical domain uses the same IP addresses, and possibly also MAC addresses, as the physical system. If any IP address of the physical system is active, the ldmp2v convert command exits with an error message. |
This section includes examples for the three phases.
Example 1 Collection Phase ExamplesThe following examples show how you might use the ldmp2v collect command.
Sharing an NFS-mounted file system. The following example shows the simplest way to perform the collect phase, where the source and target systems share an NFS-mounted file system.
# ldmp2v collect -d /home/dana/p2v/volumia
Not sharing an NFS-mounted file system. When the source and target systems do not share an NFS-mounted file system, the file system image can be written to local storage and then later copied to the control domain. Use the flash archiving method that is provided by ldmp2v. The flash tool automatically excludes the archive it creates.
# ldmp2v collect -d /home/dana/p2v/volumia -a flash
Skip file-system backup step. If backups of the system are already available using a third-party backup tool such as NetBackup, you can skip the file system backup step by using the none archiving method. When you use this option, only the system configuration manifest is created.
# ldmp2v collect -d /home/dana/p2v/volumia -a none
Exclude a file or directory from the flash archive. When using the flash archiving method, you can exclude a file or directory from the archive by passing options to the flarcreate command. This capability requires that you have at least the following patch revisions installed on the source system:
Solaris 8 OS: Patch ID 109318-34
Solaris 9 OS: Patch ID 113434-06
# ldmp2v collect -d /home/dana/p2v/volumia -a flash -O "-x /path/to/file -x /some/dir"
The following examples show how you might use the ldmp2v prepare command.
The following example creates a logical domain called volumia by using the defaults configured in /etc/ldmp2v.conf while keeping the MAC addresses of the physical system:
# ldmp2v prepare -d /home/dana/p2v/volumia -o keep-mac volumia
The following shows how to completely remove a domain and its backend devices by using the –C option:
# ldmp2v prepare -C volumia
The following shows how to resize a file system and the swap device during P2V by using the –m option:
# ldmp2v prepare -d /home/dana/p2v/normaal -m /:8g -m swap:4g normaal
The following shows how to use Solaris Volume Manager metadevices d100 and d101 as back-end devices for the guest domain and to set the name of the first virtual disk to vdisk100:
# ldmp2v prepare -b disk -B /dev/md/dsk/d100::vdisk100 -B /dev/md/dsk/d101 -d /p2v/volumia volumia
The following shows how to use ZFS volumes with non-default ZFS volume names:
# ldmp2v prepare -b zvol -B tank/ldom1/zvol1 -B tank/ldom1/zvol2 -d /p2v/volumia volumia
The following examples show how you might use the ldmp2v convert command.
Using a network install server. The ldmp2v convert command boots the logical domain over the network by using the specified virtual network interface. You must run the setup_install_server and add_install_client scripts on the install server.
Optionally, you can use the Custom JumpStart feature to perform a completely hands-off conversion.
The following shows how to use a network install server to upgrade your system:
# ldmp2v convert -n vnet0 -d /p2v/volumia volumia
The following shows how to use Custom JumpStart to upgrade your system:
# ldmp2v convert -j -n vnet0 -d /p2v/volumia volumia
Using an ISO image. The ldmp2v convert command attaches the Solaris DVD ISO image to the logical domain and boots from it. To upgrade, answer all sysid prompts and select Upgrade.
# ldmp2v convert -i /tank/iso/s10s_u5.iso -d /home/dana/p2v/volumia volumia
The following exit values are returned:
Successful completion.
An error occurred.
See the attributes(7) man page for a description of the following attributes.
|