Uploaded image for project: 'OpenShift Installer'
  1. OpenShift Installer
  2. CORS-3472

installer crashes when`us-east2` or `us-east3`GCP region is used.

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Minor Minor
    • None
    • openshift-4.16
    • None
    • False
    • None
    • False

      Regions `us-east2` and `us-east3` GCP regions doesn't have zones and when these regions are used for creating cluster, installer crashes with below stack trace.

      $ openshift-install version
      openshift-install 4.16.0-0.ci.test-2024-04-23-055943-ci-ln-z602w5b-latest
      built from commit 0bbbb0261b724628c8e68569f31f86fd84669436
      release image registry.build03.ci.openshift.org/ci-ln-z602w5b/release@sha256:a0df6e54dfd5d45e8ec6f2fcb07fa99cf682f7a79ea3bc07459d3ba1dbb47581
      release architecture amd64
      $ yq-3.3.0 r test4/install-config.yaml platform
      gcp:
        projectID: openshift-qe
        region: us-east2
        userTags:
        - parentID: 54643501348
          key: ocp_tag_dev
          value: bar
        - parentID: openshift-qe
          key: Su.Shi-Jiang_Cheng_Zi
          value: SHI NIAN
        userLabels:
        - key: createdby
          value: installer-qe
        - key: a
          value: 8
      $ yq-3.3.0 r test4/install-config.yaml credentialsMode
      Passthrough
      $ yq-3.3.0 r test4/install-config.yaml featureSet
      TechPreviewNoUpgrade
      $ yq-3.3.0 r test4/install-config.yaml metadata.name
      jiwei-0424a
      $
      $ openshift-install create cluster --dir test4
      INFO Credentials loaded from file "/home/fedora/.gcp/osServiceAccount.json"
      panic: runtime error: index out of range [0] with length 0goroutine 1 [running]:
      github.com/openshift/installer/pkg/asset/installconfig/gcp.(*Client).GetMachineTypeWithZones(0xc0017a7f90?, {0x1f6dd998, 0x23ab4be0}, {0xc0007e6650, 0xc}, {0xc0007e6660, 0x8}, {0x7c2b604, 0xd})
              /go/src/github.com/openshift/installer/pkg/asset/installconfig/gcp/client.go:142 +0x5e8
      github.com/openshift/installer/pkg/asset/installconfig/gcp.ValidateInstanceType({0x1f6fe5e8?, 0xc0007e0428?}, 0xc001a7cde0, {0xc0007e6650?, 0x27f?}, {0xc0007e6660?, 0x40ffcf?}, {0xc000efe980, 0x0, 0x0}, ...)
              /go/src/github.com/openshift/installer/pkg/asset/installconfig/gcp/validation.go:80 +0x6c
      github.com/openshift/installer/pkg/asset/installconfig/gcp.validateInstanceTypes({0x1f6fe5e8, 0xc0007e0428}, 0xc00107f080)
              /go/src/github.com/openshift/installer/pkg/asset/installconfig/gcp/validation.go:189 +0x4f7
      github.com/openshift/installer/pkg/asset/installconfig/gcp.Validate({0x1f6fe5e8?, 0xc0007e0428}, 0xc00107f080)
              /go/src/github.com/openshift/installer/pkg/asset/installconfig/gcp/validation.go:63 +0xf45
      github.com/openshift/installer/pkg/asset/installconfig.(*InstallConfig).platformValidation(0xc0011d8f80)
              /go/src/github.com/openshift/installer/pkg/asset/installconfig/installconfig.go:199 +0x21a
      github.com/openshift/installer/pkg/asset/installconfig.(*InstallConfig).finish(0xc0011d8f80, {0x7c518a9, 0x13})
              /go/src/github.com/openshift/installer/pkg/asset/installconfig/installconfig.go:171 +0x6ce
      github.com/openshift/installer/pkg/asset/installconfig.(*InstallConfig).Load(0xc0011d8f80, {0x1f69a550?, 0xc001155c70?})
              /go/src/github.com/openshift/installer/pkg/asset/installconfig/installconfig.go:112 +0x55
      github.com/openshift/installer/pkg/asset/store.(*storeImpl).load(0xc000c5f440, {0x1f6c8080, 0xc0011d8ac0}, {0xc001163c6c, 0x4})
              /go/src/github.com/openshift/installer/pkg/asset/store/store.go:264 +0x33f
      github.com/openshift/installer/pkg/asset/store.(*storeImpl).load(0xc000c5f440, {0x1f6cc230, 0xc001199360}, {0x7c056f3, 0x2})
              /go/src/github.com/openshift/installer/pkg/asset/store/store.go:247 +0x23a
      github.com/openshift/installer/pkg/asset/store.(*storeImpl).load(0xc000c5f440, {0x7f88420a5000, 0x23a57c20}, {0x0, 0x0})
              /go/src/github.com/openshift/installer/pkg/asset/store/store.go:247 +0x23a
      github.com/openshift/installer/pkg/asset/store.(*storeImpl).fetch(0xc000c5f440, {0x1f6ddab0, 0xc0011b6eb0}, {0x7f88420a5000, 0x23a57c20}, {0x0, 0x0})
              /go/src/github.com/openshift/installer/pkg/asset/store/store.go:201 +0x1b1
      github.com/openshift/installer/pkg/asset/store.(*storeImpl).Fetch(0x7fffbc31408f?, {0x1f6ddab0?, 0xc0011b6eb0?}, {0x7f88420a5000, 0x23a57c20}, {0x23a27e60, 0x8, 0x8})
              /go/src/github.com/openshift/installer/pkg/asset/store/store.go:77 +0x54
      github.com/openshift/installer/pkg/asset/store.(*fetcher).FetchAndPersist(0xc001155c60, {0x1f6ddab0, 0xc0011b6eb0}, {0x23a27e60, 0x8, 0x8})
              /go/src/github.com/openshift/installer/pkg/asset/store/assetsfetcher.go:47 +0x165
      main.newCreateCmd.runTargetCmd.func3({0x7fffbc31408f?, 0x5?})
              /go/src/github.com/openshift/installer/cmd/openshift-install/create.go:301 +0x6a
      main.newCreateCmd.runTargetCmd.func4(0xc000fdf600?, {0xc001199260?, 0x4?, 0x7c06e81?})
              /go/src/github.com/openshift/installer/cmd/openshift-install/create.go:315 +0x102
      github.com/spf13/cobra.(*Command).execute(0x23a324c0, {0xc001199220, 0x2, 0x2})
              /go/src/github.com/openshift/installer/vendor/github.com/spf13/cobra/command.go:987 +0xaa3
      github.com/spf13/cobra.(*Command).ExecuteC(0xc001005500)
              /go/src/github.com/openshift/installer/vendor/github.com/spf13/cobra/command.go:1115 +0x3ff
      github.com/spf13/cobra.(*Command).Execute(...)
              /go/src/github.com/openshift/installer/vendor/github.com/spf13/cobra/command.go:1039
      main.installerMain()
              /go/src/github.com/openshift/installer/cmd/openshift-install/main.go:62 +0x385
      main.main()
              /go/src/github.com/openshift/installer/cmd/openshift-install/main.go:36 +0x11d 

      Additional info: slack thread discussion https://redhat-internal.slack.com/archives/C01V1DP387R/p1713959395808119

              rh-ee-bbarbach Brent Barbachem
              rhn-support-jiwei Jianli Wei
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated: