Skip to content
This repository has been archived by the owner on Jul 25, 2022. It is now read-only.

gardenctl ssh to az nodes failed with lots of panic #500

Open
neo-liang-sap opened this issue Jan 13, 2021 · 1 comment
Open

gardenctl ssh to az nodes failed with lots of panic #500

neo-liang-sap opened this issue Jan 13, 2021 · 1 comment
Labels
lifecycle/rotten Nobody worked on this for 12 months (final aging stage)

Comments

@neo-liang-sap
Copy link
Contributor

Describe the bug
In debugging of some loki issue when we were trying to ssh to one of seed node we encountered sth like these

(1/4) Fetching data from target shoot cluster
Standard
Data fetched from target shoot cluster.

(2/4) Configuring Azure
Opened SSH Port.

Create public ip
51.124.94.127
Waiting 5 s until public ip is available.

Add public ip to nic


(4/4) Cleanup

  (1/3) Remove SSH rule
panic: runtime error: index out of range [0] with length 0
	panic: runtime error: index out of range [0] with length 0

goroutine 1 [running]:
github.com/gardener/gardenctl/pkg/cmd.operate(0x23a0915, 0x2, 0xc000bd6680, 0x74, 0x0, 0x0)
	/Users/i352986/git_repo/gardenctl/pkg/cmd/operate.go:68 +0x2f65
github.com/gardener/gardenctl/pkg/cmd.(*AzureInstanceAttribute).cleanupAzure(0xc0001739c8)
	/Users/i352986/git_repo/gardenctl/pkg/cmd/ssh_azure.go:154 +0x296
panic(0x22c7500, 0xc0015ff8e0)
	/usr/local/Cellar/go/1.15.3/libexec/src/runtime/panic.go:969 +0x1b9
github.com/gardener/gardenctl/pkg/cmd.operate(0x23a0915, 0x2, 0xc00093a000, 0xc6, 0x0, 0x0)
	/Users/i352986/git_repo/gardenctl/pkg/cmd/operate.go:68 +0x2f65
github.com/gardener/gardenctl/pkg/cmd.(*AzureInstanceAttribute).configureNic(0xc0001739c8)
	/Users/i352986/git_repo/gardenctl/pkg/cmd/ssh_azure.go:142 +0x23d
github.com/gardener/gardenctl/pkg/cmd.sshToAZNode(0x25462a0, 0x2f8b540, 0x7ffeefbff7de, 0x2f, 0xc00004a540, 0x54, 0x23a3980, 0x8, 0xc000112140, 0x38, ...)
	/Users/i352986/git_repo/gardenctl/pkg/cmd/ssh_azure.go:70 +0x485
github.com/gardener/gardenctl/pkg/cmd.NewSSHCmd.func1(0xc000423600, 0xc0003c7380, 0x1, 0x1, 0x0, 0x0)
	/Users/i352986/git_repo/gardenctl/pkg/cmd/ssh.go:111 +0xc4d
github.com/spf13/cobra.(*Command).execute(0xc000423600, 0xc0003c7320, 0x1, 0x1, 0xc000423600, 0xc0003c7320)
	/Users/i352986/git_repo/gardenctl/vendor/github.com/spf13/cobra/command.go:840 +0x47c
github.com/spf13/cobra.(*Command).ExecuteC(0x2f48040, 0x1d, 0xc00003fe80, 0x36)
	/Users/i352986/git_repo/gardenctl/vendor/github.com/spf13/cobra/command.go:945 +0x336
github.com/spf13/cobra.(*Command).Execute(...)
	/Users/i352986/git_repo/gardenctl/vendor/github.com/spf13/cobra/command.go:885
github.com/gardener/gardenctl/pkg/cmd.Execute()
	/Users/i352986/git_repo/gardenctl/pkg/cmd/root.go:117 +0x3ba
main.main()
	/Users/i352986/git_repo/gardenctl/cmd/gardenctl/main.go:20 +0x25

To Reproduce
Steps to reproduce the behavior:

  1. Which target was set 'gardenctl get target'
  2. Which command was entered [e.g. 'gardenctl show vpn-seed']
  3. What was the output of the command

Expected behavior
gardenctl k get nodes
gardenctl ssh node_name

Screenshots
If applicable, add screenshots to help explain your problem.
image

Gardenctl Version (please complete the following information):

  • Version/Commit latest in master branch
    Additional context
@neo-liang-sap
Copy link
Contributor Author

the issue seems intermittent - i tried sometime later today and it's success without problem, for same shoot, same node
image

@gardener-robot gardener-robot added the lifecycle/stale Nobody worked on this for 6 months (will further age) label Sep 22, 2021
@gardener-robot gardener-robot added lifecycle/rotten Nobody worked on this for 12 months (final aging stage) and removed lifecycle/stale Nobody worked on this for 6 months (will further age) labels Mar 24, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
lifecycle/rotten Nobody worked on this for 12 months (final aging stage)
Projects
None yet
Development

No branches or pull requests

2 participants