Bug 1763927 - "FATAL failed to fetch Terraform Variables" error is seen when installing to existing VPC using install-config.yaml and did not configure default region in localhost
Summary: "FATAL failed to fetch Terraform Variables" error is seen when installing to ...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Installer
Version: 4.3.0
Hardware: Unspecified
OS: Unspecified
high
high
Target Milestone: ---
: 4.3.0
Assignee: Abhinav Dahiya
QA Contact: Johnny Liu
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2019-10-22 01:25 UTC by Johnny Liu
Modified: 2020-01-23 11:08 UTC (History)
0 users

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2020-01-23 11:08:30 UTC
Target Upstream Version:


Attachments (Terms of Use)


Links
System ID Priority Status Summary Last Updated
Github openshift installer pull 2545 'None' closed Bug 1763927: asset/installconfig/aws: configure region when listing subnets 2020-06-29 22:39:32 UTC
Github openshift installer pull 2619 'None' closed Bug 1763927: asset/cluster/aws: create resourcetaggingapi client with region 2020-06-29 22:39:32 UTC
Red Hat Product Errata RHBA-2020:0062 None None None 2020-01-23 11:08:49 UTC

Description Johnny Liu 2019-10-22 01:25:32 UTC
Description of problem:

Version-Release number of the following components:
4.3.0-0.nightly-2019-10-21-014711
$ ./openshift-install v4.3.0
built from commit adb42181e45dbd9953582d72d4195b43623e023e
release image registry.svc.ci.openshift.org/ocp/release@sha256:e6238bf78c3870ec0a686edb2aae16b59dd3ca70aadeea07ebb9ae37123b8eaf

How reproducible:
Always

Steps to Reproduce:
1. Make sure no "~/.aws" or have no "~/.aws/config" configuration file.
2. Install a cluster without specifying subnets, succeed. 
3. Get the created subnets list from the installed cluster
4. Specify subnets in install-config.yaml
platform:
  aws:
    region: us-east-2
    subnets: 
    - subnet-037a522ba8470c624
    - subnet-03ee088eaa8431e00
    - subnet-06d9da5622c4dec6b
    - subnet-07f33bba97d9b15b7
    - subnet-0b24358871634489b
    - subnet-0e395111a4ab16778
5. Trigger a 2nd install using the same subnets via the install-config.yaml


Actual results:
# openshift-install create cluster --dir demo1
<--snip-->
FATAL failed to fetch Terraform Variables: failed to fetch dependency of "Terraform Variables": failed to fetch dependency of "Bootstrap Ignition Config": failed to generate asset "Master Machines": describing subnets: MissingRegion: could not find region configuration 



Expected results:
The 2nd cluster should be installed successfully when no "~/.aws/config" configuration file.

Additional info:
Please attach logs from ansible-playbook with the -vvv flag

Comment 2 Johnny Liu 2019-10-31 10:32:36 UTC
Re-test this bug with 4.3.0-0.nightly-2019-10-31-050543, failed. 

./openshift-install v4.3.0
built from commit f2ac89df630f6ae6efb91e8a6f01c5a120389942
release image registry.svc.ci.openshift.org/ocp/release@sha256:dbd10b97d37a0a9b51daebbe211790774e56a57d4756a32949cf70b0a5e61f76

level=info msg="Creating infrastructure resources..."
level=debug msg="Tagging arn:aws:ec2:us-east-2:301721915996:subnet/subnet-071c1a2fd3781a226 with kubernetes.io/cluster/jialiu432-8qf76: shared"
level=debug msg="Tagging arn:aws:ec2:us-east-2:301721915996:subnet/subnet-061a6c4030053e89d with kubernetes.io/cluster/jialiu432-8qf76: shared"
level=debug msg="Tagging arn:aws:ec2:us-east-2:301721915996:subnet/subnet-03c13fd12cbea6836 with kubernetes.io/cluster/jialiu432-8qf76: shared"
level=debug msg="Tagging arn:aws:ec2:us-east-2:301721915996:subnet/subnet-0a20d2002346f1e3e with kubernetes.io/cluster/jialiu432-8qf76: shared"
level=debug msg="Tagging arn:aws:ec2:us-east-2:301721915996:subnet/subnet-09c69efc3018207d8 with kubernetes.io/cluster/jialiu432-8qf76: shared"
level=debug msg="Tagging arn:aws:ec2:us-east-2:301721915996:subnet/subnet-03e52fcd9af6128b2 with kubernetes.io/cluster/jialiu432-8qf76: shared"
level=fatal msg="failed to fetch Cluster: failed to generate asset \"Cluster\": MissingRegion: could not find region configuration"

The reported error become a bit different now, but still failed.

Comment 5 Johnny Liu 2019-11-07 09:36:27 UTC
Verified this bug with 4.3.0-0.nightly-2019-11-07-033535, and PASS.

level=debug msg="Generating Cluster..."
level=info msg="Creating infrastructure resources..."
level=debug msg="Tagging arn:aws:ec2:us-east-2:301721915996:subnet/subnet-0b7428b05ebf73676 with kubernetes.io/cluster/jialiu43bz1-8lmvt: shared"
level=debug msg="Tagging arn:aws:ec2:us-east-2:301721915996:subnet/subnet-00905863c6c3eaad8 with kubernetes.io/cluster/jialiu43bz1-8lmvt: shared"
level=debug msg="Tagging arn:aws:ec2:us-east-2:301721915996:subnet/subnet-0ae0faef925559a7b with kubernetes.io/cluster/jialiu43bz1-8lmvt: shared"
level=debug msg="Tagging arn:aws:ec2:us-east-2:301721915996:subnet/subnet-0e93f18f5dd8b8dab with kubernetes.io/cluster/jialiu43bz1-8lmvt: shared"
level=debug msg="Symlinking plugin terraform-provider-aws src: \"/home/installer2/workspace/Launch Environment Flexy/workdir/openshift-install\" dst: \"/tmp/openshift-install-436690205/plugins/terraform-provider-aws\""
level=debug msg="Symlinking plugin terraform-provider-azurerm src: \"/home/installer2/workspace/Launch Environment Flexy/workdir/openshift-install\" dst: \"/tmp/openshift-install-436690205/plugins/terraform-provider-azurerm\""

Installation get completed successfully.

+ oc get clusterversion
NAME      VERSION                             AVAILABLE   PROGRESSING   SINCE   STATUS
version   4.3.0-0.nightly-2019-11-07-033535   True        False         78s     Cluster version is 4.3.0-0.nightly-2019-11-07-033535

Comment 7 errata-xmlrpc 2020-01-23 11:08:30 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.

https://access.redhat.com/errata/RHBA-2020:0062


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