Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

set loadbalancer configs before initializing the OS clients #14887

Merged
merged 2 commits into from
Dec 30, 2022

Conversation

zetaab
Copy link
Member

@zetaab zetaab commented Dec 27, 2022

fixes #14886

the problem was that Openstack cloud clients were called and initialised before setting up base setup for loadbalancer.

cc @olemarkus I think you modified this part of code sometime ago.

@k8s-ci-robot k8s-ci-robot added cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. labels Dec 27, 2022
@zetaab
Copy link
Member Author

zetaab commented Dec 27, 2022

another issue after cluster is up and running

Dec 27 13:28:47 control-plane-esptnl-8wun7d protokube[25007]: panic: runtime error: invalid memory address or nil pointer dereference
Dec 27 13:28:47 control-plane-esptnl-8wun7d protokube[25007]: [signal SIGSEGV: segmentation violation code=0x1 addr=0x20 pc=0x2e21d39]
Dec 27 13:28:47 control-plane-esptnl-8wun7d protokube[25007]: goroutine 1 [running]:
Dec 27 13:28:47 control-plane-esptnl-8wun7d protokube[25007]: k8s.io/kops/upup/pkg/fi/cloudup/openstack.NewOpenstackCloud(0x0, {0x3cd026e, 0x9})
Dec 27 13:28:47 control-plane-esptnl-8wun7d protokube[25007]: #011k8s.io/kops/upup/pkg/fi/cloudup/openstack/cloud.go:367 +0x759
Dec 27 13:28:47 control-plane-esptnl-8wun7d protokube[25007]: k8s.io/kops/protokube/pkg/protokube.NewOpenStackCloudProvider()
Dec 27 13:28:47 control-plane-esptnl-8wun7d protokube[25007]: #011k8s.io/kops/protokube/pkg/protokube/openstack_volume.go:234 +0x85
Dec 27 13:28:47 control-plane-esptnl-8wun7d protokube[25007]: main.run()
Dec 27 13:28:47 control-plane-esptnl-8wun7d protokube[25007]: #011k8s.io/kops/protokube/cmd/protokube/main.go:129 +0xc59
Dec 27 13:28:47 control-plane-esptnl-8wun7d protokube[25007]: main.main()
Dec 27 13:28:47 control-plane-esptnl-8wun7d protokube[25007]: #011k8s.io/kops/protokube/cmd/protokube/main.go:47 +0x7b

@k8s-ci-robot k8s-ci-robot added area/provider/openstack Issues or PRs related to openstack provider size/S Denotes a PR that changes 10-29 lines, ignoring generated files. and removed size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. labels Dec 27, 2022

hasDNS := !cluster.IsGossip() && !cluster.UsesNoneDNS()
return buildClients(provider, tags, cluster.Spec.CloudProvider.Openstack, config, region, hasDNS)
// used by protokube
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

when protokube uses this the cluster is nil always

@johngmyers
Copy link
Member

I don't have enough OpenStack expertise to review this
/unassign

@johngmyers johngmyers removed their request for review December 29, 2022 02:46
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: olemarkus

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added lgtm "Looks good to me", indicates that a PR is ready to be merged. approved Indicates a PR has been approved by an approver from all required OWNERS files. labels Dec 30, 2022
k8s-ci-robot added a commit that referenced this pull request Dec 30, 2022
…-upstream-release-1.26

Automated cherry pick of #14887: set loadbalancer configs before initializing the OS
@k8s-ci-robot k8s-ci-robot merged commit e85051b into kubernetes:master Dec 30, 2022
@zetaab zetaab deleted the fixoscreate branch December 30, 2022 09:07
Shimiazoulai pushed a commit to spotinst/kubernetes-kops that referenced this pull request Jul 13, 2023
…-of-#14887-upstream-release-1.26

Automated cherry pick of kubernetes#14887: set loadbalancer configs before initializing the OS
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. area/provider/openstack Issues or PRs related to openstack provider cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. size/S Denotes a PR that changes 10-29 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Creating new clusters in OpenStack broken
4 participants