virt-install [options]

Create a guest machine completely from the command line. Virt-install does not require an XML image descriptor file. virt-install will prompt for any required information not provided on the command line. Following is the required information.



Use KVM or KQEMU kernel acceleration if available. Recommended when the guest OS is compatible.


If an image has multiple boot descriptors, use descriptor n. The first descriptor is descriptor 0. When omitted, the one that best fits the current hypervisor is chosen.

-c path, --cdrom=path

File to use for virtual CDROM device. The file may be an ISO file, CDROM device, or a URL that refers to an ISO image to fetch.


Warn if the number of virtual CPUs for the guest exceeds the number of physical CPUs in the host system.


The hypervisor connection uri.


Allow guest to use only the given set of CPUs. A set is a comma-separated list of numbers or number ranges: e.g., 0,2 or 0–2,5,6.

-d, --debug

Print debugging information to standard output.

-f path, --file=path

Required. The path to the file, disk partition, or logical volume to use to store the new guest’s virtual disk. If the original system has multiple disks, this option should be given once per disk.

-h, --help

Print information on the command and options, then exit.

-k map, --keymap=map

Set the keymap to use for the virtual console. By default, an English keymap is used.

-l path, --location=path

Specify ...

Get Linux in a Nutshell, 6th Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.