From 010efe332e3a0bc3995b5e57cc7b851ae3564e6e Mon Sep 17 00:00:00 2001 From: Ross Brattain Date: Tue, 21 Jan 2025 06:23:29 -0500 Subject: [PATCH] OCPBUGS-46072: create /run/nodeip-configuration before use With nmstate `br-ex` creation using static IP, it looks like the systemd boot ordering can change and we can attempt to run `30-resolv-prepender` before `nodeip-configuration.service`. When `30-resolv-prepender` runs it tries to touch a file in `/run/nodeip-configuration` when it does not exist. ```log nm-dispatcher[2409]: touch: cannot touch '/run/nodeip-configuration/br-ex-up': No such file or directory ``` The quick fix is to always mkdir before touching, then we don't have to track the global state of `/run/nodeip-configuration` --- .../common/on-prem/files/NetworkManager-resolv-prepender.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/templates/common/on-prem/files/NetworkManager-resolv-prepender.yaml b/templates/common/on-prem/files/NetworkManager-resolv-prepender.yaml index 8ebbdb5d3c..098d2b8490 100644 --- a/templates/common/on-prem/files/NetworkManager-resolv-prepender.yaml +++ b/templates/common/on-prem/files/NetworkManager-resolv-prepender.yaml @@ -63,6 +63,7 @@ contents: fi if [[ "$STATUS" == "up" ]] && [[ $IFACE == "br-ex" ]]; then + /bin/mkdir -p /run/nodeip-configuration touch /run/nodeip-configuration/br-ex-up fi ;;