MX19 - dmesg shows systemd-logind Failed to start user service 'user@1000.service', ignoring: Unknown unit  [Solved]

Message
Author
BitterTruth
Posts: 655
Joined: Tue Sep 22, 2020 7:36 pm

MX19 - dmesg shows systemd-logind Failed to start user service 'user@1000.service', ignoring: Unknown unit

#1 Post by BitterTruth »

IM USING MX19 and I've started seeing this in dmesg:

Code: Select all

[    9.869814] systemd-logind[1794]: Failed to start user service 'user@118.service', ignoring: Unknown unit: user@118.service
[    9.912547] cgroup: cgroup: disabling cgroup2 socket matching due to net_prio or net_cls activation
[    9.914330] systemd-logind[1794]: New session c1 of user lightdm.
AND

Code: Select all

[   15.311743] systemd-logind[1794]: Failed to start user service 'user@1000.service', ignoring: Unknown unit: user@1000.service
[   15.321566] systemd-logind[1794]: New session 1 of user MYUSER.
As I absolutely detest systemd, can anyone point me in the right direction as to where to look to see what it's trying to run? I've had a little poke around in lightdm's config file as well as logind's supposed config files but just as I expected, it's turning out to be a convoluted mess instead a single location where all the config/service files are located.

User avatar
j2mcgreg
Global Moderator
Posts: 7010
Joined: Tue Oct 23, 2007 12:04 pm

Re: MX19 - dmesg shows systemd-logind Failed to start user service 'user@1000.service', ignoring: Unknown unit

#2 Post by j2mcgreg »

QSI please.
HP 15; ryzen 3 5300U APU; 500 Gb SSD; 8GB ram
HP 17; ryzen 3 3200; 500 GB SSD; 12 GB ram
Idea Center 3; 12 gen i5; 256 GB ssd;

In Linux, newer isn't always better. The best solution is the one that works.

Stuart_M
Posts: 696
Joined: Wed Aug 07, 2019 7:10 pm

Re: MX19 - dmesg shows systemd-logind Failed to start user service 'user@1000.service', ignoring: Unknown unit  [Solved]

#3 Post by Stuart_M »

I'm guessing that you use sysVinit vice systemD since you absolutely detest systemD. My guess is that those lines are only related to using systemD so I don't see any need for concern. The output I get is essentially identical to what you posted in your Post #1 above (see below code window) and MX-19.4 is running perfectly fine.

I too am using MX-19.4 (Xfce) and use sysVinit. It continues to be as solid and stable as always. I don't know if these lines just started to appear in my case because I rarely look at the dmesg output but I suspect those lines were always present. (I suppose I could make a test installation on a spare SSD using a downloaded live MX-19.4 flash drive (ISO) I have, dated 28 May 2023, to check but I really doubt it would be of any use, much less necessary.)

Here is the output I get in my MX-19.4 Xfce running dmesg -T (I manually added the line number identifications). I compared the five lines you posted above with the below five lines and they are essentially identical.

Code: Select all

Lines 966-968:
[Thu Jul 24 07:22:42 2025] systemd-logind[2598]: Failed to start user service 'user@118.service', ignoring: Unknown unit: user@118.service
[Thu Jul 24 07:22:42 2025] cgroup: cgroup: disabling cgroup2 socket matching due to net_prio or net_cls activation
[Thu Jul 24 07:22:42 2025] systemd-logind[2598]: New session c1 of user lightdm.

Lines 972-973:
[Thu Jul 24 07:22:47 2025] systemd-logind[2598]: Failed to start user service 'user@1000.service', ignoring: Unknown unit: user@1000.service
[Thu Jul 24 07:22:47 2025] systemd-logind[2598]: New session 1 of user Felix.

BitterTruth
Posts: 655
Joined: Tue Sep 22, 2020 7:36 pm

Re: MX19 - dmesg shows systemd-logind Failed to start user service 'user@1000.service', ignoring: Unknown unit

#4 Post by BitterTruth »

@Stuart_M Sorry for the late response. I have been trying to upgrade my ethernet cabling (without success).

Thank you for taking the time to look into this issue for me. I can confirm, you have put my mind at ease. I was mostly worried that some insidious processes had managed to install themselves on my machine but since you have those messages too, it's most likely they are related to lightdm (user 118) and logind setting up the session for me (user 1000). Unfortunately, even booting up with sysv doesn't mean we are systemd free. I don't mind living with it for now.

Thank you for offering to install MX19 to an ssd but I don't think it's necessary. I suppose for completeness I should do that and see what dmesg has to say as well as see if a normal MX23 install (with systemd) has those messages but it might be a short while before I can do that and get back with the results. For now, I will mark this as solved.

The Debian wiki mentions using openrc instead of systemd for Buster and I did want to try removing it from my MX19_XFCE but then thought it better not to risk messing up my main machine.

https://wiki.debian.org/Init#Changing_t ... ation_time

Thankfully though, Bookworm supports more init systems and Dolphin_Oracle kindly put together a MX23_SysV_init_Only respin which I have running on my other machines. The respin has as much of systemd removed as possible (really easy to do) and it's really stable too so I will probablyy move over to that (or a MX25_SysV_init_only respin) when I am ready to migrate. Not yet though.

I've been putting off learning anything about systemd for a very long time now so before I made this post, curiosity got the better of me and I tried to look into the workings of it, it's supposed config files etc but when I found about 7 different locations for logind configs alone, I just gave up.

Too convoluted for me.

BitterTruth
Posts: 655
Joined: Tue Sep 22, 2020 7:36 pm

Re: MX19 - dmesg shows systemd-logind Failed to start user service 'user@1000.service', ignoring: Unknown unit

#5 Post by BitterTruth »

so after looking into this for far too long it appears this is systemd-shim doing it's thing.

apparently systemd-shim mimics some of the core systemd functionalities and interfaces, but without launching or managing the full systemd init process. it sets up fake per user instances of systemd and also intercepts Dbus communication from apps that want to talk to systemd. It passes the messages onto sysv init instead.

The reason we are seeing the message is because it is not setting up a full per user instance of systemd. It's setting up just enough to fool apps that need systemd.

Somewher along the line, you have PAM involved as well as Dbus (the more the merrier) so it basically goes something like this:

lightdm starts ---> talks to PAM ------> PAM modules start -------> systemd.logind & systemd-shim

On MX19.4 specifically then:

we also have this script which is invokingsystemd-shim:

/usr/lib/x86_64-linux-gnu/systemd-shim-invoke

I think the fake per user instance systemd files it creates are:

Code: Select all

cat /run/systemd/users/118
# This is private data. Do not parse.
NAME=lightdm
STATE=closing
STOPPING=no
RUNTIME=/run/user/118
REALTIME=1753594018345457
MONOTONIC=9769909
SESSIONS=c1
SEATS=seat0
ACTIVE_SESSIONS=
ONLINE_SESSIONS=
ACTIVE_SEATS=
ONLINE_SEATS=
AND

Code: Select all

cat /run/systemd/users/1000
# This is private data. Do not parse.
NAME=bittertruth
STATE=active
STOPPING=no
RUNTIME=/run/user/1000
DISPLAY=1
REALTIME=1753594024207118
MONOTONIC=15631570
SESSIONS=1
SEATS=seat0
ACTIVE_SESSIONS=1
ONLINE_SESSIONS=1
ACTIVE_SEATS=seat0
ONLINE_SEATS=seat0
If anyones on MX21 or higher, then you don't need to worry about all this, LOL. I think later versions started using elogind which does the job of systemd.logind and systemd-shim.

Post Reply

Return to “Older Versions”