Installation guide

Dell Inc.
KVM Virtualization in RHEL 6 Made Easy
8
# restorecon -R -v /vm-images
Verify that the context was changed:
# ls aZ /vm-images
drwxr-xr-x. root root system_u:object_r:virt_image_t:s0 .
dr-xr-xr-x. root root system_u:object_r:root_t:s0 ..
5. If you are going to export the directory /vm-images as a samba or NFS share, there are SELinux
Booleans that need to be set as well:
# setsebool -P virt_use_samba 1
# setsebool -P virt_use_nfs 1
3. Creating VMs
Installation of VMs using the virt-install tool is very straight-forward. This tool can run in interactive or
non-interactive mode. Let‟s use virt-install in non-interactive mode to create a RHEL 6.1 x64 VM named
vm1 with one virtual CPU, 1 GB memory and 10 GB of disk space:
# virt-install \
--network bridge:br0 \
--name vm1 \
--ram=1024 \
--vcpus=1 \
--disk path=/vm-images/vm1.img,size=10 \
--graphics none \
--location=http://my.server.com/pub/rhel6.1/install-x86_64/ \
--extra-args="console=tty0 console=ttyS0,115200"
--network bridge:br0
If you created a network bridge (as specified in Chapter I, steps 6-10) and want to use it for full
inbound and outbound connectivity, then you must specify it.
--name vm1
No big mystery here, this is the name of the VM
--ram=1024
This is the amount of memory in the VM in MBs
--vcpus=1
You guessed it, this is the number of virtual CPUs
--disk path=/vm-images/vm1.img,size=10