From aaffa661681f7156b325a894f2549416f265d679 Mon Sep 17 00:00:00 2001 From: John Mulligan Date: Tue, 19 Dec 2023 14:10:39 -0500 Subject: [PATCH] cehphadm: disable restarting init containers service Disable the Restart= line in the init containers systemd template. It is commented out as there are probably more appropriate workarounds to use in the future but this should fix testing on centos8 based systems. Signed-off-by: John Mulligan --- src/cephadm/cephadmlib/templates/init_ctr.service.j2 | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/cephadm/cephadmlib/templates/init_ctr.service.j2 b/src/cephadm/cephadmlib/templates/init_ctr.service.j2 index 730d5043dec..e23a72be40f 100644 --- a/src/cephadm/cephadmlib/templates/init_ctr.service.j2 +++ b/src/cephadm/cephadmlib/templates/init_ctr.service.j2 @@ -19,8 +19,12 @@ EnvironmentFile=-/etc/environment ExecStart=/bin/bash {{ ctx.data_dir }}/{{ identity.fsid }}/%i/init_containers.run ExecStop=/bin/bash {{ ctx.data_dir }}/{{ identity.fsid }}/%i/init_containers.run stop ExecStopPost=-/bin/bash {{ ctx.data_dir }}/{{ identity.fsid }}/%i/init_containers.run poststop -Restart=on-failure -RestartSec=10s +# FIXME: Disable Restart on oneshot service. systemd versions before v224 +# did not allow Restart=on-failure with a oneshot service. Having it set +# prevents the service from starting on centos8. Disable it for now and +# revisit this at a later time. +#Restart=on-failure +#RestartSec=10s TimeoutStopSec=120 StartLimitInterval=30min StartLimitBurst=5 -- 2.39.5