Qemu + kvm advice and help thread

A thread for helping each other and getting help setting up and optimizing qemu and kvm. Other hypervisors welcome too.
Remember we all started off in the beginning so be nice.

Attached: qemu.jpg (650x400, 36K)

I need more cores.
Please send some my way.

how is gpu passthrough? does it really have no performance difference? also i've been seeing some people complaining about casual input lag, is it bad?

Very little performance overhead. Obviously, the virtualised environment is going to have a slight overhead in terms of CPU and memory performance, which will also to some degree impact GPU performance, but it's very little compared to bare-metal.

Good
No
It is if you don't fix it

physical cores or vm cores?
Just change the thread flag. You can optimize them through cpu pinning where the vm cpus get pinned to the same real host ones so it stops bouncing around randomly. I hear this causes thins to run better.

Physical
I'm on a quad core haswell.

I used it to give my windows 7 embedded vm a 1060 and played the vive on it without noticing any performance issues

xeon phi

Attached: 416R5EVlRQL._SX425_.jpg (425x274, 15K)

I got this running
Doesn't use it anymore though

Attached: 1560240672580.png (698x466, 115K)

Amazing. Yes if not near 99%. Depends - I used to have Synergy installed for getting input working which sucked horribly, then I found out about evdev passthrough which has been flawless and has zero input lag. The only downside is that you can't manipulate any of the *-Lock keys while passed through.

anyone know how 3D performance is with an APU/integrated graphics is?

How?
This is me btw

Attached: Screen_Shot_20190508_at_10.37.07.jpg (1648x930, 167K)

Literally whatever the normal performance is without passthrough

It's good. If you want to do it make sure you purchase hardware that supports it though.

I'll tell you if you give me your # and promise to meet me for dinner

How do you guys start up your machines? I tried making systemd services, but it got confusing really fast with metadata and seemingly random bits of configuration in multiple files.

Is there anything wrong with having all your VM-s start up as root-user cron jobs with the @reboot flag? (Note: using root due to TAP networking). Or, is there a better solution?

@reboot sh /home/user/vm/create_tap_networking.sh
@reboot sh /home/user/vm/start_this_server.sh
@reboot sh /home/user/vm/start_that_server.sh

Just use virt-manager or virsh what the fuck lmao

seems pretty obvious in retrospect. nice
assuming your networking is bridged, you should probably just put eth0 (enp1s0 etc) onto a working bridge in your /etc/network/interfaces or distro-equivalent config, rather than mucking about with it on your VM start. if bridging doesn't work right in your setup, then you should just be NATing your VMs instead, and nto have another script for it IMO

Is it good idea to install gnu on laptop and windows vm in it to play games?
My laptop has nvidia, my plan is to use igpu only for host? Is it possible

Performance is good. Not quite bare metal but really close.
More than that you just need to be aware of all the subtleties when running gpu passthrough. Online games may ban you for playing in a VM, rarely some games may just not run well or crash in a VM, you may need to find a solution for audio as simply using pulse often does not give great results, BIOS updates can fuck up your setup and I've read posts about gpu driver updates causing major issues as well.
It generally works well but you just need to be aware there's some shit that you may have to deal with that wouldn't be an issue bare metal. If you're interested, unironically lurk Jow ForumsVFIO for a while and know what you'll be getting into. Also planning your setup well is important as a shit setup is not going to be any more convenient than just dual booting.

Use evdev passthrough for no input lag and use Scream IVSHMEM for good low latency sound output.
My only gripe is microphone quality sucks ass, I guess a usb solution would not be a problem though.

Why, shit just werks