From f99a8dea3f7475d9054ec8ca46110ea4b819cb2f Mon Sep 17 00:00:00 2001 From: Miles Simpson Date: Tue, 28 Mar 2023 16:31:17 -0700 Subject: [PATCH] core: fix config format for msgr2 ipv6 monitors Signed-off-by: Miles Simpson --- pkg/daemon/ceph/client/config.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pkg/daemon/ceph/client/config.go b/pkg/daemon/ceph/client/config.go index 8d4148b0d..f2cc6119b 100644 --- a/pkg/daemon/ceph/client/config.go +++ b/pkg/daemon/ceph/client/config.go @@ -261,7 +261,8 @@ func PopulateMonHostMembers(clusterInfo *ClusterInfo) ([]string, []string) { currentMonPort := cephutil.GetPortFromEndpoint(monitor.Endpoint) if currentMonPort == Msgr2port { - monHosts = append(monHosts, fmt.Sprintf("[v2:%s:%d]", monIP, Msgr2port)) + msgr2Endpoint := net.JoinHostPort(monIP, strconv.Itoa(int(Msgr2port))) + monHosts = append(monHosts, "[v2:"+msgr2Endpoint+"]") } else { msgr2Endpoint := net.JoinHostPort(monIP, strconv.Itoa(int(Msgr2port))) msgr1Endpoint := net.JoinHostPort(monIP, strconv.Itoa(int(currentMonPort)))