Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/bin/bash
- #multifunction is on for hdmi
- #x-vga is on for displayport access
- #-device vfio-pci,host=01:00.0,multifunction=on,x-vga=on \
- #usb-host,hostbus=1,hostaddr=3 = razer
- #usb-host,hostbus=2,hostaddr=5 = usbhub_front_usb2left
- #usb-host,hostbus=2,hostaddr=6 = usbhub_front_usb2right
- #04f2:0116 chicony white keyboard
- #1532:0007 Razer mouse
- #0d8c:0102 usb itek sound
- #1131:1001 bluetooth
- #054c:0268 ps3
- #1d50:6022 lightpack
- echo "terminating prismatik, to prevent figths"
- killall prismatik
- echo "samba on"
- sudo systemctl start smbd.service
- sudo systemctl start nmbd.service
- echo "Turning off DELL monitor, switch to HDMI1"
- echo "Sound via DELL's hdmi memory will be 10GB, so only 6GB for host, close your apps"
- echo "Stealing Razer mouse"
- sudo xrandr --output DP2 --off --output HDMI1 --auto --primary
- sudo qemu-system-x86_64 \
- -enable-kvm \
- -m 10240 \
- -cpu host,kvm=off \
- -smp 4,sockets=1,cores=4,threads=1 \
- -vga none \
- -rtc base=localtime \
- -device ich9-usb-uhci3,id=uhci \
- -device usb-ehci,id=ehci \
- -device nec-usb-xhci,id=xhci \
- -device vfio-pci,host=01:00.0,x-vga=on,multifunction=on \
- -device vfio-pci,host=01:00.1 \
- -device vfio-pci,host=00:14.0 \
- -drive if=virtio,id=drive0,file=/home/pulec/vm/rawdisk/windows10.img,format=raw,cache=none,aio=native \
- -drive if=virtio,id=drive1,file=/motherstorage/KVM/data_games.img,format=raw,cache=none,aio=native \
- -usbdevice host:04f2:0116 \
- -usbdevice host:1532:0007 \
- -usbdevice host:1131:1001 \
- -usbdevice host:054c:0268 \
- -usbdevice host:1d50:6022 \
- -netdev user,id=vmnic -device virtio-net,netdev=vmnic
- #on igpu main monitor
- echo "Main monitor back on, reseting pulseaudio, restart deadbeef or web music"
- ~/scripts/two_monitors.sh
- #xrandr --output DP2 --auto --right-of HDMI1
- echo "samba off"
- sudo systemctl stop smbd.service
- sudo systemctl stop nmbd.service
Advertisement
Add Comment
Please, Sign In to add comment