systemd-homed: works but login fails with "Session setup problem, abort" error

Hi all,

I’m trying to get systemd-homed working (f.e

zypper install systemd-experimental
systemctl enable systemctl enable --now systemd-homed.service
pam-config -a  --systemd_home

and manually tweaking /etc/nsswitch.conf file

passwd: compat systemd
group:  compat systemd
shadow: compat systemd

After those steps I am

  1. able to create users with
homectl create tux -G wheel --disk-size=10G --storage=luks
  1. activate the home directory with
homectl activate tux

but I can’t login as tux. Console login, gdm login and su all fail with different error messages.

I suspected PAM session initialization problem but removing / setting all required modules to optional didn’t help.

So, does anyone here have any ideas how to fix or debug this problem?


Ok, found solution after posting the question, naturally ::sarcastic:

I didn’t have nss-systemd package installed. Apparently it’s not any packages’ requirement. So after installing nss-systemd and reboot there is actually a library that implements the systemd stanzas in /etc/nsswitch.conf… Silly me.