In order to investigate this bug, I started to write down each time I
switch user and whether it works.

The time information allowed to obtain time-bounded log extracts that
focus on relevant parts using journalctl --since ... --until ... .

After 3 "work" and one "fail" case, I observed a correlation, which
might or might not be relevant.

## Logs when no bug, things work

The following log sequence happens all 3 times things work okay:

2018-07-24T13:00:38.327651+0200 n551jk systemd[16387]: Startup finished in 26ms.
2018-07-24T13:00:38.327693+0200 n551jk systemd[1]: Started User Manager for UID 
110.
2018-07-24T13:00:38.360247+0200 n551jk systemd[16387]: Started D-Bus User 
Message Bus.
2018-07-24T13:00:38.363237+0200 n551jk dbus-daemon[16407]: [session uid=110 
pid=16407] AppArmor D-Bus mediation is enabled
2018-07-24T13:00:38.363739+0200 n551jk dbus-daemon[16407]: [session uid=110 
pid=16407] Activating via systemd: service name='org.a11y.Bus' 
unit='at-spi-dbus-bus.service' requested by ':1.1' (uid=110 pid=16405 
comm="/usr/sbin/lightdm-gtk-greeter " label="unconfined")
2018-07-24T13:00:38.364556+0200 n551jk systemd[16387]: Starting Accessibility 
services bus...
2018-07-24T13:00:38.368461+0200 n551jk dbus-daemon[16407]: [session uid=110 
pid=16407] Successfully activated service 'org.a11y.Bus'
2018-07-24T13:00:38.368546+0200 n551jk systemd[16387]: Started Accessibility 
services bus.
2018-07-24T13:00:38.371337+0200 n551jk at-spi-bus-launcher[16408]: 
dbus-daemon[16413]: Activating service name='org.a11y.atspi.Registry' requested 
by ':1.0' (uid=110 pid=16405 comm="/usr/sbin/lightdm-gtk-greeter " 
label="unconfined")
2018-07-24T13:00:38.373982+0200 n551jk dbus-daemon[16407]: [session uid=110 
pid=16407] Activating via systemd: service name='org.gtk.vfs.Daemon' 
unit='gvfs-daemon.service' requested by ':1.3' (uid=110 pid=16405 
comm="/usr/sbin/lightdm-gtk-greeter " label="unconfined")
2018-07-24T13:00:38.374774+0200 n551jk at-spi-bus-launcher[16408]: 
dbus-daemon[16413]: Successfully activated service 'org.a11y.atspi.Registry'
2018-07-24T13:00:38.374918+0200 n551jk at-spi-bus-launcher[16408]: SpiRegistry 
daemon is running with well-known name - org.a11y.atspi.Registry
2018-07-24T13:00:38.375082+0200 n551jk systemd[16387]: Starting Virtual 
filesystem service...


## Logs when bug happens, things fail

The bug happened once since I started to write down each operation, and
it shows a difference:

2018-07-24T16:34:15.777621+0200 n551jk systemd[23296]: Startup finished in 23ms.
2018-07-24T16:34:15.777665+0200 n551jk systemd[1]: Started User Manager for UID 
110.
2018-07-24T16:34:15.820108+0200 n551jk systemd[23296]: Started D-Bus User 
Message Bus.
2018-07-24T16:34:15.822959+0200 n551jk dbus-daemon[23316]: [session uid=110 
pid=23316] AppArmor D-Bus mediation is enabled
2018-07-24T16:34:15.823499+0200 n551jk dbus-daemon[23316]: [session uid=110 
pid=23316] Activating via systemd: service name='org.a11y.Bus' 
unit='at-spi-dbus-bus.service' requested by ':1.1' (uid=110 pid=23314 
comm="/usr/sbin/lightdm-gtk-greeter " label="unconfined")
2018-07-24T16:34:15.824373+0200 n551jk systemd[23296]: Starting Accessibility 
services bus...
2018-07-24T16:34:15.828552+0200 n551jk dbus-daemon[23316]: [session uid=110 
pid=23316] Successfully activated service 'org.a11y.Bus'
2018-07-24T16:34:15.828659+0200 n551jk systemd[23296]: Started Accessibility 
services bus.
2018-07-24T16:34:15.831689+0200 n551jk at-spi-bus-launcher[23317]: 
dbus-daemon[23322]: Activating service name='org.a11y.atspi.Registry' requested 
by ':1.0' (uid=110 pid=23314 comm="/usr/sbin/lightdm-gtk-greeter " 
label="unconfined")
2018-07-24T16:34:15.835154+0200 n551jk at-spi-bus-launcher[23317]: 
dbus-daemon[23322]: Successfully activated service 'org.a11y.atspi.Registry'
2018-07-24T16:34:15.835289+0200 n551jk at-spi-bus-launcher[23317]: SpiRegistry 
daemon is running with well-known name - org.a11y.atspi.Registry
2018-07-24T16:34:15.835578+0200 n551jk dbus-daemon[23316]: [session uid=110 
pid=23316] Activating via systemd: service name='org.gtk.vfs.Daemon' 
unit='gvfs-daemon.service' requested by ':1.4' (uid=110 pid=23314 
comm="/usr/sbin/lightdm-gtk-greeter " label="unconfined")
2018-07-24T16:34:15.836417+0200 n551jk systemd[23296]: Starting Virtual 
filesystem service...

## Difference between "work" and "fail"

All 3 lines mentioning at-spi-bus-launcher come *before* : dbus-daemon
... Activating via systemd: service name='org.gtk.vfs.Daemon'.

I don't know it this is relevant at this point in time.

No other salient difference in logs.

Logs attached.


** Attachment added: "Example log when things work."
   
https://bugs.launchpad.net/ubuntu/+source/lightdm/+bug/1776475/+attachment/5167260/+files/2018y07m24d-12h42m24s_activite_je_passe_sur_session_stephane_avec_export_xdg_seat_path__org_freedesktop_displaymanager_seat0___dm_tool_switch_to_user_stephane____exit.timestamped.log.txt

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to lightdm in Ubuntu.
https://bugs.launchpad.net/bugs/1776475

Title:
  Unlocking existing session often requires several attempts.

Status in lightdm package in Ubuntu:
  New

Bug description:
  # Context

  * Computer with several X sessions opened.
  * Users switching from one opened session to another.
  * Lightdm opens new greeter, wait for typing password.
  * User types password.
  * Password is accepted.
  * System closes the current greeter (screen gets black for an instant).

  # Expected

  * User gets back to their already opened session.

  # Observed

  * System immediately opens another greeter.
  * User has to type password again.

  # Reproducible

  * Not always. At times, often, at other times, rare.

  # Additional information

  Users switch session via 
  dm-tool switch-to-user $OTHERUSER
  but I guess bug appears with other means (like menu item like "lock screen", 
etc).

  # Information requested

  lsb_release -rd

  Description:  Ubuntu 18.04 LTS
  Release:      18.04

  
  LC_ALL=C apt-cache policy lightdm

  lightdm:
    Installed: 1.26.0-0ubuntu1
    Candidate: 1.26.0-0ubuntu1
    Version table:
   *** 1.26.0-0ubuntu1 500
          500 http://fr.archive.ubuntu.com/ubuntu bionic/universe amd64 Packages
          100 /var/lib/dpkg/status

  ProblemType: Bug
  DistroRelease: Ubuntu 18.04
  Package: lightdm 1.26.0-0ubuntu1
  ProcVersionSignature: Ubuntu 4.15.0-23.25-generic 4.15.18
  Uname: Linux 4.15.0-23-generic x86_64
  ApportVersion: 2.20.9-0ubuntu7.2
  Architecture: amd64
  Date: Tue Jun 12 14:14:52 2018
  ExecutablePath: /usr/sbin/lightdm
  InstallationDate: Installed on 2018-05-25 (18 days ago)
  InstallationMedia: Xubuntu 18.04 LTS "Bionic Beaver" - Release amd64 
(20180426)
  ProcEnviron:
   LANG=fr_FR.UTF-8
   PATH=(custom, no user)
  SourcePackage: lightdm
  UpgradeStatus: No upgrade log present (probably fresh install)
  modified.conffile..etc.logrotate.d.lightdm: [modified]
  mtime.conffile..etc.logrotate.d.lightdm: 2018-05-25T06:19:22.081830

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/lightdm/+bug/1776475/+subscriptions

-- 
Mailing list: https://launchpad.net/~touch-packages
Post to     : touch-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~touch-packages
More help   : https://help.launchpad.net/ListHelp

Reply via email to