LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
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 02-02-2016, 06:52 AM   #1
cg132
LQ Newbie
 
Registered: Sep 2004
Distribution: Slackware
Posts: 22

Rep: Reputation: Disabled
Unhappy Virtualize this. slackware qemu, virtual-manager, madness with spice and usb-redir


Hello all. Again I find myself beating my head into a wall and feel the need to express my pain. I decided to dive into QEMU and get a virtual machine running. Everything went well at first with base qemu and libvirt. I could run a VM like so...
Code:
qemu-system-i386 -hda ~/qemu/win7.qcow
Wonderful! Now lets get that big'ole virt-manager running. After crawling through slackbuilds.org I got my hands on the following packages:
Code:
gnome-python2-gconf-2.28.1-i486-1_SBo.tgz
tunctl-1.5-i486-2_SBo.tgz
urlgrabber-3.10-i486-1_SBo.tgz
ipaddr-py-2.1.10-i486-1_SBo.tgz
celt051-0.5.1.3-i486-1_SBo.tgz
spice-protocol-0.12.7-noarch-1_SBo.tgz
pyparsing-2.0.3-i486-1_SBo.tgz
spice-0.12.5-i486-1_SBo.tgz
orc-0.4.23-i486-1_SBo.tgz
gstreamer1-1.4.5-i486-1_SBo.tgz
gst1-plugins-base-1.4.5-i486-1_SBo.tgz
vala-0.26.2-i486-1_SBo.tgz
spice-gtk-0.28-i486-1_SBo.tgz
gtk-vnc-0.5.4-i486-1_SBo.tgz
libvirt-glib-0.2.3-i486-1_SBo.tgz
pygobject3-3.10.2-i486-2_SBo.tgz
vte3-0.36.5-i486-1_SBo.tgz
libvirt-python-1.2.21-i486-1_SBo.tgz
libosinfo-0.2.11-i486-1_SBo.tgz
virt-manager-1.2.1-i486-1_SBo.tgz
So far so good. I was able to build all the necessary packages. So I fire up virt-manager and to my amazement it opened up. Could this be true! Is it really going to work?! I begin to configure a new machine and finally I see my first error.
Code:
Unable to complete install:
'unsupported configuration: spice graphics not supported with this version of QEMU'
hahaha! I knew it couldn't be that easy. So I uninstall the qemu.sbo.tgz i have, and edit qemu.SlackBuild to include --enable-spice. Reran the script, reinstalled the new sbo.gz. New error.
Code:
Unable to complete install:
'unsupported configuration: usb redirect not supported with this version of QEMU'
Another mod to the .SlackBuild script to include --enable-usb-redir. Reran the script, removed old, installed new.

Now....when I create a new machine in virt-manager it installs without error. But when the console opens up a gray screen shows nothing but
Code:
Error connecting to graphical console:
USB redirection support not compiled in
Wait didn't I just compile usb-redir into qemu? So close yet so far away. I look back to the qemu slackbuild README (yeah maybe i shoulda read that first). It tells me to run the script with LIBUSB=yes ./qemu.SlackBuild. Well I'm game. Lets try it. Remove old, install new, Same noise. Hang on maybe I'll try it without usb-redir but libusb=yes. Remove old, install new, Same noise. Eh? No matter which way I slice it I cant get around this usb-redir noise.

Anyone know what I'm doing wrong? Or does anyone have a suggestion as to which way I should go next. I'm giving up for the moment because I've been at it for hours. I'm going to drink some whiskey, play some video games, and catch a nap. I'll report back if I have any breakthroughs or bright ideas. I expect to try recompiling virt-manager at some point but my brain is nearly toast at the moment. Time for a drink.
 
Old 02-02-2016, 07:17 AM   #2
bassmadrigal
LQ Guru
 
Registered: Nov 2003
Location: West Jordan, UT, USA
Distribution: Slackware
Posts: 8,792

Rep: Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656
Looks like you might've not read that line fully...

Quote:
Slackware's libusb is too old. Thus, to enable usb redirection, install usbredir, download libusb-1.19, and build with LIBUSB=yes ./qemu.SlackBuild
NOTE: There is no libusb-1.19, but the maintainer meant 1.0.19, and it is reflected properly in the SlackBuild.

Just make sure that libusb-1.0.19 is included in the same directory as your qemu.SlackBuild and then build qemu with LIBUSB=yes ./qemu.SlackBuild. It will build a static version of libusb into qemu, which won't affect your system version. However, it looks like the script is looking for a tar.xz file, but they don't have that available to download, so I would download the tar.bz2 file and then just edit the SlackBuild accordingly.
 
Old 02-02-2016, 06:39 PM   #3
cg132
LQ Newbie
 
Registered: Sep 2004
Distribution: Slackware
Posts: 22

Original Poster
Rep: Reputation: Disabled
Slackbuild has libusb-1.0.19.tar.xz available on the qemu page under sources. Its there. Also I was paraphrasing. I've installed usbredir and tried the LIBUSB=yes ./qemu.Slackbuild but still no dice. Going to try kicking around virt-manager a little to see if maybe it needs to be manhandled after many revisions of qemu pass through while it sits idle.
 
Old 02-02-2016, 07:20 PM   #4
cg132
LQ Newbie
 
Registered: Sep 2004
Distribution: Slackware
Posts: 22

Original Poster
Rep: Reputation: Disabled
Guys.... I am sorry for wasting the minutes of your life reading this lame post. I simply changed my VMs display from spice to vnc. All is working now. I got the hint from:
http://www.linuxquestions.org/questi...-a-4175487496/
 
Old 02-24-2016, 03:16 AM   #5
cg132
LQ Newbie
 
Registered: Sep 2004
Distribution: Slackware
Posts: 22

Original Poster
Rep: Reputation: Disabled
All righty, a revisit. Sorry to bump an old thread but I decided copping out with a weak 'oh i'll settle for vnc' wasn't really solving the issue but just a work around. So I took another look today. Not only does QEMU have a usbredir option but spice-gtk does too! I couldn't believe what I was seeing when I was looking ./configure --help for spice-gtk. I simply added --enable-usbredir=yes to the spice-gtk.SlackBuild script and believe it or not spice video started working with very little reconfiguring of the VM! Don't forget to add a new spice channel and the usb redirector for spice Cheers everyone. Thanks for putting up with me bumping an old post.
 
Old 02-24-2016, 03:31 AM   #6
ponce
LQ Guru
 
Registered: Aug 2004
Location: Pisa, Italy
Distribution: Slackware
Posts: 7,102

Rep: Reputation: 4178Reputation: 4178Reputation: 4178Reputation: 4178Reputation: 4178Reputation: 4178Reputation: 4178Reputation: 4178Reputation: 4178Reputation: 4178Reputation: 4178
you don't need to enable it explicitly because it's autodetected in the SlackBuild
Code:
[...]
if pkg-config --exists libusbredirhost; then usbredir="en"; else usbredir="dis"; fi
[...]
  --${usbredir}able-usbredir \
[...]
 
Old 02-24-2016, 05:39 AM   #7
kikinovak
MLED Founder
 
Registered: Jun 2011
Location: Montpezat (South France)
Distribution: CentOS, OpenSUSE
Posts: 3,453

Rep: Reputation: 2154Reputation: 2154Reputation: 2154Reputation: 2154Reputation: 2154Reputation: 2154Reputation: 2154Reputation: 2154Reputation: 2154Reputation: 2154Reputation: 2154
I got the same problem a few days ago. In short:
  1. Build usbredir.
  2. Build qemu with LIBUSB=yes.
  3. Make sure to build spice-gtk against usbredir.

Sounds simple, but kept me busy for two sunny afternoons.

Cheers,

Niki
 
1 members found this post helpful.
Old 02-26-2016, 05:07 PM   #8
cg132
LQ Newbie
 
Registered: Sep 2004
Distribution: Slackware
Posts: 22

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by kikinovak View Post
Sounds simple, but kept me busy for two sunny afternoons.
This is exactly why I posted about it on LQ. I knew someone else had to have stumbled over this a few times. Hopefully someone can learn from our mistakes
 
Old 07-04-2016, 08:01 PM   #9
anon190
LQ Newbie
 
Registered: Mar 2011
Posts: 12

Rep: Reputation: 0
Hello all,

I just thought I'd let you know I was having this same issue and arrived here for the answer. Thanks.

V/r,
Bryan
 
  


Reply



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
LXer: Set up qemu-kvm-1.0+noroms as spice enabled qemu server vs qemu-kvm-spice on Ubuntu Precise LXer Syndicated Linux News 0 05-26-2012 07:41 AM
[SOLVED] Virtual XP guest shuts down when spice client disconnects from qemu-kvm allend Slackware 3 03-22-2012 09:34 AM
LXer: Qemu-kvm 1.0 & Spice-protocol 0.10.1 & Spice-Gtk 0.8 USB Redirection on Ubuntu Precise LXer Syndicated Linux News 0 01-19-2012 03:00 PM
LXer: Qemu-kvm 1.0 & Spice 0.10 & Spice-Gtk 0.7.159 & Libusb 1.0.9-rc3 (official) for Ubuntu Precise LXer Syndicated Linux News 0 12-27-2011 02:50 PM
LXer: Qemu-kvm 1.0 & Spice 0.10.0 & Spice-Gtk-0.7.81 USB redirection for Ubuntu Precise and Oneiric LXer Syndicated Linux News 0 11-30-2011 08:30 PM

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

All times are GMT -5. The time now is 05:32 PM.

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
Open Source Consulting | Domain Registration