Bug 1955336 - Failure to Install OpenShift on GCP due to Cluster Name being similar to / contains "google"
Summary: Failure to Install OpenShift on GCP due to Cluster Name being similar to / co...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Installer
Version: 4.7
Hardware: Unspecified
OS: Unspecified
low
low
Target Milestone: ---
: 4.8.0
Assignee: Aditya Narayanaswamy
QA Contact: To Hung Sze
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2021-04-29 21:39 UTC by Max Whittingham
Modified: 2021-07-27 23:06 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
GCP does not allow resources to be created with names similar to the word google. Adding a check in the installer on the cluster name for all known variations of the word google that are not allowed.
Clone Of:
Environment:
Last Closed: 2021-07-27 23:05:13 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
Installer logs (2.66 KB, text/plain)
2021-04-29 21:39 UTC, Max Whittingham
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Github openshift installer pull 4925 0 None open Bug 1955336: Check cluster name for similarities with word 'google' 2021-05-11 16:02:44 UTC
Red Hat Product Errata RHSA-2021:2438 0 None None None 2021-07-27 23:06:02 UTC

Description Max Whittingham 2021-04-29 21:39:34 UTC
Created attachment 1777487 [details]
Installer logs

Version: 4.7

Platform: OSD on GCP

Please specify:
* IPI

What happened?

Cluster was created using the name 'google-test', installation failed due to the inability to create a bucket with the name 'google-test-xxxxx-bootstrap-ignition'

#For example, 

# If the installer fails to create resources (https://github.com/openshift/installer/blob/master/docs/user/troubleshooting.md#installer-fails-to-create-resources), attach the relevant portions of your `.openshift_install.log.`
# If the installer fails to bootstrap the cluster (https://github.com/openshift/installer/blob/master/docs/user/troubleshootingbootstrap.md), attach the bootstrap log bundle.
# If the installer fails to complete installation after bootstrapping completes (https://github.com/openshift/installer/blob/master/docs/user/troubleshooting.md#installer-fails-to-initialize-the-cluster), attach the must-gather log bundle using `oc adm must-gather`

# Always at least include the `.openshift_install.log`

What did you expect to happen?

Bucket creation

How to reproduce it (as minimally and precisely as possible)?

$ your-commands-here

Anything else we need to know?

#Enter text here.

Comment 1 Matthew Staebler 2021-04-29 21:55:14 UTC
Bucket names cannot start with "goog" or contain close spellings to "google".
https://cloud.google.com/storage/docs/naming-buckets#:~:text=Bucket%20names%20cannot%20be%20represented,%2C%20such%20as%20%22g00gle%22.
We can add some installer validation, but it is unlikely to catch all invalid names.

Comment 2 Tomas Dabašinskas 2021-04-29 22:38:52 UTC
+1 for adding logic to pattern match invalid names if there are known limitations around that

Comment 3 To Hung Sze 2021-05-02 14:21:53 UTC
Installer churns out this (cluster name google-test-tsze):
DEBUG module.master.google_compute_instance_group.master[1]: Creation complete after 13s [id=projects/openshift-qe/zones/us-central1-b/instanceGroups/google-test-tsze-mb4cw-master-us-central1-b] 
ERROR                                              
ERROR Error: googleapi: Error 400: Use of this bucket name is restricted: 'google-test-tsze-mb4cw-bootstrap-ignition', invalid 
ERROR                                              
ERROR   on ../../../../../tmp/openshift-install-357323199/bootstrap/main.tf line 1, in resource "google_storage_bucket" "ignition": 
ERROR    1: resource "google_storage_bucket" "ignition" { 
ERROR                                              
ERROR                                              
FATAL failed to fetch Cluster: failed to generate asset "Cluster": failed to create cluster: failed to apply Terraform: failed to complete the change

Comment 4 To Hung Sze 2021-05-02 14:26:46 UTC
We may need to update our user facing doc and warn users.

Comment 5 To Hung Sze 2021-05-02 14:30:03 UTC
tsze-google-test also doesn't work:
ERROR                                              
ERROR Error: googleapi: Error 400: Use of this bucket name is restricted: 'tsze-google-test-hc7j5-bootstrap-ignition', invalid 
ERROR                                              
ERROR   on ../../../../../tmp/openshift-install-840421988/bootstrap/main.tf line 1, in resource "google_storage_bucket" "ignition": 
ERROR    1: resource "google_storage_bucket" "ignition" { 
ERROR                                              
ERROR                                              
FATAL failed to fetch Cluster: failed to generate asset "Cluster": failed to create cluster: failed to apply Terraform: failed to complete the change

Comment 7 To Hung Sze 2021-05-20 13:05:28 UTC
Tested with 

google-test / test-google / goog / goog-le

Error now:
X Sorry, your reply was invalid: cluster name must not start with "goog" or contain variations of "google"

Accepts "go-og-le" / "g-oo-gl-e"

Comment 10 errata-xmlrpc 2021-07-27 23:05:13 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 (Moderate: OpenShift Container Platform 4.8.2 bug fix and security update), and where to find the updated
files, follow the link below.

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

https://access.redhat.com/errata/RHSA-2021:2438


Note You need to log in before you can comment on or make changes to this bug.