Bug 825633 - The connection "virt-viewer $guest" will be disconnected with an error "Segmentation fault (core dumped)"
The connection "virt-viewer $guest" will be disconnected with an error "Segme...
Status: CLOSED DUPLICATE of bug 823874
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: spice-gtk (Show other bugs)
x86_64 Linux
medium Severity medium
: rc
: ---
Assigned To: Christophe Fergeau
Desktop QE
Depends On:
  Show dependency treegraph
Reported: 2012-05-28 01:52 EDT by Huming Jiang
Modified: 2012-08-06 04:35 EDT (History)
10 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2012-08-06 04:35:33 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)
virt-viewer $guest --debug --spice-debug (29.68 KB, text/plain)
2012-05-28 01:55 EDT, Huming Jiang
no flags Details

  None (edit)
Description Huming Jiang 2012-05-28 01:52:24 EDT
Description of problem:
If a spice guest has graphics password, after guest migration, The connection "virt-viewer $guest" will be disconnected with an error "Segmentation fault (core dumped)".
Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:

1.Configure migration environment

2.Add a remote-connection to virt-manager.

3.Use virt-manager to create a spice guest with graphics password. Start the guest.

4.virt-viewer $guest --debug --spice-debug

5.Right click the running guest on virt-manager, click "Migrate" and migrate it to the remote-connection.

6.After migration is finished,the output of "virt-viewer $guest --debug --spice-debug" is:
(virt-viewer:16632): GSpice-DEBUG: spice-session.c:1181 migration channels left:6 (in migration:6)
** (virt-viewer:16632): DEBUG: Dispatch handler 7 1 0xc1b1f0
** (virt-viewer:16632): DEBUG: Update timeout 0xc1ac90 1 0
** (virt-viewer:16632): DEBUG: Dispatch timeout 0xc1ac90 0x3cde7216c0 1 0xc1b040
** (virt-viewer:16632): DEBUG: Update timeout 0xc1ac90 1 -1
** (virt-viewer:16632): DEBUG: Dispatch handler 7 1 0xc1b1f0
** (virt-viewer:16632): DEBUG: Update timeout 0xc1ac90 1 0
** (virt-viewer:16632): DEBUG: Dispatch timeout 0xc1ac90 0x3cde7216c0 1 0xc1b040
** (virt-viewer:16632): DEBUG: Update timeout 0xc1ac90 1 -1
(virt-viewer:16632): GSpice-DEBUG: channel-main.c:1664 migrate end
(virt-viewer:16632): GSpice-DEBUG: spice-channel.c:2467 test cap 0 in 0x1: yes
(virt-viewer:16632): GSpice-DEBUG: channel-display.c:733 keeping exisiting primary surface, migration or reset
(virt-viewer:16632): GSpice-DEBUG: spice-session.c:1258 migrating channel id:0 type:1
Segmentation fault (core dumped)

Actual results:
See above. 

Expected results:
The connection of "virt-viewer $guest" should be connected with no error.

Additional info:
If spice guest without graphics password, the connection of "virt-viewer $guest --debug" will be still connected.
Comment 1 Huming Jiang 2012-05-28 01:55:07 EDT
Created attachment 587154 [details]
virt-viewer $guest --debug --spice-debug
Comment 3 Alex Jia 2012-05-29 02:59:21 EDT
I just check this issue, IMHO, it should be a gtk/spice relevant bug not virt-viewer due to use-after-free:

==19650== Invalid read of size 8
==19650==    at 0x3CDFC16493: spice_msg_out_new (spice-channel.c:604)
==19650==    by 0x3CDFC1469F: spice_session_migrate_end (spice-session.c:1347)
==19650==    by 0x3CDFC23EB3: migrate_delayed (channel-main.c:1654)
==19650==    by 0x3CC6238F0D: g_main_context_dispatch (gmain.c:1960)
==19650==    by 0x3CC623C937: g_main_context_iterate (gmain.c:2591)
==19650==    by 0x3CC623CD54: g_main_loop_run (gmain.c:2799)
==19650==    by 0x3CCD34C306: gtk_main (in /usr/lib64/libgtk-x11-2.0.so.0.1800.9)
==19650==    by 0x41CB34: main (virt-viewer-main.c:141)
==19650==  Address 0x18 is not stack'd, malloc'd or (recently) free'd

Virt-viewer just call gtk_main() then other work are done by subsequent function call, I guess the subsequent function hit use-after-free issue.

Comment 5 RHEL Product and Program Management 2012-07-10 02:58:29 EDT
This request was not resolved in time for the current release.
Red Hat invites you to ask your support representative to
propose this request, if still desired, for consideration in
the next release of Red Hat Enterprise Linux.
Comment 6 RHEL Product and Program Management 2012-07-10 22:01:51 EDT
This request was erroneously removed from consideration in Red Hat Enterprise Linux 6.4, which is currently under development.  This request will be evaluated for inclusion in Red Hat Enterprise Linux 6.4.
Comment 7 Christophe Fergeau 2012-08-03 10:47:13 EDT
The backtrace is similar to bug #823874 which was fixed in spice-gtk-0.11-11.el6, which version of spice-gtk had this been tested with?
Comment 8 David Blechter 2012-08-03 12:50:57 EDT
can you please provide more details on the components and their versions, including spice-gtk.
Comment 9 Geyang Kong 2012-08-06 03:02:27 EDT
The tested version of spice-gtk is spice-gtk-0.11-9.el6.x86_64. I've tried this bug with spice-gtk-0.11-11.el6.x86_64. This issues has gone with spice-gtk-0.11-11.el6
Comment 10 Christophe Fergeau 2012-08-06 04:35:33 EDT
I'll mark this bug as a duplicate of #823874 then. Thanks for the additional info!

*** This bug has been marked as a duplicate of bug 823874 ***

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