Uploaded image for project: 'OpenShift Bugs'
  1. OpenShift Bugs
  2. OCPBUGS-55324

Installer panic when setting both custom subnets and additional security group

XMLWordPrintable

    • Important
    • Yes
    • Installer Sprint 270
    • 1
    • Proposed
    • False
    • Hide

      None

      Show
      None
    • Release Note Not Required

      Description of problem:

          Panic happened when setting both custom subnets and additional security group in install-config.yaml

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

          4.19.0-0.nightly-2025-04-17-154552

      How reproducible:

          Alwyas

      Steps to Reproduce:

          1. create aws vpc, record all the subnest ID
          2. create a security gourp, record the sg ID
          3. create install-config.yaml, set platform.aws.subnets and platform.aws.defaultMachinePlatform.additionalSecurityGroupIDs together
      E.g:
      platform:
        aws:
          region: us-east-2
          subnets:
          - subnet-046e3a4618c4e0e4e
          - subnet-0dd99f7e1695a90c8
          - subnet-095f4f02a8b65866c
          - subnet-07e80f7eea3ed3db0
          defaultMachinePlatform:
            additionalSecurityGroupIDs:
            - sg-0594ae9527482c34f

      Actual results:

          $ openshift-install create manifestsWARNING platform.aws.subnets is deprecated. Converted to platform.aws.vpc.subnets panic: runtime error: invalid memory address or nil pointer dereference[signal SIGSEGV: segmentation violation code=0x1 addr=0x0 pc=0x213a8ed]
      goroutine 1 [running]:github.com/aws/aws-sdk-go/aws/session.(*Session).Copy(0x0, {0xc0010ac700?, 0x0?, 0x0?})	/go/src/github.com/openshift/installer/vendor/github.com/aws/aws-sdk-go/aws/session/session.go:860 +0x2dgithub.com/aws/aws-sdk-go/aws/session.(*Session).ClientConfig(_, {_, _}, {_, _, _})	/go/src/github.com/openshift/installer/vendor/github.com/aws/aws-sdk-go/aws/session/session.go:874 +0x65github.com/aws/aws-sdk-go/service/ec2.New({0x22785060?, 0x0?}, {0xc0010ac700?, 0x0?, 0x0?})	/go/src/github.com/openshift/installer/vendor/github.com/aws/aws-sdk-go/service/ec2/service.go:51 +0x53github.com/openshift/installer/pkg/asset/installconfig/aws.DescribeSecurityGroups({0x22839f38, 0x27c7e0c0}, 0x0, {0xc0013d3860, 0x1, 0x7f8af051d0d0?}, {0xc0013fe350, 0x9})	/go/src/github.com/openshift/installer/pkg/asset/installconfig/aws/ec2.go:41 +0x154github.com/openshift/installer/pkg/asset/installconfig/aws.validateSecurityGroupIDs({0x22839f38, 0x27c7e0c0}, 0xc0013ed8c0, 0xc00127f920, 0xc0002017a0, 0xc00090a4d0)	/go/src/github.com/openshift/installer/pkg/asset/installconfig/aws/validation.go:496 +0x257github.com/openshift/installer/pkg/asset/installconfig/aws.validateMachinePool({0x22839f38, 0x27c7e0c0}, 0xc0013ed8c0, 0xc00127f8f0, 0xc0002017a0, 0xc00090a4d0, {0x30?, 0x0?}, {0x0, 0x0}, ...)	/go/src/github.com/openshift/installer/pkg/asset/installconfig/aws/validation.go:457 +0xc8fgithub.com/openshift/installer/pkg/asset/installconfig/aws.validatePlatform({0x22839f38, 0x27c7e0c0}, 0xc0013ed8c0, 0xc00122f9b0, 0xc001334588)	/go/src/github.com/openshift/installer/pkg/asset/installconfig/aws/validation.go:116 +0x425github.com/openshift/installer/pkg/asset/installconfig/aws.Validate({0x22839f38, 0x27c7e0c0}, 0xc0013ed8c0, 0xc001334588)	/go/src/github.com/openshift/installer/pkg/asset/installconfig/aws/validation.go:53 +0x638github.com/openshift/installer/pkg/asset/installconfig.(*InstallConfig).platformValidation(0xc00135c540, {0x22839f38?, 0x27c7e0c0?})	/go/src/github.com/openshift/installer/pkg/asset/installconfig/installconfig.go:214 +0x131github.com/openshift/installer/pkg/asset/installconfig.(*InstallConfig).finish(0xc00135c540, {0x22839f38, 0x27c7e0c0}, {0x9fce9dd, 0x13})	/go/src/github.com/openshift/installer/pkg/asset/installconfig/installconfig.go:172 +0x725github.com/openshift/installer/pkg/asset/installconfig.(*InstallConfig).Load(0xc00135c540, {0x227b4c08?, 0xc0012d8ea0?})	/go/src/github.com/openshift/installer/pkg/asset/installconfig/installconfig.go:113 +0x65github.com/openshift/installer/pkg/asset/store.(*storeImpl).load(0xc00135a030, {0x2280afc0, 0xc00135c080}, {0xc00129de5c, 0x4})	/go/src/github.com/openshift/installer/pkg/asset/store/store.go:264 +0xc27github.com/openshift/installer/pkg/asset/store.(*storeImpl).load(0xc00135a030, {0x2280f4a0, 0xc001358160}, {0x9f709d2, 0x2})	/go/src/github.com/openshift/installer/pkg/asset/store/store.go:247 +0x22dgithub.com/openshift/installer/pkg/asset/store.(*storeImpl).load(0xc00135a030, {0x22810760, 0x27c48ee0}, {0x0, 0x0})	/go/src/github.com/openshift/installer/pkg/asset/store/store.go:247 +0x22dgithub.com/openshift/installer/pkg/asset/store.(*storeImpl).fetch(0xc00135a030, {0x22839ff0, 0xc0012db540}, {0x22810760, 0x27c48ee0}, {0x0, 0x0})	/go/src/github.com/openshift/installer/pkg/asset/store/store.go:201 +0x1b1github.com/openshift/installer/pkg/asset/store.(*storeImpl).Fetch(0xc00135a030, {0x22839ff0?, 0xc0012db540?}, {0x22810760, 0x27c48ee0}, {0x27bf7080, 0x7, 0x7})	/go/src/github.com/openshift/installer/pkg/asset/store/store.go:77 +0x4egithub.com/openshift/installer/pkg/asset/store.(*fetcher).FetchAndPersist(0xc0012d8e90, {0x22839ff0, 0xc0012db540}, {0x27bf7080, 0x7, 0x7})	/go/src/github.com/openshift/installer/pkg/asset/store/assetsfetcher.go:47 +0x16bmain.newCreateCmd.runTargetCmd.func3({0x2275bb90?, 0x1?})	/go/src/github.com/openshift/installer/cmd/openshift-install/create.go:321 +0x6amain.newCreateCmd.runTargetCmd.func4(0x27c03a40, {0x27c7e0c0?, 0x4?, 0x9f722d0?})	/go/src/github.com/openshift/installer/cmd/openshift-install/create.go:335 +0x102github.com/spf13/cobra.(*Command).execute(0x27c03a40, {0x27c7e0c0, 0x0, 0x0})	/go/src/github.com/openshift/installer/vendor/github.com/spf13/cobra/command.go:1019 +0xa7bgithub.com/spf13/cobra.(*Command).ExecuteC(0xc0000b7b08)	/go/src/github.com/openshift/installer/vendor/github.com/spf13/cobra/command.go:1148 +0x40cgithub.com/spf13/cobra.(*Command).Execute(...)	/go/src/github.com/openshift/installer/vendor/github.com/spf13/cobra/command.go:1071main.installerMain()	/go/src/github.com/openshift/installer/cmd/openshift-install/main.go:67 +0x390main.main()	/go/src/github.com/openshift/installer/cmd/openshift-install/main.go:39 +0x168
      

      Expected results:

          No panic

      Additional info:

          Looks like this is a regression issue introduced by https://issues.redhat.com/browse/CORS-3440

              rh-ee-thvo Thuan Vo
              jialiu@redhat.com Johnny Liu
              Johnny Liu Johnny Liu
              Votes:
              0 Vote for this issue
              Watchers:
              7 Start watching this issue

                Created:
                Updated:
                Resolved: