mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-23 06:01:15 +00:00
glusterfs service: Switch to simple unit instead of forking.
Gluster's pidfile handling is bug-ridden.
I have fixed https://bugzilla.redhat.com/show_bug.cgi?id=1509340
in an attempt to improve it but that is far from enough.
The gluster developers describe another pidfile issue as
"our brick-process management is a total nightmare", see
f1071f17e0/xlators/mgmt/glusterd/src/glusterd-utils.c (L5907-L5924)
I have observed multiple cases where glusterd doesn't start correctly
and systemd doesn't notice because of the erroneous pidfile handling.
To improve the situation, we don't let glusterd daemonize itself any more
and instead use `--no-daemon` and the `Simple` service type.
This commit is contained in:
parent
3fc7d5eb83
commit
92f40bab2b
|
@ -176,10 +176,8 @@ in
|
||||||
'';
|
'';
|
||||||
|
|
||||||
serviceConfig = {
|
serviceConfig = {
|
||||||
Type="forking";
|
|
||||||
PIDFile="/run/glusterd.pid";
|
|
||||||
LimitNOFILE=65536;
|
LimitNOFILE=65536;
|
||||||
ExecStart="${glusterfs}/sbin/glusterd -p /run/glusterd.pid --log-level=${cfg.logLevel} ${toString cfg.extraFlags}";
|
ExecStart="${glusterfs}/sbin/glusterd --no-daemon --log-level=${cfg.logLevel} ${toString cfg.extraFlags}";
|
||||||
KillMode=cfg.killMode;
|
KillMode=cfg.killMode;
|
||||||
TimeoutStopSec=cfg.stopKillTimeout;
|
TimeoutStopSec=cfg.stopKillTimeout;
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in a new issue