Compare commits
4
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
fa22cf6c0a | ||
|
|
d1a8e2c6a3 | ||
|
|
e70f12845e | ||
|
|
3dd1af49e7 |
@@ -9,5 +9,7 @@ Note the PCI ids and display manager should be detected automatically. If you ar
|
||||
|
||||
If using startx, add a line `killall -u user_name` to qemu/vfio-startup.sh script towards the beginning and you can add a line to vfio-teardown.sh to start your window manager/ desktop environment again. Don't just add startx because it will be run as root. Instead add `su -s /bin/bash -c "/usr/bin/startx" -g username username` replacing username with your username to the end of the vfio-teardown.sh script.
|
||||
|
||||
For a detailled guide on how to use these scripts, [check out the the wiki of this repo.](https://gitlab.com/risingprismtv/single-gpu-passthrough/-/wikis/home)
|
||||
|
||||
For suggestions or support, join us on Discord at: https://discord.gg/bh4maVc
|
||||
|
||||
|
||||
+2
-2
@@ -7,12 +7,12 @@ if [[ $OBJECT == "win10" ]]; then
|
||||
case "$OPERATION" in
|
||||
"prepare")
|
||||
systemctl start libvirt-nosleep@"$OBJECT" 2>&1 | tee -a /var/log/libvirt/custom_hooks.log
|
||||
/bin/vfio-startup.sh 2>&1 | tee -a /var/log/libvirt/custom_hooks.log
|
||||
/usr/local/bin/vfio-startup 2>&1 | tee -a /var/log/libvirt/custom_hooks.log
|
||||
;;
|
||||
|
||||
"release")
|
||||
systemctl stop libvirt-nosleep@"$OBJECT" 2>&1 | tee -a /var/log/libvirt/custom_hooks.log
|
||||
/bin/vfio-teardown.sh 2>&1 | tee -a /var/log/libvirt/custom_hooks.log
|
||||
/usr/local/bin/vfio-teardown 2>&1 | tee -a /var/log/libvirt/custom_hooks.log
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
|
||||
+8
-8
@@ -8,13 +8,13 @@ if test -e /etc/libvirt/hooks/qemu;
|
||||
then
|
||||
mv /etc/libvirt/hooks/qemu /etc/libvirt/hooks/qemu_last_backup
|
||||
fi
|
||||
if test -e /bin/vfio-startup.sh;
|
||||
if test -e /usr/local/bin/vfio-startup;
|
||||
then
|
||||
mv /bin/vfio-startup.sh /bin/vfio-startup.sh.bkp
|
||||
mv /usr/local/bin/vfio-startup /usr/local/bin/vfio-startup.bkp
|
||||
fi
|
||||
if test -e /bin/vfio-teardown.sh;
|
||||
if test -e /usr/local/bin/vfio-teardown;
|
||||
then
|
||||
mv /bin/vfio-teardown.sh /bin/vfio-teardown.sh.bkp
|
||||
mv /usr/local/bin/vfio-teardown /usr/local/bin/vfio-teardown.bkp
|
||||
fi
|
||||
if test -e /etc/systemd/system/libvirt-nosleep@.service;
|
||||
then
|
||||
@@ -22,10 +22,10 @@ then
|
||||
fi
|
||||
|
||||
cp systemd-no-sleep/libvirt-nosleep@.service /etc/systemd/system/libvirt-nosleep@.service
|
||||
cp hooks/vfio-startup.sh /bin/vfio-startup.sh
|
||||
cp hooks/vfio-teardown.sh /bin/vfio-teardown.sh
|
||||
cp hooks/vfio-startup /usr/local/bin/vfio-startup
|
||||
cp hooks/vfio-teardown /usr/local/bin/vfio-teardown
|
||||
cp hooks/qemu /etc/libvirt/hooks/qemu
|
||||
|
||||
chmod +x /bin/vfio-startup.sh
|
||||
chmod +x /bin/vfio-teardown.sh
|
||||
chmod +x /usr/local/bin/vfio-startup
|
||||
chmod +x /usr/local/bin/vfio-teardown
|
||||
chmod +x /etc/libvirt/hooks/qemu
|
||||
|
||||
Reference in New Issue
Block a user