Skip to content

Panic in cilium bpf policy get #19119

@joestringer

Description

@joestringer

Found on master, v1.12 development cycle.

Found on PR #18864, CI run: https://jenkins.cilium.io/job/Cilium-PR-Runtime-net-next/1537/testReport/junit/(root)/Suite-runtime/RuntimeConntrackInVethModeTest_Conntrack_related_configuration_options_for_endpoints/

Test: Suite-runtime.RuntimeConntrackInVethModeTest Conntrack-related configuration options for endpoints
Archive: e804e2ff_RuntimeConntrackInVethModeTest_Conntrack-related_configuration_options_for_endpoints.zip

Stacktrace

/home/jenkins/workspace/Cilium-PR-Runtime-net-next/runtime-gopath/src/github.com/cilium/cilium/test/ginkgo-ext/scopes.go:527
The result of "curl --path-as-is -s -D /dev/stderr --fail --connect-timeout 5 --max-time 20 [http://[f00d::a0f:0:0:f43a]:80](http://[f00d::a0f:0:0:f43a]/) -w \"time-> DNS: '%{time_namelookup}(%{remote_ip})', Connect: '%{time_connect}',Transfer '%{time_starttransfer}', total '%{time_total}'\"" from container "curl" to httpd2 does not match
Expected
    <bool>: true
to be false
/home/jenkins/workspace/Cilium-PR-Runtime-net-next/runtime-gopath/src/github.com/cilium/cilium/test/runtime/connectivity.go:282

...

Here's the actual panic:

 	 goroutine 1 [running]:
	 goroutine 1 runtime/debug.Stack()
	 goroutine 1 	/usr/local/go/src/runtime/debug/stack.go:24 +0x65
	 goroutine 1 github.com/cilium/cilium/pkg/lock.(*internalRWMutex).Unlock(0xc0006da3d8)
	 goroutine 1 	/home/vagrant/go/src/github.com/cilium/cilium/pkg/lock/lock_debug.go:58 +0x92
	 goroutine 1 github.com/cilium/cilium/pkg/bpf.(*Map).Open(0xc0006da360)
	 goroutine 1 	/home/vagrant/go/src/github.com/cilium/cilium/pkg/bpf/map_linux.go:544 +0x95
	 goroutine 1 github.com/cilium/cilium/pkg/maps/policymap.Open({0xc00062b290, 0x4d5f25})
	 goroutine 1 	/home/vagrant/go/src/github.com/cilium/cilium/pkg/maps/policymap/policymap.go:419 +0x2e
	 goroutine 1 github.com/cilium/cilium/cilium/cmd.dumpMap({0xc00062b290, 0xc000134008})
	 goroutine 1 	/home/vagrant/go/src/github.com/cilium/cilium/cilium/cmd/bpf_policy_get.go:85 +0x47
	 goroutine 1 github.com/cilium/cilium/cilium/cmd.listAllMaps()
	 goroutine 1 	/home/vagrant/go/src/github.com/cilium/cilium/cilium/cmd/bpf_policy_get.go:68 +0x185
	 goroutine 1 github.com/cilium/cilium/cilium/cmd.glob..func23(0x3ba5ee0, {0xc0002aa930, 0x0, 0x1})
	 goroutine 1 	/home/vagrant/go/src/github.com/cilium/cilium/cilium/cmd/bpf_policy_get.go:41 +0x4b
	 goroutine 1 github.com/spf13/cobra.(*Command).execute(0x3ba5ee0, {0xc0002aa920, 0x1, 0x1})
	 goroutine 1 	/home/vagrant/go/src/github.com/cilium/cilium/vendor/github.com/spf13/cobra/command.go:860 +0x5f8
	 goroutine 1 github.com/spf13/cobra.(*Command).ExecuteC(0x3ba77e0)
	 goroutine 1 	/home/vagrant/go/src/github.com/cilium/cilium/vendor/github.com/spf13/cobra/command.go:974 +0x3bc
	 goroutine 1 github.com/spf13/cobra.(*Command).Execute(...)
	 goroutine 1 	/home/vagrant/go/src/github.com/cilium/cilium/vendor/github.com/spf13/cobra/command.go:902
	 goroutine 1 github.com/cilium/cilium/cilium/cmd.Execute()
	 goroutine 1 	/home/vagrant/go/src/github.com/cilium/cilium/cilium/cmd/root.go:36 +0x25
	 goroutine 1 main.main()
	 goroutine 1 	/home/vagrant/go/src/github.com/cilium/cilium/cilium/main.go:16 +0x17

This doesn't seem likely to be relevant to the PR at all, and is likely just a bug in certain conditions for the in-pod cilium CLI binary.

Metadata

Metadata

Assignees

No one assigned

    Labels

    area/cliImpacts the command line interface of any command in the repository.kind/bugThis is a bug in the Cilium logic.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions