Opened 2 years ago

Closed 2 years ago

#12210 closed defect (fixed)

maliit-server causes slow GNOME shutdown (xsmp infinite registration loop)

Reported by: garysu Owned by: dsd
Priority: normal Milestone: 13.1.0
Component: distro Version: not specified
Keywords: Cc: tonyforster
Blocked By: Blocking:
Deployments affected: Action Needed: no action
Verified: no

Description

OS:31007o4
OFW:Q7B03
1.Login to sugar and switch to gnome.
2.To click the switch to suagr.
3.System cannot change to sugar.
4.After reboot, system changed to sugar

Change History (10)

comment:1 Changed 2 years ago by dsd

  • Component changed from not assigned to distro
  • Milestone changed from Not Triaged to 13.1.0
  • Owner set to dsd
  • Status changed from new to assigned
  • Summary changed from [CL4]Switch from gnome to sugar will fail. to [CL4]Switch from gnome to sugar takes a long time

It does change if you leave it enough time.

comment:2 Changed 2 years ago by tonyforster

After sudo yum downgrade gnome-menus-3.6.0-1.fc18 --nogpg
the problem went away

comment:3 Changed 2 years ago by tonyforster

  • Cc tonyforster added

comment:4 Changed 2 years ago by dsd

  • Summary changed from [CL4]Switch from gnome to sugar takes a long time to maliit-server causes slow GNOME shutdown (xsmp infinite registration loop)

Here's whats happening:

  1. gnome-session shuts down all of its clients, one by one, including maliit-server
  2. Something triggers maliit-server to launch again - probably dbus-activation of a message fired by the maliit GTK+ IM plugin due to a change of widget focus
  3. The new maliit-server attempts to register with gnome-session over XSMP
  4. gnome-session rejects the maliit-server connection attempt due to this code:
static gboolean
on_xsmp_client_register_request (GsmXSMPClient *client,
                                 char         **id,
                                 GsmManager    *manager)
{
        if (manager->priv->phase >= GSM_MANAGER_PHASE_QUERY_END_SESSION) {
                goto out;
        }

The last 2 steps repeat infinitely, until gnome-session hits a timeout and stops trying to handle maliit-server. While this is happening, gnome-session produces these debug messages:

gnome-session[1919]: DEBUG(+): GsmXSMPClient: Client '0x795e0 []' received RegisterClient(NULL)
gnome-session[1919]: DEBUG(+): GsmXSMPClient:   rejected: invalid previous_id

This means that the above diagnosis has probably given us a good explanation of http://bugs.sugarlabs.org/ticket/1624 as well.

The next question is why this loops infinitely instead of just failing once. The answer seems to be in libSM.

comment:5 Changed 2 years ago by dsd

libSM fix: http://lists.x.org/archives/xorg-devel/2012-November/034436.html

However, gnome-session is still being confused by a client connecting at a late stage.

comment:7 Changed 2 years ago by dsd

  • Action Needed changed from never set to add to build

Fixed in gnome-session-3.6.2-2.fc18. In the end the libSM issue is not relevant.

comment:8 Changed 2 years ago by dsd

  • Action Needed changed from add to build to test in build

Test in 13.1.0 build 12. Bert, can you provide a test case showing how etoys was affected by this breakage?

comment:9 Changed 2 years ago by greenfeld

Switching from GNOME now goes at a reasonable speed in 13.1.0 os12 for XO-1.75 and XO-4. But I do not understand how this ticket is related to etoys.

comment:10 Changed 2 years ago by greenfeld

  • Action Needed changed from test in build to no action
  • Resolution set to fixed
  • Status changed from assigned to closed

Presuming this has nothing to do with etoys; closing.

Note: See TracTickets for help on using tickets.