6.4. Creating Guests with PXE
6.4. Creating Guests with PXE This section provides information on creating guests with PXE. Requirements PXE guest installation requires a PXE server running on the same subnet as the guest virtual machines you wish to install. The method of accomplishing this depends on how the virtual machines are connected to the network. Contact Support if you require assistance setting up a PXE server. PXE Installation with virt-install virt-install PXE installations require both the --network=bridge:installation parameter, where installation is the name of your bridge, and the --pxe parameter. By default, if no network is found, the guest virtual machine attempts to boot from alternative bootable devices. If there is no other bootable device found, the guest pauses. You can use the qemu-kvm boot parameter reboot-timeout to allow the guest to retry booting if no bootable device is found, like so: Example 6.2. Fully-virtualized PXE installation with virt-install Note that the command above cannot be executed in a text-only environment. A fully-virtualized ( --hvm ) guest can only be installed in a text-only environment if the --location and --extra-args "console= console_type " are provided instead of the --graphics spice parameter. Procedure 6.2. PXE installation with virt-manager Select PXE Select PXE as the installation method and follow the rest of the steps to configure the OS type, memory, CPU and storage settings. Figure 6.8. Selecting the installation method Figure 6.9. Selecting the installation type Figure 6.10. Specifying virtualized hardware details Figure 6.11. Specifying storage details Start the installation The installation is ready to start. Figure 6.12. Finalizing virtual machine details A DHCP request is sent and if a valid PXE server is found the guest virtual machine's installation processes will start. After the installation completes, you can connect to the guest operating system. For more information, see Section 6.5, "Connecting to Virtual Machines"
qemu-kvm -boot reboot-timeout=1000 virt-install --hvm --connect qemu:///system --network=bridge:installation --pxe --graphics spice --name rhel6-machine --ram=756 --vcpus=4 --os-type=linux --os-variant=rhel6 --disk path=/var/lib/libvirt/images/rhel6-machine.img,size=10