From 41437c511b6e89bfa45c397549d48a77b83d57ef Mon Sep 17 00:00:00 2001 From: Jarrod Johnson Date: Mon, 12 Jun 2023 08:49:13 -0400 Subject: [PATCH] Fix when networkmanager breaks one of our connections This usually happens with ipv6 link local used in initramfs stage, after networkmanager may mutilate the ipv6 connectivity. --- confluent_osdeploy/common/profile/scripts/confignet | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/confluent_osdeploy/common/profile/scripts/confignet b/confluent_osdeploy/common/profile/scripts/confignet index 9823bca6..b2cee959 100644 --- a/confluent_osdeploy/common/profile/scripts/confignet +++ b/confluent_osdeploy/common/profile/scripts/confignet @@ -316,7 +316,10 @@ if __name__ == '__main__': srvs, _ = apiclient.scan_confluents() doneidxs = set([]) for srv in srvs: - s = socket.create_connection((srv, 443)) + try: + s = socket.create_connection((srv, 443)) + except socket.error: + continue myname = s.getsockname() s.close() if len(myname) == 4: