After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 752635 - Virtual Machine Can't Find Laptop Speakers or Mic
Virtual Machine Can't Find Laptop Speakers or Mic
Status: RESOLVED INVALID
Product: gnome-boxes
Classification: Applications
Component: general
3.16.x
Other Linux
: Normal normal
: --
Assigned To: GNOME Boxes maintainer(s)
GNOME Boxes maintainer(s)
Depends on:
Blocks:
 
 
Reported: 2015-07-20 16:57 UTC by Alexander Kim
Modified: 2016-09-20 08:15 UTC
See Also:
GNOME target: ---
GNOME version: 3.15/3.16


Attachments
Win7-Spice.log (36.28 KB, text/x-log)
2015-07-21 23:20 UTC, Alexander Kim
Details
ps aux | grep -i qemu (2.75 KB, text/plain)
2015-07-21 23:22 UTC, Alexander Kim
Details
Windows 7.iso profile (844 bytes, text/plain)
2015-07-22 20:26 UTC, Alexander Kim
Details

Description Alexander Kim 2015-07-20 16:57:46 UTC
I'm running Fedora 22 and I installed a Windows 7 OS onto Gnome-Boxes.
The speakers and mic on my laptop aren't being detected.
Comment 1 Zeeshan Ali 2015-07-20 17:32:52 UTC
(In reply to Alexander Kim from comment #0)
> I'm running Fedora 22 and I installed a Windows 7 OS onto Gnome-Boxes.
> The speakers and mic on my laptop aren't being detected.

Yeah, i noticed that break again. IIRC this was fixed in spice-gtk.
Comment 2 Alexander Kim 2015-07-20 18:43:43 UTC
(In reply to Zeeshan Ali (Khattak) from comment #1)
> (In reply to Alexander Kim from comment #0)
> > I'm running Fedora 22 and I installed a Windows 7 OS onto Gnome-Boxes.
> > The speakers and mic on my laptop aren't being detected.
> 
> Yeah, i noticed that break again. IIRC this was fixed in spice-gtk.

I don't think I have spice-gtk installed.
I noticed this after finding this post:
https://bugzilla.redhat.com/show_bug.cgi?id=1220026

I tried using the update command provided:
# su -c 'yum update --enablerepo=updates-testing spice-gtk-0.28-3.fc22'

But after I did so, it said spice-gtk is not installed on this computer. Any way I can install it?
Comment 3 Zeeshan Ali 2015-07-20 19:10:14 UTC
(In reply to Alexander Kim from comment #2)
> (In reply to Zeeshan Ali (Khattak) from comment #1)
> > (In reply to Alexander Kim from comment #0)
> > > I'm running Fedora 22 and I installed a Windows 7 OS onto Gnome-Boxes.
> > > The speakers and mic on my laptop aren't being detected.
> > 
> > Yeah, i noticed that break again. IIRC this was fixed in spice-gtk.
> 
> I don't think I have spice-gtk installed.
> I noticed this after finding this post:
> https://bugzilla.redhat.com/show_bug.cgi?id=1220026
> 
> I tried using the update command provided:
> # su -c 'yum update --enablerepo=updates-testing spice-gtk-0.28-3.fc22'
> 
> But after I did so, it said spice-gtk is not installed on this computer. Any
> way I can install it?

If there was no spice-gtk on your system, "no sound" would be last of your worries. :) Boxes won't be able to start even.
Comment 4 Alexander Kim 2015-07-20 19:12:29 UTC
(In reply to Zeeshan Ali (Khattak) from comment #3)
> (In reply to Alexander Kim from comment #2)
> > (In reply to Zeeshan Ali (Khattak) from comment #1)
> > > (In reply to Alexander Kim from comment #0)
> > > > I'm running Fedora 22 and I installed a Windows 7 OS onto Gnome-Boxes.
> > > > The speakers and mic on my laptop aren't being detected.
> > > 
> > > Yeah, i noticed that break again. IIRC this was fixed in spice-gtk.
> > 
> > I don't think I have spice-gtk installed.
> > I noticed this after finding this post:
> > https://bugzilla.redhat.com/show_bug.cgi?id=1220026
> > 
> > I tried using the update command provided:
> > # su -c 'yum update --enablerepo=updates-testing spice-gtk-0.28-3.fc22'
> > 
> > But after I did so, it said spice-gtk is not installed on this computer. Any
> > way I can install it?
> 
> If there was no spice-gtk on your system, "no sound" would be last of your
> worries. :) Boxes won't be able to start even.

Oh. Well then, I am clueless as to what the cause of my issues is. :P
Comment 5 Victor Toso 2015-07-20 21:09:29 UTC
(In reply to Alexander Kim from comment #0)
> I'm running Fedora 22 and I installed a Windows 7 OS onto Gnome-Boxes.
> The speakers and mic on my laptop aren't being detected.

Thanks for reporting this problem. As Zeeshan has mentioned, we had problems prior spice-gtk3 version 28.3 on fedora 22. Could you check the version of your spice-gtk by typing: `dnf info spice-gtk3` or `yum info spice-gtk3` ?

I'm currently running spice-gtk3 on 0.29 and by using an existing image with windows 7 my audio works fine.

It would also help to see your qemu command line: `ps aux | grep -i qemu`

The log from spice could also be very helpful:
1) SPICE_DEBUG=5 gnome-boxes > win7-spice.log
2) run your VM (booting and shutdown is enough)
Comment 6 Alexander Kim 2015-07-20 21:53:57 UTC
Name        : spice-gtk3
Arch        : x86_64
Epoch       : 0
Version     : 0.29
Release     : 1.fc22
Size        : 236 k
Repo        : @System
From repo   : updates
Summary     : A GTK3 widget for SPICE clients
URL         : http://spice-space.org/page/Spice-Gtk
License     : LGPLv2+
Description : spice-client-glib-3.0 is a SPICE client library for Gtk3.

I think I have spice-gtk3 version 29.

Here is what I got after typing `ps aux | grep -i qemu`:
akim     30352  0.0  0.0 114328  2296 pts/0    S+   14:48   0:00 grep --color=auto -i qemu

Here is the log from spice. I started it up and it installed a few updates, but the issue still persists. After that I simply shut down my computer.

[akim@localhost ~]$ SPICE_DEBUG=5 gnome-boxes > win7-spice.log

(gnome-boxes:30383): GLib-GObject-WARNING **: The property GtkCellRendererPixbuf:follow-state is deprecated and shouldn't be used anymore. It will be removed in a future version.
[timestamp] [threadID] facility level [function call] <message>
--------------------------------------------------------------------------------
[60.062418] [00007717] libusb: debug [handle_events] poll() returned 0
[60.062455] [00007717] libusb: debug [libusb_handle_events_timeout_completed] doing our own event handling
[60.062458] [00007717] libusb: debug [handle_events] poll() 3 fds with timeout in 60000ms
[120.100985] [00007717] libusb: debug [handle_events] poll() returned 0
[120.101011] [00007717] libusb: debug [libusb_handle_events_timeout_completed] doing our own event handling
[120.101014] [00007717] libusb: debug [handle_events] poll() 3 fds with timeout in 60000ms
Boxes-Message: machine.vala:164: display Windows 7 Home Premium SP1 (64 Bit) disconnected
[180.156243] [00007717] libusb: debug [handle_events] poll() returned 0
[180.156266] [00007717] libusb: debug [libusb_handle_events_timeout_completed] doing our own event handling
[180.156269] [00007717] libusb: debug [handle_events] poll() 3 fds with timeout in 60000ms
Comment 7 Victor Toso 2015-07-21 06:58:32 UTC
Hey,

> It would also help to see your qemu command line: `ps aux | grep -i qemu`

You need to do the above command when you have you VM running, or else I'm not able to see your qemu command line (and all information related to devices)

> The log from spice could also be very helpful:
> 1) SPICE_DEBUG=5 gnome-boxes > win7-spice.log
> 2) run your VM (booting and shutdown is enough)

Please, do the above and attach the entire file (win7-spice.log) to the bugzilla.

Thanks
Comment 8 Alexander Kim 2015-07-21 23:20:50 UTC
Created attachment 307874 [details]
Win7-Spice.log
Comment 9 Alexander Kim 2015-07-21 23:22:56 UTC
Created attachment 307875 [details]
ps aux | grep -i qemu

This is what I got from the "ps aux | grep -i qemu" command while running the VM.
Comment 10 Victor Toso 2015-07-22 10:13:49 UTC
Thanks for the information,

As I was following closely this two bugs [0] rhbz#1176761 and [1] rhbz#1203507 I know that Windows 7 does not automatically provides audio driver for Windows 7/Vista on 64 bits. I don't know why. You could follow the comment suggestion at [2] and install the driver.

[0] https://bugzilla.redhat.com/show_bug.cgi?id=1176761
[1] https://bugzilla.redhat.com/show_bug.cgi?id=1203507
[2] https://bugzilla.redhat.com/show_bug.cgi?id=1176761#c16

I don't think this is a spice related issue as the quote below should not spice's fault

(In reply to Alexander Kim from comment #0)
> The speakers and mic on my laptop aren't being detected.

The audio device is created by QEMU and it is showed on guest after installing the right drivers.

Anyway, I think some improvement could be made on libosinfo. What do you think Zeeshan?
Comment 11 Victor Toso 2015-07-22 10:19:14 UTC
(In reply to Victor Toso from comment #10)
> Thanks for the information,
> 
> As I was following closely this two bugs [0] rhbz#1176761 and [1]
> rhbz#1203507 I know that Windows 7 does not automatically provides audio
> driver for Windows 7/Vista on 64 bits. I don't know why. You could follow
> the comment suggestion at [2] and install the driver.

I meant, for AC97 device which is the one you are using (from your qemu command line)
Comment 12 Zeeshan Ali 2015-07-22 10:59:59 UTC
(In reply to Victor Toso from comment #10)
> Thanks for the information,
> 
> As I was following closely this two bugs [0] rhbz#1176761 and [1]
> rhbz#1203507 I know that Windows 7 does not automatically provides audio
> driver for Windows 7/Vista on 64 bits. I don't know why. You could follow
> the comment suggestion at [2] and install the driver.
> 
> [0] https://bugzilla.redhat.com/show_bug.cgi?id=1176761
> [1] https://bugzilla.redhat.com/show_bug.cgi?id=1203507
> [2] https://bugzilla.redhat.com/show_bug.cgi?id=1176761#c16
> 
> I don't think this is a spice related issue as the quote below should not
> spice's fault
> 
> (In reply to Alexander Kim from comment #0)
> > The speakers and mic on my laptop aren't being detected.
> 
> The audio device is created by QEMU and it is showed on guest after
> installing the right drivers.
> 
> Anyway, I think some improvement could be made on libosinfo. What do you
> think Zeeshan?

I don't understand how this has never been the issue till now. Boxes always added AC97 device to guest and IIRC sound in windows has never been an issue. I'm pretty sure I never ever installed any drivers and I always prefer 64-bit over 32-bit.

Boxes actually only adds the device based on libosinfo claiming the OS has support for it btw.
Comment 13 Zeeshan Ali 2015-07-22 11:05:17 UTC
(In reply to Zeeshan Ali (Khattak) from comment #12)
> (In reply to Victor Toso from comment #10)
> > Thanks for the information,
> > 
> > As I was following closely this two bugs [0] rhbz#1176761 and [1]
> > rhbz#1203507 I know that Windows 7 does not automatically provides audio
> > driver for Windows 7/Vista on 64 bits. I don't know why. You could follow
> > the comment suggestion at [2] and install the driver.
> > 
> > [0] https://bugzilla.redhat.com/show_bug.cgi?id=1176761
> > [1] https://bugzilla.redhat.com/show_bug.cgi?id=1203507
> > [2] https://bugzilla.redhat.com/show_bug.cgi?id=1176761#c16

All of them are about bad quality of sound and this bug is about lack of sound (device) completely. Are you sure this is not yet another regression mainly exposed by recent FD mechanism adoption by Boxes like bug#747649.

Could you please try to reproduce?
Comment 14 Victor Toso 2015-07-22 12:25:15 UTC
(In reply to Zeeshan Ali (Khattak) from comment #13)
> (In reply to Zeeshan Ali (Khattak) from comment #12)
> > (In reply to Victor Toso from comment #10)
> > > Thanks for the information,
> > > 
> > > As I was following closely this two bugs [0] rhbz#1176761 and [1]
> > > rhbz#1203507 I know that Windows 7 does not automatically provides audio
> > > driver for Windows 7/Vista on 64 bits. I don't know why. You could follow
> > > the comment suggestion at [2] and install the driver.
> > > 
> > > [0] https://bugzilla.redhat.com/show_bug.cgi?id=1176761
> > > [1] https://bugzilla.redhat.com/show_bug.cgi?id=1203507
> > > [2] https://bugzilla.redhat.com/show_bug.cgi?id=1176761#c16
> 
> All of them are about bad quality of sound and this bug is about lack of
> sound (device) completely.

Yes, they are different bug but somewhat related to sound problems and thus I mentioned them.

> Are you sure this is not yet another regression
> mainly exposed by recent FD mechanism adoption by Boxes like bug#f.
> 
> Could you please try to reproduce?

I tried only by porting an existing image. I'll try again by installing from scratch
Comment 15 Zeeshan Ali 2015-07-22 13:37:55 UTC
(In reply to Victor Toso from comment #14)
> (In reply to Zeeshan Ali (Khattak) from comment #13)
> > Are you sure this is not yet another regression
> > mainly exposed by recent FD mechanism adoption by Boxes like bug#f.
> > 
> > Could you please try to reproduce?
> 
> I tried only by porting an existing image. I'll try again by installing from
> scratch

In Boxes? Latest in F22 should be good enough.
Comment 16 Zeeshan Ali 2015-07-22 15:21:19 UTC
Just for the record, turns out that issue on my machine was that spice-gtk 0.28 had gotten installed somehow. Audio works with both 0.29 release and also against the latest patched 0.28 spice-gtk on Fedora 22.
Comment 17 Zeeshan Ali 2015-07-22 15:23:59 UTC
And apprently it's spice-gtk 0.29 that's in Fedora 22 updates repo now.
Comment 18 Zeeshan Ali 2015-07-22 15:31:46 UTC
Alexander,

Do you happen to remember if installer was detected correctly by Boxes as Win7 installer (i-e did you get an option to 'express install' it)? If it wasn't correctly deteced, Boxes likely did not add an audio device cause it didn't have any way of knowing if OS supports AC97 or not.

It should be pretty easy to fix if that's the case. Could you please profile the output of `isoinfo -d -i ISO_PATH`?
Comment 19 Zeeshan Ali 2015-07-22 15:32:29 UTC
(In reply to Zeeshan Ali (Khattak) from comment #18) 
> It should be pretty easy to fix if that's the case. Could you please profile
> the output of `isoinfo -d -i ISO_PATH`?

profile -> provide.
Comment 20 Alexander Kim 2015-07-22 20:26:12 UTC
Created attachment 307930 [details]
Windows 7.iso profile
Comment 21 Alexander Kim 2015-07-22 20:28:36 UTC
So the text in "Windows 7.iso profile" is what happens if I type 'isoinfo -d -i *.iso' after navigating to the folder that contains the .iso.

But if I type 'isoinfo -d -i ISO_PATH` it says it can't find ISO_PATH. Here is the output:

isoinfo: No such file or directory. Cannot open 'ISO_PATH'. Cannot open SCSI driver.
isoinfo: No such file or directory. Unable to open ISO_PATH
Comment 22 Christophe Fergeau 2015-07-23 10:02:53 UTC
"ISO_PATH" was supposed to be replaced by something like /home/akim/isos/win7.iso, so what you attached is good. However, the WINDOWS_7_HOME_P_64_BIT label is very unusual for what it's worth, is this an official ISO from Microsoft?
Comment 23 Alexander Kim 2015-07-23 22:31:29 UTC
(In reply to Christophe Fergeau from comment #22)
> "ISO_PATH" was supposed to be replaced by something like
> /home/akim/isos/win7.iso, so what you attached is good. However, the
> WINDOWS_7_HOME_P_64_BIT label is very unusual for what it's worth, is this
> an official ISO from Microsoft?

Sorry, I think I should have mentioned this before. I actually got this from a torrent, but it wasn't the full-free version as I expected it to be. It's just a .iso file of the windows 7 disc with a companion program in the same folder that makes the trial version into a full version. But up to this point I haven't used the program to make it full so it's still in its trial version state. The companion program deletes a file that checks whether or not the product has been activated.
Comment 24 Alexander Kim 2015-07-23 22:39:04 UTC
It seems that this folder has a different program from the one I'm used to using.
I usually use WPAKILL but I wouldn't download it from a website unless it's packed with the torrent.
Comment 25 Victor Toso 2015-07-24 09:29:34 UTC
The problem is likely related to the audio device you are using which is AC97. You can follow the link [2] on comment #10 to install the AC97 driver from realtek website or change the audio device to intel-hda (ich6) which should be recognized directly by Windows OS.

Please confirm afterwards that this was solved so we can close this bug.
Comment 26 Zeeshan Ali 2015-07-24 11:14:22 UTC
Hmm.. looking at code more closely in Boxes, it seems I was wrong in comment#18 and issue is actually that Boxes adds AC97 by default if libosinfo doesn't report any particular audio device to be supported by the OS. The thing is that we explicitly added a non-AC97 (ICH6) device to win7 in libosinfo to avoid well-known issues of AC97 working out of the box on win7.

I don't see how we can solve this situation since we won't want to add detection for pirated software in libosinfo, mainly cause Microsoft can rightfully sue us.
Comment 27 Alexander Kim 2015-07-24 15:42:03 UTC
(In reply to Victor Toso from comment #25)
> The problem is likely related to the audio device you are using which is
> AC97. You can follow the link [2] on comment #10 to install the AC97 driver
> from realtek website or change the audio device to intel-hda (ich6) which
> should be recognized directly by Windows OS.
> 
> Please confirm afterwards that this was solved so we can close this bug.

Yo, thanks guys. It worked, downloading the AC97 drivers in the VM fixed everything. Thanks for the help, good luck on developing. :D