RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 683736 - Asynchronous when recording sound inside kvm guest with vnc console
Summary: Asynchronous when recording sound inside kvm guest with vnc console
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: qemu-kvm
Version: 7.0
Hardware: Unspecified
OS: Unspecified
low
low
Target Milestone: rc
: 7.0
Assignee: Gerd Hoffmann
QA Contact: Virtualization Bugs
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-03-10 08:45 UTC by Shaolong Hu
Modified: 2013-10-30 09:49 UTC (History)
7 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-10-30 09:49:17 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Shaolong Hu 2011-03-10 08:45:28 UTC
Description of problem:
------------------------
Connect microphone to host, boot a guest, connect guest with vnc on the host, record sound in the guest, sound recorded in the guest has big latency.


Version-Release number of selected component (if applicable):
--------------------------------------------------------------
Host:
2.6.32-118.el6.x86_64
qemu-kvm-0.12.1.2-2.149.el6.x86_64

Guest:
2.6.32-118.el6.i686


How reproducible:
-----------------
100%


Steps to Reproduce:
--------------------
1. Boot guest with:

/usr/libexec/qemu-kvm -M rhel6.1.0 -enable-kvm -m 8G -smp 4 -name RHEL-Server-6.1-32 -uuid `uuidgen` -rtc base=utc,clock=host,driftfix=slew -no-kvm-pit-reinjection -boot order=cd -drive file=./RHEL6.1-32-qcow2,if=none,id=drive-ide-disk0,format=qcow2,cache=none,werror=stop,rerror=stop -device ide-drive,drive=drive-ide-disk0,id=ide-disk0 -netdev tap,script=/etc/qemu-ifup,id=hostnet0 -device rtl8139,netdev=hostnet0,id=net0,mac=52:54:00:7b:a2:fa -usb -device usb-tablet,id=input0 -monitor stdio -balloon none -device intel-hda,id=sound0,bus=pci.0 -device hda-duplex -vnc :10

2. Connect microphone to host, on the host:

vncviewer :10

3. Record sound in the guest with Sound Recorder.
  

Actual results:
----------------
Recorded length of step 3 is bigger than actual length, timer on Sound Recorder moves faster than real time. There is big latency of sound recorded, for you say "one, two, three", stop recording and play, there is nothing, than resume recording, say "four, five, six", stop recording and play, it plays "one, two, three". 


Expected results:
------------------
Recorded sound should has no latency, timer of Sound Recorder should move correctly.


Additional info:
-----------------
Same command line with -spice, sound recorded correctly.
With win7_32 guest, SoundRecorder's timer moves correctly with both spice and vnc, but recorded sound is noise.

Comment 3 Gerd Hoffmann 2011-06-01 16:05:52 UTC
With luck this is the same as 684149.

If not this will go pretty much to the bottom of the priority list as sound without spice is not supported.

Comment 4 Gerd Hoffmann 2011-06-08 14:31:59 UTC
which app you are using to record sound with the rhel6 guest?

Comment 5 Gerd Hoffmann 2011-06-09 12:59:42 UTC
Found it, gnome-media-apps carries the sound recorder app.

Comment 6 Gerd Hoffmann 2011-06-09 13:08:48 UTC
How does the host-side audio configuration look like?

Do you use alsa?  Or pulseaudio?
See "qemu -audio-help" for more info on audio setup.

Comment 7 FuXiangChun 2011-06-10 10:26:48 UTC
Hi Gerd
   i am trying to reproduce it with alsa and pulseaudio. i will update testing result to bz next monday.

Comment 8 FuXiangChun 2011-06-10 11:26:01 UTC
(In reply to comment #6)
> How does the host-side audio configuration look like?
> 
> Do you use alsa?  Or pulseaudio?
> See "qemu -audio-help" for more info on audio setup.


use alsa and pulseaudio all can reproduce this bug. 

host info:
# uname -r
2.6.32-156.el6.x86_64
#rpm -qa|grep kvm
qemu-kvm-0.12.1.2-2.164.el6.x86_64

guest(rhel6.1 32bit) info:
# uname -r
2.6.32-131.0.15.el6.i686

steps to reproduce
1.QEMU_AUDIO_DRV=alsa or QEMU_AUDIO_DRV=pulseaudio
2. start vm 
/usr/libexec/qemu-kvm -M rhel6.1.0 -enable-kvm -m 8G -smp 4 -name RHEL-Server-6.1-32 -uuid dc170b25-7559-4383-a691-e9f8deb45ab8 -rtc base=utc,clock=host,driftfix=slew -no-kvm-pit-reinjection -boot order=c -drive file=RHEL6.1-32-qcow2,if=none,id=drive-ide-disk0,format=qcow2,cache=none,werror=stop,rerror=stop -device ide-drive,drive=drive-ide-disk0,id=ide-disk0 -netdev tap,script=/etc/qemu-ifup,id=hostnet0 -device rtl8139,netdev=hostnet0,id=net0,mac=52:54:00:7b:a2:fa -usb -device usb-tablet,id=input0 -monitor stdio -balloon none -device intel-hda,id=sound0,bus=pci.0 -device hda-duplex -vnc :10

Comment 9 Gerd Hoffmann 2011-06-14 08:52:16 UTC
You need "export QEMU_AUDIO_DRV=..." otherwise qemu does't see it.
The pulseaudio driver is named "pa" btw.

Comment 10 Shaolong Hu 2011-07-28 08:01:05 UTC
Hi Gerd,

I am back, see this is here a long time, i tried with the latest qemu-kvm:
qemu-kvm-0.12.1.2-2.172.el6.x86_64
2.6.32-171.el6.x86_64

when i export QEMU_AUDIO_DRV=pa, i can reproduce it, when i use alsa, it keeps prompting "alsa: Unexpected state 1", guest acts slowly, especially when i use Sound Reorder.

Comment 15 Gerd Hoffmann 2013-03-20 14:41:42 UTC
Sound with vnc is unsupported, lowering priority.


Note You need to log in before you can comment on or make changes to this bug.