Discussion:
Bug#1085934: lightdm: No background displayed when user-background = true
Add Reply
swingrock
2024-10-23 12:40:01 UTC
Reply
Permalink
Package: lightdm
Version: 1.26.0-8
Severity: normal
Tags: patch newcomer
X-Debbugs-Cc: ***@hotmail.fr

Dear Maintainer,

*** Reporter, please consider answering these questions, where appropriate ***

* What led up to the situation?
I use debian Bookworm,
I added :
user-background = true
to /etc/lightdm/lightdm-gtk-greeter.conf


* What exactly did you do (or not do) that was effective (or
ineffective)?

* What was the outcome of this action?
No user background displayed on login screen

* What outcome did you expect instead?
I expect the user background to be displayed on the login screen

* Walkaround
after further analysis, lightdm failed to display the background because org.gnome.settings-daemon.plugins.background doesn't exist
So i install gdm3 but i keep lightdm as my dm.
and it works but cause so trouble in xfce because of many package such as keyboard settings and so on were also installed as a part of gdm3 !!

* Excpected solution
It would be nice that the lightdm package contain all nessessary dependencies in order to have its features working fine.



*** End of the template - remove these template lines ***


-- System Information:
Debian Release: 12.7
APT prefers stable-updates
APT policy: (500, 'stable-updates'), (500, 'stable-security'), (500, 'stable'), (100, 'bookworm-fasttrack'), (100, 'bookworm-backports-staging')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 6.1.0-26-amd64 (SMP w/4 CPU threads; PREEMPT)
Kernel taint flags: TAINT_OOT_MODULE, TAINT_UNSIGNED_MODULE
Locale: LANG=fr_FR.UTF-8, LC_CTYPE=fr_FR.UTF-8 (charmap=UTF-8), LANGUAGE not set
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled

Versions of packages lightdm depends on:
ii adduser 3.134
ii dbus 1.14.10-1~deb12u1
ii debconf [debconf-2.0] 1.5.82
ii libaudit1 1:3.0.9-1
ii libc6 2.36-9+deb12u8
ii libgcrypt20 1.10.1-3
ii libglib2.0-0 2.74.6-2+deb12u3
ii libpam-systemd [logind] 252.30-1~deb12u2
ii libpam0g 1.5.2-6+deb12u1
ii libxcb1 1.15-1
ii libxdmcp6 1:1.1.2-3
ii lightdm-gtk-greeter [lightdm-greeter] 2.0.8-2+b1
ii sysvinit-utils [lsb-base] 3.06-4

Versions of packages lightdm recommends:
ii xserver-xorg 1:7.7+23

Versions of packages lightdm suggests:
ii accountsservice 22.08.8-6
ii upower 0.99.20-2
ii xserver-xephyr 2:21.1.7-3+deb12u7

-- Configuration Files:
/etc/lightdm/lightdm.conf changed:
[LightDM]
[Seat:*]
greeter-hide-users=false
greeter-allow-guest=true
greeter-setup-script=/usr/bin/numlockx on
[XDMCPServer]
[VNCServer]


-- debconf information:
* shared/default-x-display-manager: lightdm
lightdm/daemon_name: /usr/sbin/lightdm
Yves-Alexis Perez
2024-10-23 14:40:01 UTC
Reply
Permalink
  * Walkaround
after further analysis, lightdm failed to display the background because
org.gnome.settings-daemon.plugins.background doesn't exist
So i install gdm3 but i keep lightdm as my dm.
and it works but cause so trouble in xfce because of many package such as
keyboard settings and so on were also installed as a part of gdm3 !!
   * Excpected solution
It would be nice that the lightdm package contain all nessessary
dependencies in order to have its features working fine.
Hey, thank you for the bug report. I'm not sure exactly what are the
dependencies of user-background = true (which is the default) but there is no
way we would add gdm3 as a dependency to lightdm-gtk-greeter, that wouldn't
make sense at all.

Also I'm not sure I see the link with org.gnome.settings-
daemon.plugins.background but maybe some logs would help.

Regards,
- --
Yves-Alexis
Mike Gabriel
2024-10-23 21:10:01 UTC
Reply
Permalink
Hi,
Post by Yves-Alexis Perez
  * Walkaround
after further analysis, lightdm failed to display the background because
org.gnome.settings-daemon.plugins.background doesn't exist
So i install gdm3 but i keep lightdm as my dm.
and it works but cause so trouble in xfce because of many package such as
keyboard settings and so on were also installed as a part of gdm3 !!
   * Excpected solution
It would be nice that the lightdm package contain all nessessary
dependencies in order to have its features working fine.
Hey, thank you for the bug report. I'm not sure exactly what are the
dependencies of user-background = true (which is the default) but there is no
way we would add gdm3 as a dependency to lightdm-gtk-greeter, that wouldn't
make sense at all.
Also I'm not sure I see the link with org.gnome.settings-
daemon.plugins.background but maybe some logs would help.
In Lomiri Greeter and Unity Greeter the user background image code
depends on an Ubuntu-specific patch in AccountsService:

https://salsa.debian.org/freedesktop-team/accountsservice/-/blob/ubuntu/debian/patches/0011-add-background-file-support.patch

In Lomiri Greeter we added code to be able to work without that patch
on distros that don't have it.

Mike
--
DAS-NETZWERKTEAM
c\o Technik- und Ökologiezentrum Eckernförde
Mike Gabriel, Marienthaler Str. 17, 24340 Eckernförde
mobile: +49 (1520) 1976 148
landline: +49 (4351) 850 8940

GnuPG Fingerprint: 9BFB AEE8 6C0A A5FF BF22 0782 9AF4 6B30 2577 1B31
mail: ***@das-netzwerkteam.de, http://das-netzwerkteam.de
Yves-Alexis Perez
2024-10-24 19:10:01 UTC
Reply
Permalink
In Lomiri Greeter and Unity Greeter the user background image code 
https://salsa.debian.org/freedesktop-team/accountsservice/-/blob/ubuntu/debian/patches/0011-add-background-file-support.patch
In Lomiri Greeter we added code to be able to work without that patch 
on distros that don't have it.
Hey Mike,

thanks for the update but I'm not sure I get everything.

user-background=true seems the default in lightdm-gtk-greeter and relies on
the liblightdm api. I couldn't identify at first sight where does LightDM find
that user background, but maybe it actually comes from AccountService?

If so, swingrock, could you try removing gdm3 and everything else you
installed, and just install accountsservice package? And then report back.

Regards,
- --
Yves-Alexis
Mike Gabriel
2024-10-25 08:10:02 UTC
Reply
Permalink
Post by Yves-Alexis Perez
In Lomiri Greeter and Unity Greeter the user background image code 
https://salsa.debian.org/freedesktop-team/accountsservice/-/blob/ubuntu/debian/patches/0011-add-background-file-support.patch
In Lomiri Greeter we added code to be able to work without that patch 
on distros that don't have it.
Hey Mike,
thanks for the update but I'm not sure I get everything.
user-background=true seems the default in lightdm-gtk-greeter and relies on
the liblightdm api. I couldn't identify at first sight where does LightDM find
that user background, but maybe it actually comes from AccountService?
If so, swingrock, could you try removing gdm3 and everything else you
installed, and just install accountsservice package? And then report back.
I took a closer look once more. The BackgroundFile is indeed obtained
from AccountsService:

https://github.com/canonical/lightdm/blob/main/common/user-list.c#L589

However, Debian's AccountsService does not provide the BackgroundFile
attribute in org.freedesktop.Accounts like it does in Ubuntu (see
above patch URL).

That Ubuntu patch unfortunately never made it to AccountsService upstream.

Second reason why the user background image does not appear: all
desktop environments used with LightDM must update the BackgroundFile
attribute in AccountsService if the user changes their background
image. Ubuntu has/had patches for that in Ubuntu GNOME, Unity7 and
Unity8.

So, in a nutshell, without a considerable amount of effort and
cooperation from Debian's AccountsService maintainer, this bug report
should be tagged as "won't fix" for now.

Mike
--
DAS-NETZWERKTEAM
c\o Technik- und Ökologiezentrum Eckernförde
Mike Gabriel, Marienthaler Str. 17, 24340 Eckernförde
mobile: +49 (1520) 1976 148
landline: +49 (4351) 850 8940

GnuPG Fingerprint: 9BFB AEE8 6C0A A5FF BF22 0782 9AF4 6B30 2577 1B31
mail: ***@das-netzwerkteam.de, http://das-netzwerkteam.de
e***@free.fr
2024-10-25 06:20:01 UTC
Reply
Permalink
Hi,

i took the night to test it :

here it is

a. Fresh install bookworm 12.7.0
    - uncheck gnome
    - check xfce
    - no root passwd
    - only 1st account
b. Change in .*conf files
    - /etc/lightdm/lightdm.conf
        - greeter-hide-users=false
        - greeter-allow-guest=true
    - /etc/lightdm/lightdm-gtk-greeter.conf
        - user-background=true in [greeter] section
c. reboot
d. change wallpaper of 1st user.
    - use wallpaper in /usr/share/backgrounds/xfce
e. issue : Wallpaper is not displayed by lightdm
f. go to log files /var/log/lightdm
    - see files lightdm.log.1 et seat0-greeter.log.1
    - issue : WARNING : Error getting user list from
org.freedesktop.Accounts :[....]
g. solve issue : sudo apt install accountsservice
    - hint : accountsservice should be a dependencies of lightdm package.
h. reboot
i. issue : Wallpaper is not displayed by lightdm
j. go to log files /var/log/lightdm
    - see files lightdm.log.2 et seat0-greeter.log.2
    - no more warning in lightdm.log nor in seat0-greeter.log
    - issue : WARNING : Error getting user list from
org.freedesktop.Accounts :[....]
k. change wallpaper of 1st user. (new step that i've not done on my install)
    - use another from /usr/share/backgrounds/xfce
l. logout
m. Victory : the walpaper is displayed

So as a final there's only the package accountsservice which is missing
as dependencies of lightdm package

Could you please make the change.

regards,

Emmanuel
Yves-Alexis Perez
2024-10-25 08:10:02 UTC
Reply
Permalink
control: tag -1 wontfix
So, in a nutshell, without a considerable amount of effort and 
cooperation from Debian's AccountsService maintainer, this bug report 
should be tagged as "won't fix" for now.
Eh, thanks for the precision.

I guess work from both Debian maintainer and upstream.

Do you know if they are aware of the patch by the way?
- --
Yves-Alexis
Mike Gabriel
2024-10-25 08:10:02 UTC
Reply
Permalink
Control: tag -1 - wontfix

Hi Yves,
Post by Yves-Alexis Perez
control: tag -1 wontfix
So, in a nutshell, without a considerable amount of effort and 
cooperation from Debian's AccountsService maintainer, this bug report 
should be tagged as "won't fix" for now.
Eh, thanks for the precision.
I guess work from both Debian maintainer and upstream.
Do you know if they are aware of the patch by the way?
- --
Yves-Alexis
As Emmanuel tested the whole thing once more, it seems I am mistaken.
One more closer look, it seems that LightDM has changed to be more
generic and they made the BackgroundFile code (and also the keyboard
layout AccountsService attribute) usable on non-Ubuntu distros, as well:

See
https://github.com/canonical/lightdm/commit/6015bce25f241e7580c03594d846769f8236232f

So, the solution probably indeed is to add AccountsService under
Depends: or Recommends: of lightdm and done with it.

Second part is with the desktop envs then, they need to write the
background image file name into the above BackgroundFile attribute in
AccountsService, but that's not on us. Obviously, Xfce4 has that
feature (as Emmanuel's test worked under Xfce4).

Mike
--
DAS-NETZWERKTEAM
c\o Technik- und Ökologiezentrum Eckernförde
Mike Gabriel, Marienthaler Str. 17, 24340 Eckernförde
mobile: +49 (1520) 1976 148
landline: +49 (4351) 850 8940

GnuPG Fingerprint: 9BFB AEE8 6C0A A5FF BF22 0782 9AF4 6B30 2577 1B31
mail: ***@das-netzwerkteam.de, http://das-netzwerkteam.de
Yves-Alexis Perez
2024-11-04 07:50:01 UTC
Reply
Permalink
Mike said : "So, the solution probably indeed is to add AccountsService
under Depends: or Recommends: of lightdm and done with it. "
I would like AccountsService to be added under Depends. So that all
features were working fine out of the box for light-gtk-greeter.
This should be ok for gnome, unity and xfce4. Because it's build for it.
For KDE user, most of them use KDM and in case they use lightdm, they
would use lightdm-kde-greeter
"lightdm-gtk-greeter"
Hi,

thanks for the suggestion, but we won't do that. AccountsService is a nice add
to the lightdm features, but it's in no way necessary, it's not even a basic
feature. It's currently in the 'Suggests' field and I think it's just fine
that way. Adding it to Recommends would install and run it by default and I
don't think we want that at this point.

Regards,
- --
Yves-Alexis
Yves-Alexis Perez
2024-11-06 20:20:01 UTC
Reply
Permalink
This is perfectly understandable for users that are aware of what Recommands
is.
 
However, even if i know about, i do not have the reflex to look on
recommanded packages to in order to made "working" a features that is
enabled as defaut.
 
I suggest to disable it as default and add an explanation in the config file
that the feature require AccountsSetting.
Yes, that looks sensible indeed.

Regards,
- --
Yves-Alexis

Loading...