Parallels Desktop Pro Edition Command-Line Reference
Parallels Desktop Pro Edition Command-Line Reference
Parallels Desktop Pro Edition Command-Line Reference
Pro Edition
Command-Line Reference
v16
Parallels International GmbH
Vordergasse 59
8200 Schaffhausen
Switzerland
Tel: + 41 52 672 20 30
www.parallels.com
This product is protected by United States and international copyright laws. The product’s underlying technology,
patents, and trademarks are listed at http://www.parallels.com/about/legal/.
Microsoft, Windows, Windows Server, Windows Vista are registered trademarks of Microsoft Corporation.
Apple, Mac, the Mac logo, macOS, macOS, iPad, iPhone, iPod touch are trademarks of Apple Inc., registered in the US
and other countries.
Linux is a registered trademark of Linus Torvalds.
All other marks and names mentioned herein may be trademarks of their respective owners.
Contents
Introduction ............................................................................................................... 4
Command-Line Reference ........................................................................................ 5
Parallels Desktop Management ......................................................................................... 5
Display Parallels Desktop Info .................................................................................................. 5
License Management .............................................................................................................. 6
Parallels Desktop Preferences ................................................................................................. 8
User List and Virtual Machine Location .................................................................................. 10
Virtual Network Info ............................................................................................................... 10
Virtual Network Settings ........................................................................................................ 10
USB Devices ......................................................................................................................... 12
Send Problem Report ............................................................................................................ 12
Shut Down Parallels Desktop ................................................................................................ 13
Parallels Desktop Plugin Commands ..................................................................................... 13
Error Handling ....................................................................................................................... 13
Virtual Machine Management .......................................................................................... 13
General Virtual Machine Management ................................................................................... 14
Virtual Machine Configuration Tasks ...................................................................................... 22
Snapshot Management ......................................................................................................... 39
Miscellaneous Commands .................................................................................................... 41
Virtual Machine Disk Optimization .......................................................................................... 42
Error Handling ....................................................................................................................... 43
Index ........................................................................................................................ 44
CHAPTER 1
Introduction
This guide is intended for users of Parallels Desktop for Mac Pro Edition. It documents the
command-line interface that can be used to manage Parallels Desktop and virtual machines. The
interface supports the majority of Parallels Desktop management tasks that can be performed
using the Parallels Desktop graphical user interface.
Note that to get help about a particular command, you can type man <name_of_the_command>
in Terminal. This will list the command attributes and additional help.
CHAPTER 2
Command-Line Reference
In This Chapter
Parallels Desktop Management ................................................................................ 5
Virtual Machine Management ................................................................................... 13
The subsequent sections describe the available prlsrvctl commands grouped by functionality.
Optional parameters
--license
If included, only the Parallels Desktop license information is displayed.
--activation-id
Command-Line Reference
--deactivation-id
If included, only the license deactivation ID is displayed.
--json
Produces the machine-readable output in JSON format.
License Management
This section describes Parallels Desktop license management tasks.
Optional parameters
-p,--read-passwd <path>
Specifies a text file with your Parallels account password.
Related commands
web-portal signout
Signs you out of your Parallels account.
info --web-portal
Displays the information about whether you are signed in to your Parallels account and lists
details if you are.
Optional parameters
--deferred
Stores the license for deferred installation. The license will be activated the next time Parallels
Desktop is started. If a license has already been activated, it should be deactivated first before
using this option. See the prlsrvctl deactivate-license command.
--activate-online-immediately
Activates the license over the Internet immediately.
Notes
When activating Parallels Desktop Pro or Home editions, you must be signed in to your Parallels
account before executing this command. See Sign in to Parallels Account (p. 6).
Parameters
--install
Installs the license stored for deferred installation.
--remove
Removes the license stored for deferred installation.
Update a License
prlsrvctl update-license
Updates the current Parallels Desktop license.
Notes
Deactivate a License
prlsrvctl deactivate-license [--skip-network-errors]
Deactivates the current Parallels Desktop license. The --skip-network-errors option skips
network errors and removes the license locally.
Parameters
8
Command-Line Reference
Enables or disables automatic rotation of the Parallels Dispatcher Service and virtual machine
log files.
--default-encryption-plugin <plugin-id>
Sets the default encryption plugin.
--reset-default-encryption-plugin
Resets the default encryption plugin.
9
Command-Line Reference
Parameters
10
Command-Line Reference
--ip <ip[/mask]>
Sets an IPv4 address and subnet mask for the Parallels virtual network adapter.
--dhcp-ip <ip>
Sets an IPv4 address for the Parallels virtual DHCPv4 server.
--ip-scope-start <ip>
Sets the start IPv4 address for the pool of IPv4 addresses.
--ip-scope-end <ip>
Sets the end IPv4 address for the pool of IPv4 addresses.
--ip6 <ip[/mask]>
Sets an IPv6 address and subnet mask for the Parallels virtual network adapter.
--dhcp-ip6 <ip>
--ip6-scope-start <ip>
Sets the start IPv6 address for the pool of IPv6 addresses.
--ip6-scope-end <ip>
Sets the end IPv6 address for the pool of IPv6 addresses.
USB Devices
prlsrvctl usb list [-j, --json] [-c, --compat] [-a, --all]
Lists USB devices installed on the server together with the information on their assignments for
the current user. In the compat mode all known USB devices are listed, showing the device
name, device ID and autoconnect options. In the new mode (without the [-c, --compat] option),
some additional information about the device is shown, such as whether the device is
connected to a VM at the current moment. By default, only currently plugged to host devices
are shown. To see all devices, call with the [-a, --all] option.
prlsrvctl usb set <usb_dev_id> <vm_uuid | vm_name> | [--autoconnect <ask | host>] | [--vm
<vm_uuid | vm_name>]
Either assigns a USB device with ID <usb_dev_id> to the specified virtual machine or configures
the action for this device (suggest to connect to active VM or silently connect to host). When
the device is configured to connect to a virtual machine, this USB device will be connected to
the specified virtual machine when you start the virtual machine or attach the device to the host
computer.
Optional parameters
--stand-alone
Assembles a report without connecting to the Parallels Desktop service.
--name <user_name>
Appends the user name to the report.
--email <user_email>
Appends the user email address to the report.
--description <problem_description>
Appends a free-form description to the report.
Error Handling
The prlsrvctl utility returns 0 on success or an error code on failure.
13
Command-Line Reference
Syntax 1
prlctl list
Lists existing virtual machines. By default (when no parameters are included), only running VMs
are displayed.
Optional parameters
-a, --all
Lists all existing virtual machines regardless of their state (running, stopped, suspended, etc.).
-f, --full
Shows the real IP address(es) for running virtual machines.
-L
14
Command-Line Reference
Lists fields which can be used for both the output (-o, --output) and sort order (-s, --sort)
options.
-t, --template
Include templates in the output.
-j, --json
Produces output in JSON format.
Syntax 2
Optional parameters
-f, --full
Shows the real IP address(es) for running virtual machines.
-j, --json
Produces output in JSON format.
vm_id | vm_name
Returns the information about a VM specified by ID or name.
Syntax 1
Optional parameters
--dst
A path to the directory where the virtual machine files will be stored. If omitted, the default
location will be used.
--changesid
15
Command-Line Reference
Change the Windows security identifier (SID) of a Windows-based virtual machine template. It
requires Parallels Tools to be installed in the template. If omitted, the original SID will be used.
Syntax 2
Syntax 3
--no-hdd
Create a virtual machine without hard disk drives.
--lion-recovery
Create a virtual machine from the Lion OS host recovery partition.
16
Command-Line Reference
Optional parameters
--uuid <UUID>
If included, the specified UUID will be assigned to the virtual machine. A UUID can be generated
using console utilities like uuidgen(1)in macOS. If this option is not included, the original
UUID will be used.
--regenerate-src-uuid
If included, the virtual machine source ID will be automatically generated (the SMBIOS product
ID will be changed as well).
--force
If included, all validation checks will be skipped.
Remarks
Use the register command when you have a virtual machine on the host that doesn't show up in
the list of the virtual machines registered with Parallels Desktop. This can be a machine that was
previously removed from Parallels Desktop or a machine that was manually copied from another
location.
Note that after a VM is registered, all VM restrictions on the filesystem are removed. If you would
like to protect the VM from editing, you should restrict registering or removing the VM in Parallels
Desktop preferences.
The unregister command removes a virtual machine from Parallels Desktop but does not delete it
from the host. You can re-register such a machine with Parallels Desktop later using the register
command.
Optional parameters
--template
17
Command-Line Reference
--dst
Set the path to the directory where the virtual machine files will be stored. If omitted, the default
location will be used.
--changesid
Change the current Windows security identifier (SID) of a Windows-based virtual machine
template. It requires Parallels Tools to be installed in the virtual machine template.
--regenerate-src-uuid
Regenerate the virtual machine source ID (the SMBIOS product ID will also be changed).
--linked
Create a linked clone.
Optional parameters
--dst <path>
A path where the converted virtual machine files will be stored. If omitted, the default virtual
machine location will be used.
--force
If included, the virtual machine conversion will continue even if the guest OS cannot be
identified.
18
Command-Line Reference
Notes
• Microsoft Hyper-V
• Microsoft Virtual PC
• Virtual Box
• VMware
Optional parameters
--password <password>
The user password.
19
Command-Line Reference
Executes a command inside a virtual machine. Parallels Tools must be installed in the virtual
machine. Commands in Linux guests are invoked with bash -c.
Optional parameters
--password <password>
The user password
-r, --resolve-paths
Enable converting host paths to guest.
Power Operations
prlctl start <vm_id | vm_name>
Starts the specified virtual machine. The start command can be used to start a stopped virtual
machine or to resume a paused virtual machine.
20
Command-Line Reference
Changes the encryption password for the specified virtual machine. A user will be asked to
enter the current and the new password.
The prlctl set command is used to modify the configuration of a virtual machine and manage virtual
machine devices and shared folders. The subsequent subsections describe parameters and
options that can be used with this command to perform a variety of virtual machine configuration
management tasks.
--memsize <num>
Sets the amount of memory for the virtual machine (in megabytes).
22
Command-Line Reference
--external-boot-device <name>
Sets an external device from which to boot the virtual machine.
Video Parameters
--videosize <num>
Sets the amount of memory for the virtual machine graphic card (in megabytes).
23
Command-Line Reference
--autostart-delay <n>
Sets the delay of the virtual machine autostart on host boot to n seconds.
coherence: Coherence
fullscreen: Full screen
modality: Modality
headless: Headless
Optimization Parameters
--faster-vm <on | off>
Sets the performance mode: faster virtual machine or faster host.
25
Command-Line Reference
Sharing Parameters
--smart-mount <on | off>
Enables or disables shared volumes.
Coherence Parameters
--winsystray-in-macmenu <on | off>
Shows Windows notification area in the Mac menu bar.
Security Parameters
--require-pwd <exit-fullscreen | change-vm-state | manage-snapshots | change-guest-
pwd>:<on | off>
Require an administrator password to perform a corresponding action.
27
Command-Line Reference
--sg-interval <seconds>
Sets a time interval between taking snapshots.
--sg-max-snapshots <num>
Sets the maximum allowed number of snapshots.
--host-admin <name>
Specifies the host administrator name if an administrator password is required to unlock editing
of the virtual machine configuration.
--password-to-edit
This parameter is not used since Parallels Desktop 15. In previous versions, it was used to set a
custom password to modify the virtual machine configuration. In Parallels Desktop 15 and
newer, use the --require-custom-pwd and --custom-pwd commands (described in the
beginning of this section).
Device Management
The following options can be used with the prlctl set command to manage devices:
Common Options
The options described here are common for all types of devices.
--device-connect <device_name>
Connects the specified device to a running virtual machine. The device can be of type fdd,
cdrom, sound, or net. To obtain a device name, use the prlctl list -i command.
--device-disconnect <device_name>
Disconnects the specified device from a running virtual machine.
29
Command-Line Reference
If --detach-only is specified and the device is a virtual hard disk drive, the disk image is
preserved.
If --destroy-image is specified, the virtual HDD image is removed from the server.
If --destroy-image-force is specified, the virtual HDD image is removed from all snapshots and
from the server.
The default action on deleting a virtual HDD is to detach the HDD image as if --detach-only
was specified.
prlctl set <vm_id | vm_name> --device-add <hdd | cdrom | net | fdd | serial | parallel | sound |
usb> [device_options]
To modify a device:
The subsequent sections describe options and parameters for each device type.
--device-add hdd [--image <image_name>] [--type <expand | plain>] [--size <n>] [--split]
30
Command-Line Reference
Parameters
hdd_name: The name of the virtual hard disk to modify (--device-set command only). Virtual hard
disks are named using the hddN format where N is the drive index number starting from 0 (e.g.
hdd0, hdd1). To obtain the list of disk names, use the prlctl list --info command.
--image: specifies the name of the file to be used for emulating the VM virtual disk drive. If this
option is omitted, a new file is created inside the directory storing all VM-related configuration files
and assigned the name of harddiskN.hdd.
--type: specifies the type of the virtual disk from one of the following:
• expand (default): virtual disks of this type are small initially and grow in size as you add data to
it.
• plain: virtual disks of this type have a fixed size from the moment of their creation.
--position: the SCSI / IDE / SATA device identifier to be used for the disk drive. Allowed ranges:
--device-add hdd --device <real_name> [--iface <ide | scsi | sata>] [--passthr <yes | no>]
Parameters
--device: the name of the host computer hard disk that will be connected to the virtual machine.
To obtain the names of all hard disks installed on the host, use the prlsrvctl info command.
--position: the SCSI / IDE / SATA device identifier to be used for the disk drive. Allowed ranges:
--device-add cdrom [--image <name>] [--iface <ide | scsi | sata>] [--position <n>]
Parameters
drive_name: The name of the optical drive to modify (--device-set command only). To obtain the
list of the available drives, use the prlctl list --info command.
--image: connect the specified image file to the virtual machine. The following image file formats
are supported: iso, cue, ccd, dmg.
--position: the SCSI / IDE / SATA device identifier to be used for the optical drive. Allowed ranges:
32
Command-Line Reference
--device-add cdrom --device <name> [--iface <ide | scsi | sata>] [--passthr <yes | no>]
Parameters
--device: the name of the host computer CD/DVD drive that will be connected to the virtual
machine. To obtain the names of all CD/DVD drives installed on the host, use the prlsrvctl info
command.
--position: the SCSI / IDE / SATA device identifier to be used for the CD/DVD drive. Allowed
ranges:
Add an FDD
The command adds a virtual floppy disk drive based on a file image.
Modify an FDD
Parameters
fdd_name: The name of the FDD to modify. To obtain the list of the available drives, use the
prlctl list --info command.
Parameters
--device-add net --type <shared | bridged | host-only> [--iface <name>] [--mac <addr | auto>]
[--ipadd <addr [/mask]> | --ipdel <addr[/mask]> | --dhcp <yes | no> | --dhcp6 <yes | no>]
[--ipadd <addr [/mask]> | --ipdel <addr[/mask]> | --dhcp <yes | no> | --dhcp6 <yes | no>]
Parameters
adapter_name: the name of the virtual network adapter to modify (--device-set command only). To
obtain the list of the available adapters, use the prlctl list --info command.
34
Command-Line Reference
--type: the type of the network adapter to create in the virtual machine.
--iface: the host network interface to be assigned to the bridged or host-only virtual network
adapter.
--mac: the MAC address to be assigned to the virtual network adapter. If omitted, the MAC
address will be automatically generated.
--ipadd: the IP address to be assigned to the network adapter in the virtual machine.
--ipdel: the IP address to be removed from the network adapter in the virtual machine.
--dhcp: specifies whether the virtual network adapter should get its IP settings through a DHCP
server.
--dhcp6: specifies whether the virtual network adapter should get its IPv6 settings through a DHCP
server.
--configure: if set to yes, the settings above are applied to the virtual network adapter instead of
its original settings. Configuring any of the settings automatically sets this option to yes.
--apply-iponly: if set to yes, the hostname, nameserver, and search domain settings from the
virtual machine configuration file are ignored.
[--socket-mode <server|client>]}
[--socket-mode <server|client>]}
35
Command-Line Reference
Parameters
port_name: the name of the port to modify (--device-set command only). To obtain the list of the
available ports, use the prlctl list --info command.
--device: the number of the host computer serial port that will be used by the virtual machine.
--output: the path to the file where the output of the virtual serial port will be sent.
--socket: the name of the host computer socket to which the serial port will be connected.
Parameters
port_name: the name of the port to modify (--device-set command only). To obtain the list of the
available ports, use the prlctl list --info command.
--device: the parallels port number on the host computer that will be used by the virtual machine.
--output: the path to the file where the output of the virtual parallel port will be sent.
Parameters:
--ouput: the name of a physical output device to which to connect the virtual sound card.
36
Command-Line Reference
--input: the name of the physical input device to which to connect the virtual sound card.
The command adds USB support to a virtual machine and makes the USB & Bluetooth
configuration options available.
--device-add usb
Shared Folders
A shared folder is a host OS folder that can be accessed from a virtual machine.
[--enable | --disable]
Shares the host OS folder name with a virtual machine.
--shf-host-del <name>
Removes the specified folder from the list of shared folders.
[--enable | --disable]
Modifies the settings of the host OS shared folder name.
37
Command-Line Reference
Advanced
--time-sync <on | off>
Enables or disables the virtual machine time synchronization.
38
Command-Line Reference
--rename-ext-disks
Renames external virtual hard disks bundles using the virtual machine name.
Miscellaneous
--name <name>
Changes the virtual machine name.
--description <desc>
Sets the virtual machine description.
--asset-id <id>
Changes the virtual machine asset ID.
Snapshot Management
This section describes command used to manage virtual machine snapshots.
39
Command-Line Reference
Optional parameters
Delete a Snapshot
prlctl snapshot-delete <vm_id | vm_name> -i, --id <snapid>
Deletes a virtual machine snapshot. The -i, --id <snapid> parameter specifies the ID of the
snapshot to delete.
Optional parameters
-c, --children
If included, all child snapshots of the specified snapshot will be deleted.
List Snapshots
prlctl snapshot-list <vm_id | vm_name> [{-t,--tree] | [-i,--id <snapid>}] [-j, json]
Lists the virtual machine snapshot tree. There are three modes of snapshot listing:
• If the -t, --tree option is specified, the tree is displayed using ASCII graphics.
• If the -i, --id <snapid> option is specified, the specified snapshot information is displayed.
• If no option is specified, the snapshot tree is displayed as a table with two columns:
PARENT_SNAPSHOT_ID, SNAPSHOT_ID.
Revert to a Snapshot
prlctl snapshot-switch <vm_id | vm_name> -i, --id <snapid> [--skip-resume]
Reverts the specified virtual machine to the specified snapshot. The -i, --id <snapid>
parameter specifies the ID of a snapshot to revert to.
If the optional --skip-resume parameter is included, the virtual machine will not be started if it
was running when the snapshot was taken.
40
Command-Line Reference
Miscellaneous Commands
This section describes miscellaneous prlctl commands.
<-d, --dump | -s, --send [--proxy [user [:password] @proxyhost [:port]]] [--no-proxy]>
Generates a problem report. If the -s, --send option is specified, the report is sent to Parallels.
Otherwise, it is dumped to stdout.
Parameters
-d, --dump
If included, the report is displayed on the screen. You can pipe the output to a file and then
send it to the Parallels technical support.
-s, --send
If this option is included (instead of -d, --dump), the report is sent to Parallels. You can specify
additional optional parameters, which are described below.
--proxy user:password@proxyhost:port
If you use a proxy server to connect to the Internet, include the --proxy parameter and specify
the proxy server information. The problem report will be sent to Parallels through this proxy
server.
--no-proxy
Do not use a proxy server to send the problem report. This is the default behavior, so you can
include or omit this parameter.
Optional Parameters
--name <user_name>
Inserts the specified user name into the report.
--email <user_e-mail>
Inserts the specified e-mail address into the report.
--description <problem_description>
Inserts the specified free-form description into the report.
41
Command-Line Reference
Create a VM Dump
prlctl debug-dump <vm_id | vm_name>
Optional parameters
--name <dump_file_name>
Allows you to specify a dump file name. By default, the file is named memory.elf.dmp. When
you create a new dump file, it replaces the previous file (if it exists). Giving it a custom name to a
file solves this issue.
--path <output_directory_path>]
By default, dump files are saved to the virtual machine directory. If you want to save them to
another directory, specify the directory path using the --path parameter.
Notes
To create a dump, the virtual machine must be running or paused. Suspended virtual machines are
not supported by this command. The command returns 0 (zero) on success and a non-zero value
on failure.
Syntax
42
Command-Line Reference
The prl_disk_tool compact command removes all empty blocks from expanding Parallels virtual
disks and reduces their size on your real disk. Compacting is performed by scanning file systems
for unused clusters and cleaning the corresponding disk blocks. The supported file systems are
NTFS, FAT16/32, ext2/ext3. You can also try to compact disks with unsupported file system types
using the --buildmap option.
Error Handling
The prlctl utility returns 0 on success or an error code on failure.
43
Index
Index
Sharing Parameters - 26
Shut Down Parallels Desktop - 13
Sign in to Parallels Account - 6
Snapshot Management - 39
Startup and Shutdown Parameters - 24
T
Take a Virtual Machine Snapshot - 39
U
Update a License - 7
USB and Bluetooth Parameters - 24
USB Devices - 12
Use Guest Debugger - 42
User List and Virtual Machine Location - 10
V
Video Parameters - 23
Virtual Floppy Disk Drive - 33
Virtual Hard Disk - 30
Virtual Machine Configuration Tasks - 22
Virtual Machine Disk Optimization - 42
Virtual Machine Management - 13
Virtual Network Adapter - 34
Virtual Network Info - 10
Virtual Network Settings - 10
Virtual Optical Drive - 32
Virtual Parallel Port - 36
Virtual Printer Parameters - 24
Virtual Serial Port - 35
Virtual Sound Card - 36