Lista de comandos


Force a cleanup

rnl-virt clean [-f|--force]

Use when having problems, make sure all virtual machines turned off before running.

This turns off all instances of libvirtd and of switches running and deletes the folders these use, in an attempt to solve any problems there might be.

Open virsh or virt manager (advanced usage)

rnl-virt virsh
rnl-virt manager

Opens virsh or virt-manager respectively, with the proper connection to the VM managing system.

These commands are recommended for advanced users who might want to manually edit the VMs they created.

Disks

List templates

rnl-virt disk list-templates

Create a new disk

rnl-virt disk create <name> <template> [--path <path>]

Creates a new disk, named <name>.qcow2, based on the template named <template>, in folder <path>.

If --path is omitted, the disk is created in the current folder.

Templates are stored in /var/lib/rnl-virt/disk/templates/.

Net

An alias is rnl-virt sw.

Create a new switch/hub

rnl-virt switch create <name> [--hub] [--tap]

--hub creates a hub instead of a switch.

--tap connects the switch or hub to the tap interface for communication between virtual machines in all workstations of the laboratories.

Switch sockets are stored in $XDG_RUNTIME_DIR/rnl-virt-$XDG_SESSION_ID/net/.

Management interfaces have the suffix .mgmt.

Open the management console of the switch/hub

rnl-virt switch manage <name>

Virtual machines

List existing virtual machines

rnl-virt vm list

List templates for creating virtual machines

rnl-virt vm list-templates

List ISO which can be used as CDs

rnl-virt vm list-cds

Create a virtual machine

rnl-virt vm create <name> <template> <disk> [--cdrom isofile] [--switch switch1 [switch2]] [--nat] [--tap]

--cdrom adds ISO files as CDs inside the virtual machine

--switch adds switches created with rnl-virt switch as network interfaces.

--nat adds a userspace interface which creates a NAT network to the outside.

--tap connects the virtual machine directly to the tap interface for communication between virtual machines in all workstations of the laboratories.

Templates are stored in /var/lib/rnl-virt/vm/templates/.

Remove a virtual machine

rnl-virt vm remove <name>

This does not delete the disk.

Insert a CD on the virtual machine

rnl-virt vm insert-cd <vm name> <iso>

iso can either be one of the ISOs made available or a full path to an ISO.

Eject a CD from the virtual machine

rnl-virt vm eject <vm name>

Boot an existing virtual machine

rnl-virt vm start <name>

Boots the virtual machine but does not open its screen.

Open the screen of an already running virtual machine

rnl-virt vm open <name>

Opens virt-viewer connected to the machine.

Shutdown a running virtual machine

rnl-virt vm stop <name> [-f|--force]

--force forcefully shuts down the virtual machine, such as if pressing the VMs power button for 10 seconds.

Help

List available commands

rnl-virt -h|--help

Information about disk commands

rnl-virt disk -h|--help

Information about switch commands

rnl-virt switch -h|--help

Information about virtual machine commands

rnl-virt vm -h|--help

Help about a specific command

rnl-virt <section> <command> -h|--help