On certain system, the networking service can be restarted.
On systems were it is possible it should be restored that way.
Otherwise, fallback to the original method of restoring
networking by using ifup/ifdown manually.
It was seen that if restarting networking service is possible
but is not done, Calico cni will fail to be created when Kubernetes
is brought up later in the playbook.
This only impacts certain systems.
TEST PLAN
PASS: Run optimized restore with --registry-images (AIO-SX)
* Run on affected and unaffected systems
PASS: Run optimized restore without --registry-images (AIO-SX)
* Run on affected and unaffected systems
Reviewed: https:/ /review. opendev. org/c/starlingx /ansible- playbooks/ +/868251 /opendev. org/starlingx/ ansible- playbooks/ commit/ 24c75495b32278d af16291327d8289 52ccd2029b
Committed: https:/
Submitter: "Zuul (22348)"
Branch: master
commit 24c75495b32278d af16291327d8289 52ccd2029b
Author: Joshua Kraitberg <email address hidden>
Date: Tue Dec 20 20:26:07 2022 -0500
Fix calico bring-up failure in optimized restore
On certain system, the networking service can be restarted.
On systems were it is possible it should be restored that way.
Otherwise, fallback to the original method of restoring
networking by using ifup/ifdown manually.
It was seen that if restarting networking service is possible
but is not done, Calico cni will fail to be created when Kubernetes
is brought up later in the playbook.
This only impacts certain systems.
TEST PLAN
PASS: Run optimized restore with --registry-images (AIO-SX)
* Run on affected and unaffected systems
PASS: Run optimized restore without --registry-images (AIO-SX)
* Run on affected and unaffected systems
Closes-Bug: 2000184 d93edbdae3f4b02 b6243181677
Signed-off-by: Joshua Kraitberg <email address hidden>
Change-Id: I97b9fc2bbbe47e