ebpf_exporter
ebpf_exporter copied to clipboard
terminate called after throwing an instance of 'std::bad_function_call'
OS: centos 4.11.1-1.el7.elrepo.x86_64
./ebpf_exporter-1.2.2/ebpf_exporter --config.file=/usr/tmp/bio-tracepoints.yaml
2021/11/29 16:28:07 Starting with 1 programs found in the config 2021/11/29 16:28:07 Listening on :9435 terminate called after throwing an instance of 'std::bad_function_call' what(): bad_function_call SIGABRT: abort PC=0x7f5a7649a337 m=3 sigcode=18446744073709551610
goroutine 0 [idle]: runtime: unknown pc 0x7f5a7649a337
Getting a similar crash when clicking metrics from the web page after starting the exporter:
2022/02/01 09:57:41 Starting with 1 programs found in the config
2022/02/01 09:57:41 Listening on :9435
Then I clicked metrics:
terminate called after throwing an instance of 'std::bad_function_call'
what(): bad_function_call
SIGABRT: abort
PC=0x7fbf2112b387 m=0 sigcode=18446744073709551610
goroutine 0 [idle]:
runtime: unknown pc 0x7fbf2112b387
stack: frame={sp:0x7ffed0541fd8, fp:0x0} stack=[0x7ffecfd43260,0x7ffed05422a0)
Full crash details are attached: ebpf_exporter_crash.txt. It seems to crash with whatever config file taken from the /examples directory.
Setting up core dump gives:
[signal SIGSEGV: segmentation violation code=0x1 addr=0x50 pc=0x7804ae]
goroutine 1 [running]:
debug/elf.(*Prog).Open(...)
/usr/lib/golang/src/debug/elf/file.go:166
github.com/go-delve/delve/pkg/proc/core.readNotes(0x7fffa7c82721, 0xf2c7)
/root/delve/pkg/proc/core/linux_core.go:228 +0x4e
github.com/go-delve/delve/pkg/proc/core.readLinuxOrPlatformIndependentCore({0x7fffa7c82721, 0xa3ae80}, {0x7fffa7c826f3, 0x2d})
/root/delve/pkg/proc/core/linux_core.go:110 +0x134
github.com/go-delve/delve/pkg/proc/core.OpenCore({0x7fffa7c82721, 0x3f}, {0x7fffa7c826f3, 0x2d}, {0xc000118c50, 0x1, 0x1})
/root/delve/pkg/proc/core/core.go:210 +0x13c
github.com/go-delve/delve/service/debugger.New(0xc0002aa000, {0xc000118de0, 0x1, 0x1})
/root/delve/service/debugger/debugger.go:176 +0x345
github.com/go-delve/delve/service/rpccommon.(*ServerImpl).Run(0xc0001167e0)
/root/delve/service/rpccommon/server.go:122 +0xd6
github.com/go-delve/delve/cmd/dlv/cmds.execute(0x0, {0xc000118de0, 0x1, 0x1}, 0xc000124ea0, {0x7fffa7c82721, 0x3f}, 0x3, {0xc00011a7e0, 0x2, ...}, ...)
/root/delve/cmd/dlv/cmds/commands.go:971 +0xc7f
github.com/go-delve/delve/cmd/dlv/cmds.coreCmd(0xc0002a4780, {0xc00011a7e0, 0x2, 0x2})
/root/delve/cmd/dlv/cmds/commands.go:775 +0xdb
github.com/spf13/cobra.(*Command).execute(0xc0002a4780, {0xc00011a780, 0x2, 0x2})
/root/delve/vendor/github.com/spf13/cobra/command.go:856 +0x5f8
github.com/spf13/cobra.(*Command).ExecuteC(0xc000140f00)
/root/delve/vendor/github.com/spf13/cobra/command.go:960 +0x3ad
github.com/spf13/cobra.(*Command).Execute(...)
/root/delve/vendor/github.com/spf13/cobra/command.go:897
main.main()
/root/delve/cmd/dlv/main.
go:24 +0x18a
Dump file is attached: core.ebpf_exporter.1679.centos2009.zip
Solved by building bcc from source and copying /usr/lib64/libbcc* binaries to the problematic machine.