Porter command reference

Porter command reference

Reference for the Porter command-line flags. Porter installs to /usr/local/sbin/porter and must be run with sudo. Supplying the input flags lets you skip the corresponding interactive prompts.

Mode flags

Specify one mode flag.

FlagDescriptionDefault
--localConvert a file that is already on the SC//Reliant host.Yes, this is the default mode
--esxiStream the disk directly from an ESXi host over SSH.No

Input flags

Use these flags to supply values that Porter would otherwise prompt for.

FlagDescription
--file <path>Path to a local .ova, .ovf, or .vmdk file. Skips the file picker.
--esxi-host <host>ESXi hostname or IP address.
--esxi-vm <name>Name of the source VM. Must be an exact match for the name on the ESXi host.
--pass <password>ESXi root password, supplied inline. Used once to install the SSH key.
--pass-file <path>Path to a file containing the ESXi root password. Used once to install the SSH key.

Omit both password flags if an authorized SSH key is already seeded at /root/.ssh/id_rsa. See Running a Porter migration.

Conversion flags

FlagDescription
--linuxTreat the guest as Linux. Skips the Windows VirtIO driver injection and the VMware Tools cleanup script.
--no-driversConvert the disk without injecting VirtIO drivers.
--rawUse qemu-img for the conversion instead of virt-v2v.
--virtio-iso <path>Path to a specific virtio-win ISO to use for driver injection.
--post-migration-script <path>Windows path to an existing script already present on the VM, to be run as SYSTEM after cleanup completes.

Output flags

FlagDescriptionDefault
--output-dir <path>Directory where the finished QCOW2 file is written.—
--temp-dir <path>Working directory used during conversion./mnt/kvm_backups
--debugProduce verbose output.—

Examples

Run fully interactively against an ESXi host.

sudo porter vmware --esxi

Run a fully unattended Windows migration from ESXi using a seeded SSH key.

sudo porter vmware --esxi \
  --esxi-host <host> \
  --esxi-vm <VMNAME> \
  --virtio-iso /mnt/gold-images/iso/virtio-win-0.1.271.iso \
  --output-dir /kvm/<name> \
  --post-migration-script 'C:\path\to\validator.ps1'

Convert a local export of a Linux guest.

sudo porter vmware --local \
  --file <path_to_file> \
  --linux \
  --output-dir /kvm/<name>