4.1. add

4.1.1. add host vm

rocks add host vm {host...} {membership} [cpus=string] [disk=string] [disksize=string] [ip=string] [mac=string] [mem=string] [membership=string] [name=string] [num-macs=string] [slice=string] [subnet=string]

Add a VM specification to the database.

arguments

host

One or more physical host names.

membership

The membership to assign to the VM.

parameters

[cpus=string]

The number of CPUs to assign to this VM. The default is: 1.

[disk=string]

A disk specification for this VM. The default is: file:/<largest-partition-on-physical-node>/xen/disks/<vm-name>.hda,hda,w

[disksize=string]

The amount of disk space in gigabytes to assign to the disk specification. The default is: 36.

[ip=string]

The IP address to assign to the VM. If no IP address is provided, then one will be automatically assigned.

[mac=string]

A MAC address to assign to this VM. If no MAC address is specified, the next free MAC address will be selected.

[mem=string]

The amount of memory in megabytes to assign to this VM. The default is: 1024.

[membership=string]

Can be used in place of the membership argument.

[name=string]

The name to assign to the VM (e.g., 'compute-0-0-0').

[num-macs=string]

The number of MAC addresses to automatically assign to this VM. The default is 1.

[slice=string]

The 'slice' id on the physical node. Each VM on a physical node has a unique slice number The default is the next available free slice number.

[subnet=string]

The subnet to associate to this VM. The default is: private.

examples

# rocks add host vm

Create a default VM.

# rocks add host vm mem=4096

Create a VM and allocate 4 GB of memory to it.