Skip to content

Instantly share code, notes, and snippets.

@audebert
Created April 2, 2015 18:12
Show Gist options
  • Save audebert/e67da29eab37fd000b5d to your computer and use it in GitHub Desktop.
Save audebert/e67da29eab37fd000b5d to your computer and use it in GitHub Desktop.
prologin libvirt
sudo ip link add prolo-lan type bridge
sudo ip link add prolo-upstream type bridge
sudo ip link set eno1 master prolo-upstream
virt-install --connect qemu:///system \
--name gw.prolo \
--memory 1024 \
--vcpus=2,maxvcpus=4 \
--cpu host \
--cdrom /sgoinfre/isos/archlinux-2015.03.01-dual.iso \
--disk size=40 \
--disk size=40 \
--network bridge=prolo-upstream \
--network bridge=prolo-lan \
--virt-type kvm \
--os-variant centos7.0
virt-install --connect qemu:///system \
--name pas-r00p00.prolo \
--memory 1024 \
--vcpus=2,maxvcpus=4 \
--cpu host \
--nodisks \
--network bridge=prolo-lan \
--pxe \
--virt-type kvm \
--os-variant centos7.0
VIRSH="virsh -c qemu:///system"
RHFS=01
$VIRSH vol-delete /var/lib/libvirt/images/rhfs${RHFS}.prolo.qcow2
$VIRSH vol-delete /var/lib/libvirt/images/rhfs${RHFS}.prolo-1.qcow2
$VIRSH vol-create-as default rhfs${RHFS}.prolo.qcow2 40G --format qcow2
$VIRSH vol-create-as default rhfs${RHFS}.prolo-1.qcow2 40G --format qcow2
set -e
virt-install --connect qemu:///system \
--name rhfs45.prolo \
--memory 2048 \
--vcpus=2,maxvcpus=4 \
--cpu host \
--disk size=40 \
--disk size=40 \
--network bridge=prolo-lan \
--network bridge=prolo-lan \
--pxe \
--virt-type kvm \
--os-variant centos7.0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment