Bug 1822326

Summary: The ip check in the etcd-ensure-env-vars init container doesn't work in the ipv6 environments
Product: OpenShift Container Platform Reporter: Suresh Kolichala <skolicha>
Component: EtcdAssignee: Suresh Kolichala <skolicha>
Status: CLOSED ERRATA QA Contact: ge liu <geliu>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 4.5   
Target Milestone: ---   
Target Release: 4.5.0   
Hardware: Unspecified   
OS: Unspecified   
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Cause: The env var check wasn't accounting for IPv6 addresses. Consequence: The init container fails to succeed, and hence etcd never starts. Fix: Check for both ipv4 and ipv6 addresses (with square brackets) Result: The init container succeeds with env checks, and etcd container successfully starts.
Story Points: ---
Clone Of:
: 1822327 (view as bug list) Environment:
Last Closed: 2020-07-13 17:26:34 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Bug Depends On:    
Bug Blocks: 1822327    

Description Suresh Kolichala 2020-04-08 18:21:39 UTC
Description of problem:

The fix for Bug 1817028 (https://bugzilla.redhat.com/show_bug.cgi?id=1817028) introduced a new init container to validate the etcd environment before firing up the etcd. However, the checks for ensuring the etcd environment rely on ipstring comparison which fails in the ipv6 environments. 

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
1. Create a ipv6 cluster

Actual results:
The etcd members fails to start with the init container failing forever with an error similar to:
Expected node IP to be fd2e:6f44:5dd8:c956::15 got [fd2e:6f44:5dd8:c956::15]

Expected results:
etcd to come up normally, and the cluster to become available.

Additional info:

Comment 4 errata-xmlrpc 2020-07-13 17:26:34 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.