You are not logged in.

#1 2021-02-21 08:29:51

nerdnils
Member
Registered: 2017-03-04
Posts: 23

[SOLVED] No session created after login in with sddm

Hi there,

I am logging in on tty3 over sddm to i3 on this override:

[Unit]
Description=Simple Desktop Display Manager
Documentation=man:sddm(1) man:sddm.conf(5)
Conflicts=getty@tty3.service

[Service]
Environment=DISPLAY=:1
Environment=XAUTHORITY=/root/.Xauthority
ExecStart=
ExecStart=-/usr/bin/sddm
#Restart=always

[Install]
Alias=autovt@tty3.service

No audio. When starting cmus it says "cmus: Error: an error occured while initializing MPRIS: No medium found. MPRIS will be disabled." "systemctl status --user" returns "Failed to connect to bus: $DBUS_SESSION_BUS_ADDRESS and $XDG_RUNTIME_DIR not defined"

printenv DBUS_SESSION_BUS_ADDRESS

returns nothing. No autologin used, i entered my password in sddm. No pacnew-files are in /etc/pam.d

/usr/lib/sddm/sddm.conf.d/default.conf

[Autologin]
# Whether sddm should automatically log back into sessions when they exit
Relogin=false

# Name of session file for autologin session (if empty try last logged in)
Session=

# Username for autologin session
User=


[General]
# Halt command
HaltCommand=/usr/bin/systemctl poweroff

# Input method module
InputMethod=

# Comma-separated list of Linux namespaces for user session to enter
Namespaces=

# Initial NumLock state. Can be on, off or none.
# If property is set to none, numlock won't be changed
# NOTE: Currently ignored if autologin is enabled.
Numlock=on

# Reboot command
RebootCommand=/usr/bin/systemctl reboot


[Theme]
# Current theme name
Current=

# Cursor theme used in the greeter
CursorTheme=

# Number of users to use as threshold
# above which avatars are disabled
# unless explicitly enabled with EnableAvatars
DisableAvatarsThreshold=7

# Enable display of custom user avatars
EnableAvatars=true

# Global directory for user avatars
# The files should be named <username>.face.icon
FacesDir=/usr/share/sddm/faces

# Font used in the greeter
Font=

# Theme directory path
ThemeDir=/usr/share/sddm/themes


[Users]
# Default $PATH for logged in users
DefaultPath=/usr/local/sbin:/usr/local/bin:/usr/bin

# Comma-separated list of shells.
# Users with these shells as their default won't be listed
HideShells=

# Comma-separated list of users that should not be listed
HideUsers=cab

# Maximum user id for displayed users
MaximumUid=60000

# Minimum user id for displayed users
MinimumUid=1000

# Remember the session of the last successfully logged in user
RememberLastSession=true

# Remember the last successfully logged in user
RememberLastUser=true

# When logging in as the same user twice, restore the original session, rather than create a new one
ReuseSession=true


[Wayland]
# Enable Qt's automatic high-DPI scaling
EnableHiDPI=false

# Path to a script to execute when starting the desktop session
SessionCommand=/usr/share/sddm/scripts/wayland-session

# Directory containing available Wayland sessions
SessionDir=/usr/share/wayland-sessions

# Path to the user session log file
SessionLogFile=.local/share/sddm/wayland-session.log


[X11]
# Path to a script to execute when starting the display server
DisplayCommand=/usr/share/sddm/scripts/Xsetup

# Path to a script to execute when stopping the display server
DisplayStopCommand=/usr/share/sddm/scripts/Xstop

# Enable Qt's automatic high-DPI scaling
EnableHiDPI=false

# The lowest virtual terminal number that will be used.
MinimumVT=1

# Arguments passed to the X server invocation
ServerArguments=-nolisten tcp

# Path to X server binary
ServerPath=/usr/bin/X

# Path to a script to execute when starting the desktop session
SessionCommand=/usr/share/sddm/scripts/Xsession

# Directory containing available X sessions
SessionDir=/usr/share/xsessions

# Path to the user session log file
SessionLogFile=.local/share/sddm/xorg-session.log

# Path to the Xauthority file
UserAuthFile=.Xauthority

# Path to xauth binary
XauthPath=/usr/bin/xauth

# Path to Xephyr binary
XephyrPath=/usr/bin/Xephyr

/etc/pam.d/sddm

#%PAM-1.0

auth		include		system-login
-auth		optional	pam_gnome_keyring.so
-auth   optional  pam_kwallet5.so

account		include		system-login

password	include		system-login
-password	optional	pam_gnome_keyring.so use_authtok

session		optional	pam_keyinit.so force revoke
session		include		system-login
-session		optional	pam_gnome_keyring.so auto_start
-session  optional  pam_kwallet5.so auto_start

"loginctl" shows no session for this user.
"w" shows a session for this user but on tty1 while he is actually on tty3
"pgrep -a dbus-daemon"

563 /usr/bin/dbus-daemon --system --address=systemd: --nofork --nopidfile --systemd-activation --syslog-only
674 /usr/bin/dbus-daemon --session --address=systemd: --nofork --nopidfile --systemd-activation --syslog-only

~/.xprofile does not exist
/etc/pam.d/system-auth

#%PAM-1.0

auth       required                    pam_faillock.so      preauth
# Optionally use requisite above if you do not want to prompt for the password
# on locked accounts.
auth       [success=2 default=ignore]  pam_unix.so          try_first_pass nullok
-auth      [success=1 default=ignore]  pam_systemd_home.so
auth       [default=die]               pam_faillock.so      authfail
auth       optional                    pam_permit.so
auth       required                    pam_env.so
auth       required                    pam_faillock.so      authsucc
# If you drop the above call to pam_faillock.so the lock will be done also
# on non-consecutive authentication failures.

-account   [success=1 default=ignore]  pam_systemd_home.so
account    required                    pam_unix.so
account    optional                    pam_permit.so
account    required                    pam_time.so

-password  [success=1 default=ignore]  pam_systemd_home.so
password   required                    pam_unix.so          try_first_pass nullok shadow
password   optional                    pam_permit.so

session    required                    pam_limits.so
session    required                    pam_unix.so
session    optional                    pam_permit.so

/etc/pam.d/system-login

#%PAM-1.0

auth       required   pam_shells.so
auth       requisite  pam_nologin.so
auth       include    system-auth

account    required   pam_access.so
account    required   pam_nologin.so
account    include    system-auth

password   include    system-auth

session    optional   pam_loginuid.so
session    optional   pam_keyinit.so       force revoke
session    include    system-auth
session    optional   pam_motd.so          motd=/etc/motd
session    optional   pam_mail.so          dir=/var/spool/mail standard quiet
-session   optional   pam_systemd.so
session    required   pam_env.so           user_readenv=1

/etc/pam.d/login

#%PAM-1.0

auth       required     pam_securetty.so
auth       requisite    pam_nologin.so
auth       include      system-local-login
account    include      system-local-login
session    include      system-local-login

Any idea how to get sddm to crea a session and have the DBUS-environment-variables set?


[Edit]
I also can not switch my tty anymore after login into tty3
[/Edit]

[Edit2]
Maybe it is important that i copied shadow group passwd from my old system. This is a fresh installation.
[/Edit2]

Last edited by nerdnils (2021-02-21 09:28:38)

Offline

#2 2021-02-21 09:28:20

nerdnils
Member
Registered: 2017-03-04
Posts: 23

Re: [SOLVED] No session created after login in with sddm

Normally I don't double post but I think a solution is worth it.

I just did
pacman -S dbus
and rebooted. Everything works again.

Offline

#3 2021-02-21 10:28:01

GeorgeJP
Member
From: Czech Republic
Registered: 2020-01-28
Posts: 68

Re: [SOLVED] No session created after login in with sddm

dbus is dependency for systemd. Should be already in your system

Offline

Board footer

Powered by FluxBB