URL: https://linuxfr.org/users/neologix/journaux/systemd-attention-a-removeipc Title: systemd: attention à RemoveIPC Authors: neologix Date: 2016年09月30日T09:19:07+02:00 License: CC By-SA Tags: troll, fud, systemd et lennart_poettering Score: 26 Un journal bookmark pour éviter des potentiels problèmes à d'autres... Suite à une mise à jour vers RHEL7, certaines de nos databases postgres ont commencé à crasher de façon aléatoire sur semop(), avec EINVAL. La raison: les semaphores utilisées par psql disparaissaient par magie. On a vite identifié le coupable : systemd, plus précisément cette option : https://lists.freedesktop.org/archives/systemd-devel/2014-April/018373.html> RemoveIPC=> Controls whether System V and POSIX IPC objects belonging to the user shall be removed when the user fully logs out. Takes a boolean argument. If enabled, the user may not consume IPC resources after the last of the user's sessions terminated. This covers System V semaphores, shared memory and message queues, as well as POSIX shared memory and message queues. Note that IPC objects of the root user and other system users are excluded from the effect of this setting. Defaults to "yes". Oui, vous avez bien lu, systemd supprime les semaphores/shared memory/message queue appartenant à un utilisateur quand il logout : donc si vous avez un process qui tourne sous un utilisateur, et par example un job cron qui tourne sous ce même utilisateur, systemd va joyeusement faire le menage (et c'est encore pire parce aue le comportement dépend selon que c'est un system user ou non). Je vous laisse lire le bug report - qui date : https://github.com/systemd/systemd/issues/2039 J'aime particulièrement cette réponse :> poettering commented on Nov 26, 2015> Well, it's configurable, because it can break stuff.> But I am pretty sure the usecase you describe is borked... The cleanup stuff already excludes system users, i.e. all daemon users. As it appears the customer created a non-system account for this stuff, and that's what should be fixed.> Sorry, but this is nothing to fix upstream... Please ask the customer to disable RemoveIPC= locally, or fix his users to become proper system users.> Sorry. RHEL et Oracle ont désactivé cette option par défaut, mais je suis abasourdi par la réponse de Poettering...