Skip to content

Instantly share code, notes, and snippets.

@justindav1s
Last active May 14, 2018 20:44
Show Gist options
  • Save justindav1s/954179d0676a548bb656ed27a16b4a2a to your computer and use it in GitHub Desktop.
Save justindav1s/954179d0676a548bb656ed27a16b4a2a to your computer and use it in GitHub Desktop.
make a vm with virt-install
#!/bin/bash
#PCI-passthrough doesn't work though ....
virt-install \
-n RHEL7.5_2 \
--description "virt-install test" \
--os-type=Linux \
--os-variant=rhel7 \
--ram=2048 \
--vcpus=2 \
--graphics none \
--disk path=/images/rhel7.img,bus=virtio,size=10 \
--location '/images/rhel-server-7.5-x86_64-dvd.iso' \
--extra-args 'console=ttyS0,115200n8 serial' \
--features kvm_hidden=on \
--network type=direct,source=enp0s31f6,model=virtio \
--debug
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment