We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
CompactStorage at the start of the agent can make the agent panic when walking the storeage dir:
time="2020-09-08T19:01:28+02:00" level=fatal msg="runtime error: invalid memory address or nil pointer dereference" stacktrace="goroutine 1 [running]:\nruntime/debug.Stack(0xc0000c46a8, 0xce59c0, 0x15ce320) /usr/local/go/src/runtime/debug/stack.go:24 +0x9d\ngithub.com/newrelic/infrastructure-agent/pkg/helpers/recover.PanicHandler(0x0) /go/src/github.com/newrelic/infrastructure-agent/pkg/helpers/recover/recover.go:30 +0x51\npanic(0xce59c0, 0x15ce320) /usr/local/go/src/runtime/panic.go:975 +0x3e3\ngithub.com/newrelic/infrastructure-agent/internal/agent/delta.(*Store).StorageSize.func1(0xc02a265000, 0x7c, 0x0, 0x0, 0x1031c20, 0xc0239a69f0, 0x0, 0x0) /go/src/github.com/newrelic/infrastructure-agent/internal/agent/delta/store.go:272 +0x2b\npath/filepath.walk(0xc02a26c620, 0x62, 0x1049b40, 0xc02a2781a0, 0xc0000c4b00, 0x0, 0x0) /usr/local/go/src/path/filepath/path.go:380 +0x20c\npath/filepath.walk(0xc028524780, 0x33, 0x1049b40, 0xc02807e820, 0xc0000c4b00, 0x0, 0x0) /usr/local/go/src/path/filepath/path.go:384 +0x2ff\npath/filepath.walk(0xc000799aa0, 0x27, 0x1049b40, 0xc02807e270, 0xc0000c4b00, 0x0, 0xc022105ae0) /usr/local/go/src/path/filepath/path.go:384 +0x2ff\npath/filepath.Walk(0xc000799aa0, 0x27, 0xc0000c4b00, 0xc0000c4b08, 0xc000ceaf30) /usr/local/go/src/path/filepath/path.go:406 +0xff\ngithub.com/newrelic/infrastructure-agent/internal/agent/delta.(*Store).StorageSize(0xc00047d020, 0xc000799aa0, 0x27, 0xc00417e840, 0xc01c7b9740, 0xc0000c4abd) /go/src/github.com/newrelic/infrastructure-agent/internal/agent/delta/store.go:271 +0x66\ngithub.com/newrelic/infrastructure-agent/internal/agent/delta.(*Store).CompactStorage(0xc00047d020, 0xc000ceaf30, 0x2f, 0x1400000, 0x0, 0x0) /go/src/github.com/newrelic/infrastructure-agent/internal/agent/delta/store.go:243 +0x41\ngithub.com/newrelic/infrastructure-agent/internal/agent.(*patchSenderIngest).Process(0xc00417e840, 0x0, 0x0) /go/src/github.com/newrelic/infrastructure-agent/internal/agent/patch_sender.go:162 +0x50f\ngithub.com/newrelic/infrastructure-agent/internal/agent.(*Agent).sendInventory(0xc000184800, 0xc00016ceb0) /go/src/github.com/newrelic/infrastructure-agent/internal/agent/agent.go:942 +0xbe\ngithub.com/newrelic/infrastructure-agent/internal/agent.(*Agent).Run(0xc000184800, 0x0, 0x0) /go/src/github.com/newrelic/infrastructure-agent/internal/agent/agent.go:920 +0x9f1\nmain.initializeAgentAndRun(0xc000426300, 0x0, 0xc000470150, 0x2a, 0xc0004b83c0, 0x1d, 0xc0001edc80, 0x34, 0xc0004700f0, 0x28, ...) /go/src/github.com/newrelic/infrastructure-agent/cmd/newrelic-infra/newrelic-infra.go:323 +0x1cb7\nmain.main() /go/src/github.com/newrelic/infrastructure-agent/cmd/newrelic-infra/newrelic-infra.go:165 +0x80b\n"
The text was updated successfully, but these errors were encountered:
fix(agent): fixes panic when compacting storage (#102)
44767ca
fixes #101
Fixed at #102
Sorry, something went wrong.
Successfully merging a pull request may close this issue.
CompactStorage at the start of the agent can make the agent panic when walking the storeage dir:
time="2020-09-08T19:01:28+02:00" level=fatal msg="runtime error: invalid memory address or nil pointer dereference" stacktrace="goroutine 1 [running]:\nruntime/debug.Stack(0xc0000c46a8, 0xce59c0, 0x15ce320) /usr/local/go/src/runtime/debug/stack.go:24 +0x9d\ngithub.com/newrelic/infrastructure-agent/pkg/helpers/recover.PanicHandler(0x0) /go/src/github.com/newrelic/infrastructure-agent/pkg/helpers/recover/recover.go:30 +0x51\npanic(0xce59c0, 0x15ce320) /usr/local/go/src/runtime/panic.go:975 +0x3e3\ngithub.com/newrelic/infrastructure-agent/internal/agent/delta.(*Store).StorageSize.func1(0xc02a265000, 0x7c, 0x0, 0x0, 0x1031c20, 0xc0239a69f0, 0x0, 0x0) /go/src/github.com/newrelic/infrastructure-agent/internal/agent/delta/store.go:272 +0x2b\npath/filepath.walk(0xc02a26c620, 0x62, 0x1049b40, 0xc02a2781a0, 0xc0000c4b00, 0x0, 0x0) /usr/local/go/src/path/filepath/path.go:380 +0x20c\npath/filepath.walk(0xc028524780, 0x33, 0x1049b40, 0xc02807e820, 0xc0000c4b00, 0x0, 0x0) /usr/local/go/src/path/filepath/path.go:384 +0x2ff\npath/filepath.walk(0xc000799aa0, 0x27, 0x1049b40, 0xc02807e270, 0xc0000c4b00, 0x0, 0xc022105ae0) /usr/local/go/src/path/filepath/path.go:384 +0x2ff\npath/filepath.Walk(0xc000799aa0, 0x27, 0xc0000c4b00, 0xc0000c4b08, 0xc000ceaf30) /usr/local/go/src/path/filepath/path.go:406 +0xff\ngithub.com/newrelic/infrastructure-agent/internal/agent/delta.(*Store).StorageSize(0xc00047d020, 0xc000799aa0, 0x27, 0xc00417e840, 0xc01c7b9740, 0xc0000c4abd) /go/src/github.com/newrelic/infrastructure-agent/internal/agent/delta/store.go:271 +0x66\ngithub.com/newrelic/infrastructure-agent/internal/agent/delta.(*Store).CompactStorage(0xc00047d020, 0xc000ceaf30, 0x2f, 0x1400000, 0x0, 0x0) /go/src/github.com/newrelic/infrastructure-agent/internal/agent/delta/store.go:243 +0x41\ngithub.com/newrelic/infrastructure-agent/internal/agent.(*patchSenderIngest).Process(0xc00417e840, 0x0, 0x0) /go/src/github.com/newrelic/infrastructure-agent/internal/agent/patch_sender.go:162 +0x50f\ngithub.com/newrelic/infrastructure-agent/internal/agent.(*Agent).sendInventory(0xc000184800, 0xc00016ceb0) /go/src/github.com/newrelic/infrastructure-agent/internal/agent/agent.go:942 +0xbe\ngithub.com/newrelic/infrastructure-agent/internal/agent.(*Agent).Run(0xc000184800, 0x0, 0x0) /go/src/github.com/newrelic/infrastructure-agent/internal/agent/agent.go:920 +0x9f1\nmain.initializeAgentAndRun(0xc000426300, 0x0, 0xc000470150, 0x2a, 0xc0004b83c0, 0x1d, 0xc0001edc80, 0x34, 0xc0004700f0, 0x28, ...) /go/src/github.com/newrelic/infrastructure-agent/cmd/newrelic-infra/newrelic-infra.go:323 +0x1cb7\nmain.main() /go/src/github.com/newrelic/infrastructure-agent/cmd/newrelic-infra/newrelic-infra.go:165 +0x80b\n"
The text was updated successfully, but these errors were encountered: