Systemd 212 defaults to remove all IPC (including SYSV memory) when a user "fully" logs out.
Because the postgresql service does not count as a login, if you ssh in as postgres (I'm rsycing wal files) and then logout. Systemd removes the postgres SYSV memory bringing down postgres with fun errors like: FATAL: semop(id=92307463) failed: Invalid argument CONTEXT: xlog redo insert: rel 1663/16414/112697213; tid 1319269/129 LOG: background writer process (PID 24589) exited with exit code 1 LOG: terminating any other active server processes LOG: all server processes terminated; reinitializing LOG: semctl(119406593, 0, IPC_RMID, ...) failed: Invalid argument I was thinking the simple fix would be to add the below to postgresql.service: PAMname=systemd-login But that does not work for two reasons: 1) it does not seem to register with logind (I dont get logs about Started User Manager for UID 88, like i do when I ssh in) 2) as soon as pg_ctl exits, the session gets closed. (pg_ctl starts postgres in the background) Is there some other systemd.service knob I can turn? Or, for any machine running postgres is the recommendation to disable RemoveIPC ? Find attached the postgresql.service file.
postgresql.service
Description: Binary data
_______________________________________________ systemd-devel mailing list systemd-devel@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/systemd-devel