[Bug 906900] PostgreSQL improper shutdown
http://bugzilla.suse.com/show_bug.cgi?id=906900 --- Comment #57 from Andrei Borzenkov <arvidjaar@gmail.com> --- (In reply to Thomas Blume from comment #56)
(In reply to Andrei Borzenkov from comment #55)
Why "su -" needs logind session in the first place? This seems to work in Arch without it; what are the real reasons to have pam_systemd for su?
According to the (OpenSUSE) manpage 'su -' is the same like 'su --login', which is the command to create a login session.
No. "su" manpage describes exactly what "su --login" does. To reiterate: Starts the shell as a login shell with an environment similar to a real login: o clears all the environment variables except TERM o initializes the environment variables HOME, SHELL, USER, LOGNAME, and PATH o changes to the target user's home directory o sets argv[0] of the shell to '-' in order to make the shell a login shell There is nothing about "creating login session".
If this is different on Arch, there seems to be a difference in the su package, not in systemd.
Yes. Arch does not have pam_systemd in su-l. And nobody explained why we need pam_systemd for su.
Anyway, here is test package for systemd that should fix it on systemd side. It sets KillMode=none for scope units started from within sysvinit scripts. Change is suprisingly small (all infrastructure was there already).
Already tried this.
Did you actually read and test my patch? May be you misunderstand - my patch does not change *service* KillMode; it changes *scope* KillMode.
Unfortunately, it doesn't help, since the processes are killed directly at session logout, not by a timeout (see comment#24).
a) by default processes are *NOT* killed on session logout. Cf. logind.conf: #KillUserProcesses=no b) The problem happens on system shutdown which calls Stop for user.scope unit. Stop will then kill all processes that are part of scope according to KillMode of *scope*. What my patch does, is to allow turning off killing on stop. -- You are receiving this mail because: You are on the CC list for the bug.
participants (1)
-
bugzilla_noreply@novell.com