Bug 795219

Summary: virt-manager hangs with run with ibus
Product: [Fedora] Fedora Reporter: Ricky Zhou <ricky>
Component: virt-managerAssignee: Cole Robinson <crobinso>
Status: CLOSED DEFERRED QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 15CC: berrange, crobinso, dpierce, hbrock, i18n-bugs, jforbes, tagoh, tfujiwar, virt-maint
Target Milestone: ---Keywords: Reopened
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-07-07 14:05:42 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description Ricky Zhou 2012-02-20 02:42:03 UTC
When ibus is running, starting virt-manager and double-clicking a machine hangs the process.  strace shows it repeatedly sched_yield()ing.  This seems to have something to do with the interaction between dbus and virt-manager forking off a new process (so it runs fine with --no-fork).  The reason that enabling ibus seems to trigger this is that ibus tries talks to its own dbus bus, which is where it seems to hang in the strace.  The full output of strace -f python src/virt-manager.py is at http://ricky.fedorapeople.org/virt-manager.strace.out.

Moving the forking code (in virt-manager.py):

    # Now we've got basic environment up & running we can fork
    if not options.nofork and not options.debug:
        drop_tty()
        drop_stdio()

        # Ignore SIGHUP, otherwise a serial console closing drops the whole app
        signal.signal(signal.SIGHUP, signal.SIG_IGN)

anywhere above the

    config = virtManager.config.vmmConfig(appname, appversion, ui_dir)

line seems to avoid the hang.  Unfortunately I haven't gotten much further in trying to analyze this bug, as I'm not very familiar with dbus or gtk.

I've reproduced this with virt-manager-0.9.1-2.fc15.noarch as well as current code in git master on Fedora 15.

Comment 1 Cole Robinson 2012-02-28 21:10:50 UTC
How are you running ibus? I don't have an f15 instance anymore so I'm trying to reproduce on f16.

Are there any backtraces in ~/.virt-manager/virt-manager.log ?

Comment 2 Cole Robinson 2012-04-02 20:48:03 UTC
Closing as INSUFFICIENT_DATA. Ricky, if you are still seeing this, please reopen and provide the info requested in Comment #1

Comment 3 Ricky Zhou 2012-04-03 00:08:39 UTC
Sorry, completely forgot to reply to this.

It looks like ibus is run via imsettings-daemon.  I use xfce, and the way that I enabled ibus input was by selecting it in xfce4-im-chooser.  It'd be interesting to see if the issue happens in gnome.

Since this is a hanging bug, there are no interesting backtraces in ~/.virt-manager/virt-manager.log.  I have traced it down to the interaction between dbus and forking off though, as I mentioned in the description.

Comment 4 Jens Petersen 2012-06-30 04:29:22 UTC
I haven't seen any hangs in gnome fwiw.

Comment 5 Jens Petersen 2012-06-30 04:30:01 UTC
Ricky, can you reproduce on f16 or f17?

Comment 6 Cole Robinson 2012-07-07 14:05:42 UTC
F15 is dead, so if anyone can still reproduce on F17. please reopen and I'll try and reproduce.