LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 08-23-2018, 07:50 PM   #1
lawnm0wer
Member
 
Registered: Nov 2017
Posts: 52

Rep: Reputation: Disabled
Virt-Manager Oddities, and slackware from source builds


Hello slackers! My first problem, is that I'm trying to setup virt-manager. I recently built it and its deps through sbopkg, I checked the slackdocs page on it and set up a libvirt group for my current non-root account.

the problem is, I open it up, and get this error message

Code:
Unable to connect to libvirt.

Verify that the 'libvirtd' daemon is running.

Libvirt URI is: qemu:///system

Traceback (most recent call last):
  File "/usr/share/virt-manager/virtManager/connection.py", line 1035, in _do_open
    self._backend.open(self._do_creds_password)
  File "/usr/share/virt-manager/virtinst/connection.py", line 144, in open
    open_flags)
  File "/usr/lib64/python2.7/site-packages/libvirt.py", line 105, in openAuth
    if ret is None:raise libvirtError('virConnectOpenAuth() failed')
libvirtError: Failed to connect socket to '/var/run/libvirt/libvirt-sock': Permission denied
I don't know what I missed or what else I need to be able to get virt-manager working with my system. The main idea is to be able to have at least reasonable GPU passthrough performance and use spice with it.

For my second problem, I am installing slackware on an old laptop that I want to take with me for the sake of travel. except that the performance is not up to my standards, so I figured I'd build the kernel by hand, then I remember my attempts at gentoo, the reasons I went back to slack, and figured "why not build the other programs?"

so I downloaded the sources of 14.2.

How I would automate the process of chmodding and executing the .SlackBuild(s) of the sources? I for one don't want to do this all by hand as it would cost me more time than I'm willing to spend on it.

Last edited by lawnm0wer; 08-23-2018 at 07:51 PM. Reason: clarification
 
Old 08-23-2018, 08:38 PM   #2
mralk3
Senior Member
 
Registered: May 2015
Location: Utah, USA
Distribution: Slackware 14.2 || Slackware-current && CentOS
Posts: 1,322

Rep: Reputation: 697Reputation: 697Reputation: 697Reputation: 697Reputation: 697Reputation: 697
Did you start libvirt? Directions are on the read me here:

https://slackbuilds.org/slackbuilds/...libvirt/README

It needs to be set to start at boot.
 
Old 08-24-2018, 08:14 PM   #3
lawnm0wer
Member
 
Registered: Nov 2017
Posts: 52

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by mralk3 View Post
Did you start libvirt? Directions are on the read me here:

https://slackbuilds.org/slackbuilds/...libvirt/README

It needs to be set to start at boot.
yes I did, it turns out that not only is libvirt working, virt-manager works when I'm on root, but not on my user account. For a matter of clarification with my OP, I added the libvirt group after I installed everything. Maybe that screwed something up, or wasn't sufficient enough?

EDIT: Also, I tried making a test VM, and libvirt spat out the following:

Code:
Unable to complete install: 'unsupported configuration: this QEMU does not support 'qxl' video device'

Traceback (most recent call last):
  File "/usr/share/virt-manager/virtManager/asyncjob.py", line 89, in cb_wrapper
    callback(asyncjob, *args, **kwargs)
  File "/usr/share/virt-manager/virtManager/create.py", line 2545, in _do_async_install
    guest.start_install(meter=meter)
  File "/usr/share/virt-manager/virtinst/guest.py", line 498, in start_install
    doboot, transient)
  File "/usr/share/virt-manager/virtinst/guest.py", line 434, in _create_guest
    domain = self.conn.createXML(install_xml or final_xml, 0)
  File "/usr/lib64/python2.7/site-packages/libvirt.py", line 3659, in createXML
    if ret is None:raise libvirtError('virDomainCreateXML() failed', conn=self)
libvirtError: unsupported configuration: this QEMU does not support 'qxl' video device
at the moment, I'm going to install ovmf on my system, and poke through my bios to see if I can find anything I can do to remedy this problem. I would still like help on how to resolve libvirt not working for users.

Last edited by lawnm0wer; 08-24-2018 at 08:31 PM. Reason: libvirt experimentation
 
Old 08-25-2018, 10:46 PM   #4
mralk3
Senior Member
 
Registered: May 2015
Location: Utah, USA
Distribution: Slackware 14.2 || Slackware-current && CentOS
Posts: 1,322

Rep: Reputation: 697Reputation: 697Reputation: 697Reputation: 697Reputation: 697Reputation: 697
You need: https://slackbuilds.org/repository/1...f86-video-qxl/
and I also usually install: https://slackbuilds.org/repository/1...spice-vdagent/

You need to start it up without qxl enabled and then install qxl, power off, enable qxl, start up and qxl will work in the VM.
 
Old 09-11-2018, 08:13 PM   #5
lawnm0wer
Member
 
Registered: Nov 2017
Posts: 52

Original Poster
Rep: Reputation: Disabled
back to square two

Hoo boy...

What an adventure I've had this past few weeks with slackware.

so here's what happened. Something went really wrong in between messing with virt-manager's options while root. somehow I did something that caused my system to not be able to detect any screens, so I had to backup my data and reinstall slackware from the bare command line. Eventually I managed to not only get a Windows 7 VM working, but I managed to install the virtio drivers from redhat onto the machine for better performance... unfortunately, this did not include gaming performance; the moment I tried to start a backed up copy of xonotic, all my plans went down the toilet.

So I pulled out the extra GPU I had bought specifically as a host GPU for passthrough, and put my stronger, gaming GPU on the other bus, and tried to pass it through immediately for shiz and giggles. got an error that I don't remember, so I reinstalled slackware again to be safe.

two hours of untangling virt-manager deps later, I got my win7 VM working again. I tried to pass it through to my VM on my fresh install, and it puked out this error.

Code:
Error starting domain: internal error: qemu unexpectedly closed the monitor: 2018-09-12 04:21:55.339+0000: Domain id=1 is tainted: high-privileges
2018-09-12T04:21:55.882537Z qemu-kvm: -device vfio-pci,host=07:00.1,id=hostdev0,bus=pci.0,addr=0x9: vfio error: 0000:07:00.1: group 22 is not viable
Please ensure all devices within the iommu_group are bound to their vfio bus driver.

Traceback (most recent call last):
  File "/usr/share/virt-manager/virtManager/asyncjob.py", line 89, in cb_wrapper
    callback(asyncjob, *args, **kwargs)
  File "/usr/share/virt-manager/virtManager/asyncjob.py", line 125, in tmpcb
    callback(*args, **kwargs)
  File "/usr/share/virt-manager/virtManager/libvirtobject.py", line 82, in newfn
    ret = fn(self, *args, **kwargs)
  File "/usr/share/virt-manager/virtManager/domain.py", line 1508, in startup
    self._backend.create()
  File "/usr/lib64/python2.7/site-packages/libvirt.py", line 1080, in create
    if ret == -1: raise libvirtError ('virDomainCreate() failed', dom=self)
libvirtError: internal error: qemu unexpectedly closed the monitor: 2018-09-12 04:21:55.339+0000: Domain id=1 is tainted: high-privileges
2018-09-12T04:21:55.882537Z qemu-kvm: -device vfio-pci,host=07:00.1,id=hostdev0,bus=pci.0,addr=0x9: vfio error: 0000:07:00.1: group 22 is not viable
Please ensure all devices within the iommu_group are bound to their vfio bus driver.
at this point, I realize that I need some help and advice regarding this problem. I don't know where to start to find information, because it's either outdated or for distros that are radically different from slackware, so I have the following questions:
  • My GPU is EFI-based, I did not install OVMF on slackware, Should I install OVMF and try again?
  • Will I be able to use spice to avoid the need for a KVM-switch? if so, is it worth the effort?
  • Since spice is installed, will the windows 7 spice drivers be necessary for better machine and gaming performance?
  • I've heard about audio issues, what are common problems that people have with audio and how should I avoid them?
  • is there any reason I should install Xen over KVM/Qemu that isn't "multiple simultaneous VMs running at once"? Should I even bother?
  • what other software or dependencies should I install on my slackware-based host so I can get the most out of my gpu-passthrough experience?

My best-case-scenario goal, is something like this: http://www.youtube.com/watch?v=ssfvpLXK8po given my hardware is AMD-based, it'd be far from exact.
At the very least, I want to pass my GPU through to a windows 7 VM, and be able to game smoothly on it, while keeping all my writing and other stuff on slackware.

Machine specs for reference
  • Mobo : Asus sabertooth 990FX
  • GPUs :Sapphire RX 580
  • Sapphire HD 6450
  • CPU : AMD FX8350 4.2ghz
  • Host OS : Slackware-current (8/21/18 build)

Last edited by lawnm0wer; 09-11-2018 at 08:15 PM.
 
Old 09-12-2018, 11:16 AM   #6
ninikos
Member
 
Registered: Dec 2012
Posts: 57

Rep: Reputation: 29
I am using exact the same motherboard and processor on my main desktop and three graphics cards, two are used for passthrough: an amd 7350 graphics and an nvidia quadro fx 3800.

Even though I don't use libvirt, because I could not get the passthrough to work, I have made this little command called vms. See here

https://www.linuxquestions.org/quest...es-4175637126/

I have been using it to successfully run linuxes, windows, macos and freebsd with full 3d hardware acceleration. Have a look here for pointers about passthrough, even if you don't use vms, it might be useful

https://docs.slackware.com/howtos:em...ci-passthrough

Also, for audio on a windows guest, the best way is to buy a cheap pci sound card and pass it through to the guest, or buy a cheap usb card and pass through the host's usb controller. Windows usually have smaller buffer sizes for audio and because of this, there are clicks and pops here and there caused by buffer underruns and on top of that a lot of latency, especially when running games and videos.
 
Old 09-12-2018, 06:26 PM   #7
lawnm0wer
Member
 
Registered: Nov 2017
Posts: 52

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by ninikos View Post
I am using exact the same motherboard and processor on my main desktop and three graphics cards, two are used for passthrough: an amd 7350 graphics and an nvidia quadro fx 3800.

Even though I don't use libvirt, because I could not get the passthrough to work, I have made this little command called vms. See here

https://www.linuxquestions.org/quest...es-4175637126/

I have been using it to successfully run linuxes, windows, macos and freebsd with full 3d hardware acceleration. Have a look here for pointers about passthrough, even if you don't use vms, it might be useful

https://docs.slackware.com/howtos:em...ci-passthrough

Also, for audio on a windows guest, the best way is to buy a cheap pci sound card and pass it through to the guest, or buy a cheap usb card and pass through the host's usb controller. Windows usually have smaller buffer sizes for audio and because of this, there are clicks and pops here and there caused by buffer underruns and on top of that a lot of latency, especially when running games and videos.
MASSIVE EDIT:
Can you please make it clear that you're using alienbob's slackbuild of VDE, and not the slackbuilds.org's slackbuild? I figured this out only after searching for TigerVNC and finally understanding how you managed to get that to work, as the slackbuilds.org version of VDE refuses to compile.

other than that, I've managed to boot an iso of my windows 7 disc, so I'll continue to look through the manuals on VMS, so far it's promising!

Last edited by lawnm0wer; 09-12-2018 at 08:53 PM. Reason: everything in my post was a mess
 
Old 09-14-2018, 03:06 AM   #8
ninikos
Member
 
Registered: Dec 2012
Posts: 57

Rep: Reputation: 29
Quote:
Originally Posted by lawnm0wer View Post
MASSIVE EDIT:
Can you please make it clear that you're using alienbob's slackbuild of VDE, and not the slackbuilds.org's slackbuild? I figured this out only after searching for TigerVNC and finally understanding how you managed to get that to work, as the slackbuilds.org version of VDE refuses to compile.
I have been using the slackbuilds.org vde.SlackBuild, but I haven't tried to compile it for some time. But alienbob's SlackBuild should also work fine.

You need VDE if you want to use VDE network, I have to remove that from REQUIRES, since it's really an optional dependency.
 
Old 09-14-2018, 04:55 AM   #9
55020
Senior Member
 
Registered: Sep 2009
Location: Yorks. W.R. 167397
Distribution: Slackware
Posts: 1,307
Blog Entries: 4

Rep: Reputation: Disabled
Quote:
Originally Posted by lawnm0wer View Post
the slackbuilds.org version of VDE refuses to compile
That's something we can help you with. Are you on 14.2, or are you on -current? If you're on -current, you need to use Ponce's unofficial repo for *everything*. Ponce's repo specifically has a fix for building vde2 with openssl-1.1.x.

https://github.com/Ponce/slackbuilds...2/network/vde2
 
Old 09-20-2018, 10:11 PM   #10
lawnm0wer
Member
 
Registered: Nov 2017
Posts: 52

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by 55020 View Post
That's something we can help you with. Are you on 14.2, or are you on -current? If you're on -current, you need to use Ponce's unofficial repo for *everything*. Ponce's repo specifically has a fix for building vde2 with openssl-1.1.x.

https://github.com/Ponce/slackbuilds...2/network/vde2
yes, that was exactly the thing. Ninikos, sorry that I made such a quick assumption, I've had a few frustrating weeks with tech.

I am marking this thread as solved, since I am not using virt-manager anymore, and my other questions I have made in a different thread.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Virsh/Virt-Manager/Virt-Install broken after upgrade to Xubuntu 17.10 Zabzoo Linux - Desktop 2 02-01-2018 09:05 AM
[SOLVED] virt-manager slackbuild dependency problem slackware 14.1 multilib bmarley83 Slackware 20 11-13-2015 10:30 AM
LXer: Hacking libvirt/virsh/virt-manager/virt-install at Xen 4.0 Dom0 on top of Ubunt LXer Syndicated Linux News 0 05-06-2010 03:50 PM
LXer: Virt-install&Virt-manager at Xen 4.0-rc8 (2.6.32.10 pvops) Dom0 on top Ubuntu K LXer Syndicated Linux News 0 03-26-2010 10:41 PM
Unable to install Virtual Machine In Rhel5 with Virt-manager with CD-Rom Source prasun_mitra Linux - Enterprise 0 08-30-2007 04:03 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 03:39 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration