Skip to content

Conversation

@brushknight
Copy link
Contributor

  • Have you followed the guidelines for contributing?
  • Have you ensured that your commits follow the commit style guide?
  • Have you checked that there aren't other open pull requests for the same formula update/change?
  • Have you built your formula locally with brew install --build-from-source <formula>, where <formula> is the name of the formula you're submitting?
  • Is your test running fine brew test <formula>, where <formula> is the name of the formula you're submitting?
  • Does your build pass brew audit --strict <formula> (after doing brew install --build-from-source <formula>)? If this is a new formula, does it pass brew audit --new <formula>?

We notices that there is an issue with one libraries that happens during the runtime. Latest tested version of go is 1.16.7 so we would like to fix it in order to avoid this issues. Once we test [email protected] we will update it in the formula as well.

I am not sure, should we remove bottles. If we should not, let me know and I will update PR.

@BrewTestBot BrewTestBot added the go Go use is a significant feature of the PR or issue label Sep 2, 2021
@carlocab carlocab changed the title Update newrelic-infra-agent.rb - fix [email protected] newrelic-infra-agent: build with [email protected] Sep 2, 2021
@carlocab
Copy link
Member

carlocab commented Sep 2, 2021

What's the issue, and how can it be reproduced?

@brushknight
Copy link
Contributor Author

brushknight commented Sep 2, 2021

To reproduce it you will need to install this formula, sign up on the one.newrelic.com, obtain license key and run newrelic-infra. This is what we got after 15-20sec of runtime. This doesn't happen if we compile with [email protected].

fatal error: unexpected signal during runtime execution
[signal SIGSEGV: segmentation violation code=0x1 addr=0xb01dfacedebac1e pc=0x7fff71e5a70a]

runtime stack:
runtime: unexpected return pc for runtime.sigpanic called from 0x7fff71e5a70a
stack: frame={sp:0x7000072b1e58, fp:0x7000072b1ea8} stack=[0x700007232338,0x7000072b1f38)
0x00007000072b1d58:  0x01007000072b1d78  0x0000000000000004
0x00007000072b1d68:  0x000000000000001f  0x00007fff71e5a70a
0x00007000072b1d78:  0x0b01dfacedebac1e  0x0000000000000001
0x00007000072b1d88:  0x000000000403af91 <runtime.throw+0x0000000000000071>  0x00007000072b1e28
0x00007000072b1d98:  0x000000000489e22b  0x00007000072b1de0
0x00007000072b1da8:  0x000000000403b248 <runtime.fatalthrow.func1+0x0000000000000048>  0x000000c0006821a0
0x00007000072b1db8:  0x0000000000000001  0x0000000000000001
0x00007000072b1dc8:  0x00007000072b1e28  0x000000000403af91 <runtime.throw+0x0000000000000071>
0x00007000072b1dd8:  0x000000c0006821a0  0x00007000072b1e18
0x00007000072b1de8:  0x000000000403b1d0 <runtime.fatalthrow+0x0000000000000050>  0x00007000072b1df8
0x00007000072b1df8:  0x000000000403b200 <runtime.fatalthrow.func1+0x0000000000000000>  0x000000c0006821a0
0x00007000072b1e08:  0x000000000403af91 <runtime.throw+0x0000000000000071>  0x00007000072b1e28
0x00007000072b1e18:  0x00007000072b1e48  0x000000000403af91 <runtime.throw+0x0000000000000071>
0x00007000072b1e28:  0x00007000072b1e30  0x000000000403afc0 <runtime.throw.func1+0x0000000000000000>
0x00007000072b1e38:  0x00000000048ad01d  0x000000000000002a
0x00007000072b1e48:  0x00007000072b1e98  0x00000000040515b6 <runtime.sigpanic+0x0000000000000396>
0x00007000072b1e58: <0x00000000048ad01d  0x000000c000036048
0x00007000072b1e68:  0x00007000072b1ed8  0x000000000402c106 <runtime.(*mheap).allocSpan+0x0000000000000546>
0x00007000072b1e78:  0x000000c000142f68  0x00000000046eb850 <github.com/shirou/gopsutil/disk.PartitionsWithContext+0x0000000000000050>
0x00007000072b1e88:  0x000000c000583ba0  0x0000000000000000
0x00007000072b1e98:  0x00007000072b1ee0 !0x00007fff71e5a70a
0x00007000072b1ea8: >0x00007000072b1ee0  0x0000000004ea4000
0x00007000072b1eb8:  0x0000000000000a95  0x000000000432f245 <golang.org/x/sys/unix.libc_statfs64_trampoline+0x0000000000000005>
0x00007000072b1ec8:  0x000000000407049f <runtime.syscall+0x000000000000001f>  0x000000c000142788
0x00007000072b1ed8:  0x000000000406fe0c <runtime.nanotime_trampoline+0x000000000000000c>  0x000000c000142758
0x00007000072b1ee8:  0x000000000406e2d0 <runtime.asmcgocall+0x0000000000000070>  0x00007000072b1f20
0x00007000072b1ef8:  0x000000000401328e <runtime.persistentalloc.func1+0x000000000000002e>  0x0000000000001018
0x00007000072b1f08:  0x000000c0006821a0  0x0000000004f40e18
0x00007000072b1f18:  0x00000000000018d0  0x000000c000583ba0
0x00007000072b1f28:  0x000000000406c3e9 <runtime.systemstack+0x0000000000000049>  0x00007000072b1f50
runtime.throw({0x48ad01d, 0xc000036048})
	/usr/local/Cellar/go/1.17/libexec/src/runtime/panic.go:1198 +0x71
runtime: unexpected return pc for runtime.sigpanic called from 0x7fff71e5a70a
stack: frame={sp:0x7000072b1e58, fp:0x7000072b1ea8} stack=[0x700007232338,0x7000072b1f38)
0x00007000072b1d58:  0x01007000072b1d78  0x0000000000000004
0x00007000072b1d68:  0x000000000000001f  0x00007fff71e5a70a
0x00007000072b1d78:  0x0b01dfacedebac1e  0x0000000000000001
0x00007000072b1d88:  0x000000000403af91 <runtime.throw+0x0000000000000071>  0x00007000072b1e28
0x00007000072b1d98:  0x000000000489e22b  0x00007000072b1de0
0x00007000072b1da8:  0x000000000403b248 <runtime.fatalthrow.func1+0x0000000000000048>  0x000000c0006821a0
0x00007000072b1db8:  0x0000000000000001  0x0000000000000001
0x00007000072b1dc8:  0x00007000072b1e28  0x000000000403af91 <runtime.throw+0x0000000000000071>
0x00007000072b1dd8:  0x000000c0006821a0  0x00007000072b1e18
0x00007000072b1de8:  0x000000000403b1d0 <runtime.fatalthrow+0x0000000000000050>  0x00007000072b1df8
0x00007000072b1df8:  0x000000000403b200 <runtime.fatalthrow.func1+0x0000000000000000>  0x000000c0006821a0
0x00007000072b1e08:  0x000000000403af91 <runtime.throw+0x0000000000000071>  0x00007000072b1e28
0x00007000072b1e18:  0x00007000072b1e48  0x000000000403af91 <runtime.throw+0x0000000000000071>
0x00007000072b1e28:  0x00007000072b1e30  0x000000000403afc0 <runtime.throw.func1+0x0000000000000000>
0x00007000072b1e38:  0x00000000048ad01d  0x000000000000002a
0x00007000072b1e48:  0x00007000072b1e98  0x00000000040515b6 <runtime.sigpanic+0x0000000000000396>
0x00007000072b1e58: <0x00000000048ad01d  0x000000c000036048
0x00007000072b1e68:  0x00007000072b1ed8  0x000000000402c106 <runtime.(*mheap).allocSpan+0x0000000000000546>
0x00007000072b1e78:  0x000000c000142f68  0x00000000046eb850 <github.com/shirou/gopsutil/disk.PartitionsWithContext+0x0000000000000050>
0x00007000072b1e88:  0x000000c000583ba0  0x0000000000000000
0x00007000072b1e98:  0x00007000072b1ee0 !0x00007fff71e5a70a
0x00007000072b1ea8: >0x00007000072b1ee0  0x0000000004ea4000
0x00007000072b1eb8:  0x0000000000000a95  0x000000000432f245 <golang.org/x/sys/unix.libc_statfs64_trampoline+0x0000000000000005>
0x00007000072b1ec8:  0x000000000407049f <runtime.syscall+0x000000000000001f>  0x000000c000142788
0x00007000072b1ed8:  0x000000000406fe0c <runtime.nanotime_trampoline+0x000000000000000c>  0x000000c000142758
0x00007000072b1ee8:  0x000000000406e2d0 <runtime.asmcgocall+0x0000000000000070>  0x00007000072b1f20
0x00007000072b1ef8:  0x000000000401328e <runtime.persistentalloc.func1+0x000000000000002e>  0x0000000000001018
0x00007000072b1f08:  0x000000c0006821a0  0x0000000004f40e18
0x00007000072b1f18:  0x00000000000018d0  0x000000c000583ba0
0x00007000072b1f28:  0x000000000406c3e9 <runtime.systemstack+0x0000000000000049>  0x00007000072b1f50
runtime.sigpanic()
	/usr/local/Cellar/go/1.17/libexec/src/runtime/signal_unix.go:719 +0x396

goroutine 126 [syscall]:
syscall.syscall(0x432f240, 0xc00079c79c, 0xc000142870, 0x0)
	/usr/local/Cellar/go/1.17/libexec/src/runtime/sys_darwin.go:22 +0x3b fp=0xc000142788 sp=0xc000142768 pc=0x406ae9b
syscall.syscall(0x4ec2498, 0x0, 0x0, 0x0)
	<autogenerated>:1 +0x26 fp=0xc0001427d0 sp=0xc000142788 pc=0x4070ca6
golang.org/x/sys/unix.Statfs({0x4ec2498, 0x0}, 0xc000142870)
	/Users/brew/Library/Caches/Homebrew/go_mod_cache/pkg/mod/golang.org/x/[email protected]/unix/zsyscall_darwin_amd64.go:2487 +0x85 fp=0xc000142820 sp=0xc0001427d0 pc=0x432eee5
github.com/shirou/gopsutil/disk.UsageWithContext({0x1, 0xc0002f8900}, {0x4ec2498, 0x1})
	/Users/brew/Library/Caches/Homebrew/go_mod_cache/pkg/mod/github.com/shirou/[email protected]+incompatible/disk/disk_unix.go:21 +0x6f fp=0xc000143980 sp=0xc000142820 pc=0x46ec2cf
github.com/shirou/gopsutil/disk.Usage(...)
	/Users/brew/Library/Caches/Homebrew/go_mod_cache/pkg/mod/github.com/shirou/[email protected]+incompatible/disk/disk_unix.go:16
github.com/newrelic/infrastructure-agent/pkg/metrics/storage.(*DarwinStorageSampleWrapper).Usage(0xc000143b60, {0x4ec2498, 0xc00054f380})
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/pkg/metrics/storage/storage_sampler_darwin.go:89 +0x35 fp=0xc0001439b0 sp=0xc000143980 pc=0x46ef975
github.com/newrelic/infrastructure-agent/pkg/metrics/storage.(*Sampler).Sample(0xc0003f0a00)
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/pkg/metrics/storage/storage_sampler.go:218 +0xd3c fp=0xc000143ee0 sp=0xc0001439b0 pc=0x46ee39c
github.com/newrelic/infrastructure-agent/pkg/metrics/sampler.StartSamplerRoutine.func1()
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/pkg/metrics/sampler/sampler_routine.go:42 +0x19a fp=0xc000143fe0 sp=0xc000143ee0 pc=0x4677b3a
runtime.goexit()
	/usr/local/Cellar/go/1.17/libexec/src/runtime/asm_amd64.s:1581 +0x1 fp=0xc000143fe8 sp=0xc000143fe0 pc=0x406e5c1
created by github.com/newrelic/infrastructure-agent/pkg/metrics/sampler.StartSamplerRoutine
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/pkg/metrics/sampler/sampler_routine.go:32 +0x173

goroutine 1 [select]:
github.com/newrelic/infrastructure-agent/internal/agent.(*Agent).Run(0xc0003378c0)
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/internal/agent/agent.go:751 +0x8c7
main.initializeAgentAndRun(0xc000794700, {{0x0, {0x0, 0x0}}, {0x0, 0x0}, {0xc0001040c0, 0x52}, {0xc0001b4150, 0x28}, ...})
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/cmd/newrelic-infra/newrelic-infra.go:427 +0x2a14
main.main()
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/cmd/newrelic-infra/newrelic-infra.go:195 +0x8d8

goroutine 50 [chan receive]:
main.main.func2()
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/cmd/newrelic-infra/newrelic-infra.go:122 +0xae
created by main.main
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/cmd/newrelic-infra/newrelic-infra.go:118 +0x2d4

goroutine 52 [syscall]:
os/signal.signal_recv()
	/usr/local/Cellar/go/1.17/libexec/src/runtime/sigqueue.go:166 +0x28
os/signal.loop()
	/usr/local/Cellar/go/1.17/libexec/src/os/signal/signal_unix.go:24 +0x19
created by os/signal.Notify.func1.1
	/usr/local/Cellar/go/1.17/libexec/src/os/signal/signal.go:151 +0x2c

goroutine 76 [sleep]:
time.Sleep(0xdf8475800)
	/usr/local/Cellar/go/1.17/libexec/src/runtime/time.go:193 +0x12e
github.com/newrelic/infrastructure-agent/pkg/sysinfo/cloud.(*Detector).detectRetrying(0xc0002e4910, {0xc0007879c0, 0x4, 0x4})
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/pkg/sysinfo/cloud/cloud.go:228 +0x177
created by github.com/newrelic/infrastructure-agent/pkg/sysinfo/cloud.(*Detector).initialize
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/pkg/sysinfo/cloud/cloud.go:113 +0xf0

goroutine 66 [IO wait]:
internal/poll.runtime_pollWait(0x5728478, 0x72)
	/usr/local/Cellar/go/1.17/libexec/src/runtime/netpoll.go:229 +0x89
internal/poll.(*pollDesc).wait(0xc0003f0380, 0xc0001aca00, 0x0)
	/usr/local/Cellar/go/1.17/libexec/src/internal/poll/fd_poll_runtime.go:84 +0x32
internal/poll.(*pollDesc).waitRead(...)
	/usr/local/Cellar/go/1.17/libexec/src/internal/poll/fd_poll_runtime.go:89
internal/poll.(*FD).Read(0xc0003f0380, {0xc0001aca00, 0x1301, 0x1301})
	/usr/local/Cellar/go/1.17/libexec/src/internal/poll/fd_unix.go:167 +0x25a
net.(*netFD).Read(0xc0003f0380, {0xc0001aca00, 0xc0001aca05, 0x141})
	/usr/local/Cellar/go/1.17/libexec/src/net/fd_posix.go:56 +0x29
net.(*conn).Read(0xc00019a200, {0xc0001aca00, 0x6, 0xc0000777f8})
	/usr/local/Cellar/go/1.17/libexec/src/net/net.go:183 +0x45
crypto/tls.(*atLeastReader).Read(0xc00079f830, {0xc0001aca00, 0x0, 0x400f70d})
	/usr/local/Cellar/go/1.17/libexec/src/crypto/tls/conn.go:777 +0x3d
bytes.(*Buffer).ReadFrom(0xc0004dc978, {0x49f7c20, 0xc00079f830})
	/usr/local/Cellar/go/1.17/libexec/src/bytes/buffer.go:204 +0x98
crypto/tls.(*Conn).readFromUntil(0xc0004dc700, {0x5728560, 0xc00019a200}, 0x1301)
	/usr/local/Cellar/go/1.17/libexec/src/crypto/tls/conn.go:799 +0xe5
crypto/tls.(*Conn).readRecordOrCCS(0xc0004dc700, 0x0)
	/usr/local/Cellar/go/1.17/libexec/src/crypto/tls/conn.go:606 +0x112
crypto/tls.(*Conn).readRecord(...)
	/usr/local/Cellar/go/1.17/libexec/src/crypto/tls/conn.go:574
crypto/tls.(*Conn).Read(0xc0004dc700, {0xc00015b000, 0x1000, 0x1})
	/usr/local/Cellar/go/1.17/libexec/src/crypto/tls/conn.go:1277 +0x16f
net/http.(*persistConn).Read(0xc000147e60, {0xc00015b000, 0x404e4c0, 0xc000077ec8})
	/usr/local/Cellar/go/1.17/libexec/src/net/http/transport.go:1926 +0x4e
bufio.(*Reader).fill(0xc0002d36e0)
	/usr/local/Cellar/go/1.17/libexec/src/bufio/bufio.go:101 +0x103
bufio.(*Reader).Peek(0xc0002d36e0, 0x1)
	/usr/local/Cellar/go/1.17/libexec/src/bufio/bufio.go:139 +0x5d
net/http.(*persistConn).readLoop(0xc000147e60)
	/usr/local/Cellar/go/1.17/libexec/src/net/http/transport.go:2087 +0x1ac
created by net/http.(*Transport).dialConn
	/usr/local/Cellar/go/1.17/libexec/src/net/http/transport.go:1747 +0x1e05

goroutine 67 [select]:
net/http.(*persistConn).writeLoop(0xc000147e60)
	/usr/local/Cellar/go/1.17/libexec/src/net/http/transport.go:2386 +0xfb
created by net/http.(*Transport).dialConn
	/usr/local/Cellar/go/1.17/libexec/src/net/http/transport.go:1748 +0x1e65

goroutine 96 [syscall]:
syscall.syscall6(0x432f140, 0xe, 0x0, 0x0, 0xc0000c9678, 0xa, 0x4f3ce40)
	/usr/local/Cellar/go/1.17/libexec/src/runtime/sys_darwin.go:44 +0x3b
golang.org/x/sys/unix.kevent(0xe, 0x0, 0x0, 0xc0000c9678, 0xa, 0x4f3ce40)
	/Users/brew/Library/Caches/Homebrew/go_mod_cache/pkg/mod/golang.org/x/[email protected]/unix/zsyscall_darwin_amd64.go:292 +0x5b
golang.org/x/sys/unix.Kevent(0x406939b, {0x0, 0x200000003, 0xc0000c9558}, {0xc0000c9678, 0x0, 0xc000582ea0}, 0xc0000c9578)
	/Users/brew/Library/Caches/Homebrew/go_mod_cache/pkg/mod/golang.org/x/[email protected]/unix/syscall_bsd.go:413 +0x3c
github.com/fsnotify/fsnotify.read(0x0, {0xc0000c9678, 0xa, 0xa}, 0x4f3ce40)
	/Users/brew/Library/Caches/Homebrew/go_mod_cache/pkg/mod/github.com/fsnotify/[email protected]/kqueue.go:511 +0x36
github.com/fsnotify/fsnotify.(*Watcher).readEvents(0xc00034b9e0)
	/Users/brew/Library/Caches/Homebrew/go_mod_cache/pkg/mod/github.com/fsnotify/[email protected]/kqueue.go:274 +0xa5
created by github.com/fsnotify/fsnotify.NewWatcher
	/Users/brew/Library/Caches/Homebrew/go_mod_cache/pkg/mod/github.com/fsnotify/[email protected]/kqueue.go:62 +0x1c7

goroutine 94 [IO wait]:
internal/poll.runtime_pollWait(0x57280d8, 0x72)
	/usr/local/Cellar/go/1.17/libexec/src/runtime/netpoll.go:229 +0x89
internal/poll.(*pollDesc).wait(0xc0003f1080, 0xc00034c000, 0x0)
	/usr/local/Cellar/go/1.17/libexec/src/internal/poll/fd_poll_runtime.go:84 +0x32
internal/poll.(*pollDesc).waitRead(...)
	/usr/local/Cellar/go/1.17/libexec/src/internal/poll/fd_poll_runtime.go:89
internal/poll.(*FD).Read(0xc0003f1080, {0xc00034c000, 0x1301, 0x1301})
	/usr/local/Cellar/go/1.17/libexec/src/internal/poll/fd_unix.go:167 +0x25a
net.(*netFD).Read(0xc0003f1080, {0xc00034c000, 0xc00034c005, 0x3d5})
	/usr/local/Cellar/go/1.17/libexec/src/net/fd_posix.go:56 +0x29
net.(*conn).Read(0xc00019a380, {0xc00034c000, 0x15aac78e563a3d85, 0xc00007a7f8})
	/usr/local/Cellar/go/1.17/libexec/src/net/net.go:183 +0x45
crypto/tls.(*atLeastReader).Read(0xc00079ecd8, {0xc00034c000, 0x0, 0x400f70d})
	/usr/local/Cellar/go/1.17/libexec/src/crypto/tls/conn.go:777 +0x3d
bytes.(*Buffer).ReadFrom(0xc0004dd778, {0x49f7c20, 0xc00079ecd8})
	/usr/local/Cellar/go/1.17/libexec/src/bytes/buffer.go:204 +0x98
crypto/tls.(*Conn).readFromUntil(0xc0004dd500, {0x5728560, 0xc00019a380}, 0x0)
	/usr/local/Cellar/go/1.17/libexec/src/crypto/tls/conn.go:799 +0xe5
crypto/tls.(*Conn).readRecordOrCCS(0xc0004dd500, 0x0)
	/usr/local/Cellar/go/1.17/libexec/src/crypto/tls/conn.go:606 +0x112
crypto/tls.(*Conn).readRecord(...)
	/usr/local/Cellar/go/1.17/libexec/src/crypto/tls/conn.go:574
crypto/tls.(*Conn).Read(0xc0004dd500, {0xc00035a000, 0x1000, 0x1})
	/usr/local/Cellar/go/1.17/libexec/src/crypto/tls/conn.go:1277 +0x16f
net/http.(*persistConn).Read(0xc000337d40, {0xc00035a000, 0xc000342cc0, 0xc00007ad30})
	/usr/local/Cellar/go/1.17/libexec/src/net/http/transport.go:1926 +0x4e
bufio.(*Reader).fill(0xc00034b560)
	/usr/local/Cellar/go/1.17/libexec/src/bufio/bufio.go:101 +0x103
bufio.(*Reader).Peek(0xc00034b560, 0x1)
	/usr/local/Cellar/go/1.17/libexec/src/bufio/bufio.go:139 +0x5d
net/http.(*persistConn).readLoop(0xc000337d40)
	/usr/local/Cellar/go/1.17/libexec/src/net/http/transport.go:2087 +0x1ac
created by net/http.(*Transport).dialConn
	/usr/local/Cellar/go/1.17/libexec/src/net/http/transport.go:1747 +0x1e05

goroutine 195 [IO wait]:
internal/poll.runtime_pollWait(0x5727ff0, 0x72)
	/usr/local/Cellar/go/1.17/libexec/src/runtime/netpoll.go:229 +0x89
internal/poll.(*pollDesc).wait(0xc0003f1800, 0xc00034d500, 0x0)
	/usr/local/Cellar/go/1.17/libexec/src/internal/poll/fd_poll_runtime.go:84 +0x32
internal/poll.(*pollDesc).waitRead(...)
	/usr/local/Cellar/go/1.17/libexec/src/internal/poll/fd_poll_runtime.go:89
internal/poll.(*FD).Read(0xc0003f1800, {0xc00034d500, 0x1301, 0x1301})
	/usr/local/Cellar/go/1.17/libexec/src/internal/poll/fd_unix.go:167 +0x25a
net.(*netFD).Read(0xc0003f1800, {0xc00034d500, 0xc00034d505, 0x16c})
	/usr/local/Cellar/go/1.17/libexec/src/net/fd_posix.go:56 +0x29
net.(*conn).Read(0xc00019a020, {0xc00034d500, 0x3492eb3f5ef382b4, 0xc00062f7f8})
	/usr/local/Cellar/go/1.17/libexec/src/net/net.go:183 +0x45
crypto/tls.(*atLeastReader).Read(0xc00000e930, {0xc00034d500, 0x0, 0x400f70d})
	/usr/local/Cellar/go/1.17/libexec/src/crypto/tls/conn.go:777 +0x3d
bytes.(*Buffer).ReadFrom(0xc00060c278, {0x49f7c20, 0xc00000e930})
	/usr/local/Cellar/go/1.17/libexec/src/bytes/buffer.go:204 +0x98
crypto/tls.(*Conn).readFromUntil(0xc00060c000, {0x5728560, 0xc00019a020}, 0x1301)
	/usr/local/Cellar/go/1.17/libexec/src/crypto/tls/conn.go:799 +0xe5
crypto/tls.(*Conn).readRecordOrCCS(0xc00060c000, 0x0)
	/usr/local/Cellar/go/1.17/libexec/src/crypto/tls/conn.go:606 +0x112
crypto/tls.(*Conn).readRecord(...)
	/usr/local/Cellar/go/1.17/libexec/src/crypto/tls/conn.go:574
crypto/tls.(*Conn).Read(0xc00060c000, {0xc00061e000, 0x1000, 0x0})
	/usr/local/Cellar/go/1.17/libexec/src/crypto/tls/conn.go:1277 +0x16f
net/http.(*persistConn).Read(0xc0003667e0, {0xc00061e000, 0xc000104780, 0xc00062fd30})
	/usr/local/Cellar/go/1.17/libexec/src/net/http/transport.go:1926 +0x4e
bufio.(*Reader).fill(0xc00060a720)
	/usr/local/Cellar/go/1.17/libexec/src/bufio/bufio.go:101 +0x103
bufio.(*Reader).Peek(0xc00060a720, 0x1)
	/usr/local/Cellar/go/1.17/libexec/src/bufio/bufio.go:139 +0x5d
net/http.(*persistConn).readLoop(0xc0003667e0)
	/usr/local/Cellar/go/1.17/libexec/src/net/http/transport.go:2087 +0x1ac
created by net/http.(*Transport).dialConn
	/usr/local/Cellar/go/1.17/libexec/src/net/http/transport.go:1747 +0x1e05

goroutine 95 [select]:
net/http.(*persistConn).writeLoop(0xc000337d40)
	/usr/local/Cellar/go/1.17/libexec/src/net/http/transport.go:2386 +0xfb
created by net/http.(*Transport).dialConn
	/usr/local/Cellar/go/1.17/libexec/src/net/http/transport.go:1748 +0x1e65

goroutine 105 [select]:
github.com/newrelic/infrastructure-agent/pkg/integrations/v4.(*Manager).watchForFSChanges(0xc0002e03c0, {0x4a0a390, 0xc000787f40})
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/pkg/integrations/v4/manager.go:361 +0x15e
github.com/newrelic/infrastructure-agent/pkg/integrations/v4.(*Manager).Start(0xc0002e03c0, {0x4a0a390, 0xc000787f40})
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/pkg/integrations/v4/manager.go:260 +0x1c9
created by main.initializeAgentAndRun
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/cmd/newrelic-infra/newrelic-infra.go:402 +0x2525

goroutine 103 [IO wait]:
internal/poll.runtime_pollWait(0x57281c0, 0x72)
	/usr/local/Cellar/go/1.17/libexec/src/runtime/netpoll.go:229 +0x89
internal/poll.(*pollDesc).wait(0xc0003f0080, 0xc000251300, 0x0)
	/usr/local/Cellar/go/1.17/libexec/src/internal/poll/fd_poll_runtime.go:84 +0x32
internal/poll.(*pollDesc).waitRead(...)
	/usr/local/Cellar/go/1.17/libexec/src/internal/poll/fd_poll_runtime.go:89
internal/poll.(*FD).Read(0xc0003f0080, {0xc000251300, 0x1008, 0x1008})
	/usr/local/Cellar/go/1.17/libexec/src/internal/poll/fd_unix.go:167 +0x25a
net.(*netFD).Read(0xc0003f0080, {0xc000251300, 0xc000251305, 0x430})
	/usr/local/Cellar/go/1.17/libexec/src/net/fd_posix.go:56 +0x29
net.(*conn).Read(0xc00019a018, {0xc000251300, 0xb6, 0xc0003877f8})
	/usr/local/Cellar/go/1.17/libexec/src/net/net.go:183 +0x45
crypto/tls.(*atLeastReader).Read(0xc00079e390, {0xc000251300, 0x0, 0x400f70d})
	/usr/local/Cellar/go/1.17/libexec/src/crypto/tls/conn.go:777 +0x3d
bytes.(*Buffer).ReadFrom(0xc0004dd3f8, {0x49f7c20, 0xc00079e390})
	/usr/local/Cellar/go/1.17/libexec/src/bytes/buffer.go:204 +0x98
crypto/tls.(*Conn).readFromUntil(0xc0004dd180, {0x5728560, 0xc00019a018}, 0x1008)
	/usr/local/Cellar/go/1.17/libexec/src/crypto/tls/conn.go:799 +0xe5
crypto/tls.(*Conn).readRecordOrCCS(0xc0004dd180, 0x0)
	/usr/local/Cellar/go/1.17/libexec/src/crypto/tls/conn.go:606 +0x112
crypto/tls.(*Conn).readRecord(...)
	/usr/local/Cellar/go/1.17/libexec/src/crypto/tls/conn.go:574
crypto/tls.(*Conn).Read(0xc0004dd180, {0xc000113000, 0x1000, 0x1})
	/usr/local/Cellar/go/1.17/libexec/src/crypto/tls/conn.go:1277 +0x16f
net/http.(*persistConn).Read(0xc00035c900, {0xc000113000, 0xc000342600, 0xc000387d30})
	/usr/local/Cellar/go/1.17/libexec/src/net/http/transport.go:1926 +0x4e
bufio.(*Reader).fill(0xc000042c00)
	/usr/local/Cellar/go/1.17/libexec/src/bufio/bufio.go:101 +0x103
bufio.(*Reader).Peek(0xc000042c00, 0x1)
	/usr/local/Cellar/go/1.17/libexec/src/bufio/bufio.go:139 +0x5d
net/http.(*persistConn).readLoop(0xc00035c900)
	/usr/local/Cellar/go/1.17/libexec/src/net/http/transport.go:2087 +0x1ac
created by net/http.(*Transport).dialConn
	/usr/local/Cellar/go/1.17/libexec/src/net/http/transport.go:1747 +0x1e05

goroutine 104 [select]:
net/http.(*persistConn).writeLoop(0xc00035c900)
	/usr/local/Cellar/go/1.17/libexec/src/net/http/transport.go:2386 +0xfb
created by net/http.(*Transport).dialConn
	/usr/local/Cellar/go/1.17/libexec/src/net/http/transport.go:1748 +0x1e65

goroutine 106 [select]:
github.com/newrelic/infrastructure-agent/internal/agent/cmdchannel/service.(*srv).Run(0xc0002e5540, {0x4a0a390, 0xc000787f40}, 0xc0003528a0, {{0x42b38b1, 0xc0004dd180, 0x4f0c880}, 0xc00034ba40})
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/internal/agent/cmdchannel/service/service.go:88 +0x176
created by main.initializeAgentAndRun
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/cmd/newrelic-infra/newrelic-infra.go:404 +0x2736

goroutine 107 [select]:
github.com/newrelic/infrastructure-agent/pkg/integrations/v4.(*Manager).handleRequestsQueue(0xc0002e03c0, {0x4a0a390, 0xc000787f40})
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/pkg/integrations/v4/manager.go:322 +0x16d
created by github.com/newrelic/infrastructure-agent/pkg/integrations/v4.(*Manager).Start
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/pkg/integrations/v4/manager.go:258 +0x1af

goroutine 108 [chan receive]:
github.com/newrelic/infrastructure-agent/pkg/ctl.handleSignals(0x470920e, 0xc0002e03c0, {0x4a046c8, 0x4f3cc20})
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/pkg/ctl/notification_handler_unix.go:110 +0xfa
created by github.com/newrelic/infrastructure-agent/pkg/ctl.NotificationHandler
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/pkg/ctl/notification_handler_unix.go:56 +0x11b

goroutine 109 [select]:
github.com/newrelic/infrastructure-agent/pkg/ctl.NotificationHandler.func1()
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/pkg/ctl/notification_handler_unix.go:60 +0xb4
created by github.com/newrelic/infrastructure-agent/pkg/ctl.NotificationHandler
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/pkg/ctl/notification_handler_unix.go:58 +0x196

goroutine 111 [chan receive]:
github.com/newrelic/infrastructure-agent/internal/agent.(*Agent).connect(0xc0003378c0)
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/internal/agent/agent.go:1143 +0xb1
created by github.com/newrelic/infrastructure-agent/internal/agent.(*Agent).Run
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/internal/agent/agent.go:669 +0x1af

goroutine 196 [select]:
net/http.(*persistConn).writeLoop(0xc0003667e0)
	/usr/local/Cellar/go/1.17/libexec/src/net/http/transport.go:2386 +0xfb
created by net/http.(*Transport).dialConn
	/usr/local/Cellar/go/1.17/libexec/src/net/http/transport.go:1748 +0x1e65

goroutine 113 [chan receive]:
github.com/newrelic/infrastructure-agent/pkg/plugins.(*HostAliasesPlugin).Run(0xc00051b4a0)
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/pkg/plugins/host_aliases.go:115 +0x51
created by github.com/newrelic/infrastructure-agent/internal/agent.(*Agent).startPlugins.func1
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/internal/agent/agent.go:602 +0x70

goroutine 125 [runnable]:
github.com/newrelic/infrastructure-agent/pkg/metrics/sampler.StartSamplerRoutine.func1()
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/pkg/metrics/sampler/sampler_routine.go:40 +0x165
created by github.com/newrelic/infrastructure-agent/pkg/metrics/sampler.StartSamplerRoutine
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/pkg/metrics/sampler/sampler_routine.go:32 +0x173

goroutine 139 [select]:
net/http.(*persistConn).writeLoop(0xc00007fd40)
	/usr/local/Cellar/go/1.17/libexec/src/net/http/transport.go:2386 +0xfb
created by net/http.(*Transport).dialConn
	/usr/local/Cellar/go/1.17/libexec/src/net/http/transport.go:1748 +0x1e65

goroutine 117 [select]:
github.com/newrelic/infrastructure-agent/internal/agent.(*metricsIngestSender).accumulateBatches(0xc000144fc0)
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/internal/agent/event_sender.go:216 +0x125
github.com/newrelic/infrastructure-agent/internal/agent.(*metricsIngestSender).Start.func1()
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/internal/agent/event_sender.go:145 +0x58
created by github.com/newrelic/infrastructure-agent/internal/agent.(*metricsIngestSender).Start
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/internal/agent/event_sender.go:143 +0xaf

goroutine 118 [select]:
github.com/newrelic/infrastructure-agent/internal/agent.(*metricsIngestSender).sendBatches(0xc000144fc0)
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/internal/agent/event_sender.go:320 +0xf8
github.com/newrelic/infrastructure-agent/internal/agent.(*metricsIngestSender).Start.func2()
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/internal/agent/event_sender.go:150 +0x58
created by github.com/newrelic/infrastructure-agent/internal/agent.(*metricsIngestSender).Start
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/internal/agent/event_sender.go:148 +0xf1

goroutine 119 [select]:
github.com/newrelic/infrastructure-agent/pkg/metrics/sender.(*Sender).scheduleSamplers(0xc0001c0b80)
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/pkg/metrics/sender/sender.go:94 +0xe5
github.com/newrelic/infrastructure-agent/pkg/metrics/sender.(*Sender).Start.func1()
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/pkg/metrics/sender/sender.go:62 +0x35
created by github.com/newrelic/infrastructure-agent/pkg/metrics/sender.(*Sender).Start
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/pkg/metrics/sender/sender.go:60 +0x9d

goroutine 120 [chan receive]:
github.com/newrelic/infrastructure-agent/internal/agent.(*Agent).Run.func1()
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/internal/agent/agent.go:733 +0x5d
created by github.com/newrelic/infrastructure-agent/internal/agent.(*Agent).Run
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/internal/agent/agent.go:732 +0x779

goroutine 127 [runnable]:
github.com/newrelic/infrastructure-agent/pkg/metrics/sampler.StartSamplerRoutine.func1()
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/pkg/metrics/sampler/sampler_routine.go:40 +0x165
created by github.com/newrelic/infrastructure-agent/pkg/metrics/sampler.StartSamplerRoutine
	/private/tmp/newrelic-infra-agent-20210901-43079-dns9wi/infrastructure-agent-1.20.2/pkg/metrics/sampler/sampler_routine.go:32 +0x173

goroutine 138 [IO wait]:
internal/poll.runtime_pollWait(0x57282a8, 0x72)
	/usr/local/Cellar/go/1.17/libexec/src/runtime/netpoll.go:229 +0x89
internal/poll.(*pollDesc).wait(0xc0000bb200, 0xc000253900, 0x0)
	/usr/local/Cellar/go/1.17/libexec/src/internal/poll/fd_poll_runtime.go:84 +0x32
internal/poll.(*pollDesc).waitRead(...)
	/usr/local/Cellar/go/1.17/libexec/src/internal/poll/fd_poll_runtime.go:89
internal/poll.(*FD).Read(0xc0000bb200, {0xc000253900, 0x1008, 0x1008})
	/usr/local/Cellar/go/1.17/libexec/src/internal/poll/fd_unix.go:167 +0x25a
net.(*netFD).Read(0xc0000bb200, {0xc000253900, 0xff, 0xc000385778})
	/usr/local/Cellar/go/1.17/libexec/src/net/fd_posix.go:56 +0x29
net.(*conn).Read(0xc00019a430, {0xc000253900, 0x6, 0xc0003857f8})
	/usr/local/Cellar/go/1.17/libexec/src/net/net.go:183 +0x45
crypto/tls.(*atLeastReader).Read(0xc0001977e8, {0xc000253900, 0x0, 0x400f70d})
	/usr/local/Cellar/go/1.17/libexec/src/crypto/tls/conn.go:777 +0x3d
bytes.(*Buffer).ReadFrom(0xc00018f3f8, {0x49f7c20, 0xc0001977e8})
	/usr/local/Cellar/go/1.17/libexec/src/bytes/buffer.go:204 +0x98
crypto/tls.(*Conn).readFromUntil(0xc00018f180, {0x5728560, 0xc00019a430}, 0x1008)
	/usr/local/Cellar/go/1.17/libexec/src/crypto/tls/conn.go:799 +0xe5
crypto/tls.(*Conn).readRecordOrCCS(0xc00018f180, 0x0)
	/usr/local/Cellar/go/1.17/libexec/src/crypto/tls/conn.go:606 +0x112
crypto/tls.(*Conn).readRecord(...)
	/usr/local/Cellar/go/1.17/libexec/src/crypto/tls/conn.go:574
crypto/tls.(*Conn).Read(0xc00018f180, {0xc000179000, 0x1000, 0x1})
	/usr/local/Cellar/go/1.17/libexec/src/crypto/tls/conn.go:1277 +0x16f
net/http.(*persistConn).Read(0xc00007fd40, {0xc000179000, 0xc000343aa0, 0xc000385d30})
	/usr/local/Cellar/go/1.17/libexec/src/net/http/transport.go:1926 +0x4e
bufio.(*Reader).fill(0xc000541e00)
	/usr/local/Cellar/go/1.17/libexec/src/bufio/bufio.go:101 +0x103
bufio.(*Reader).Peek(0xc000541e00, 0x1)
	/usr/local/Cellar/go/1.17/libexec/src/bufio/bufio.go:139 +0x5d
net/http.(*persistConn).readLoop(0xc00007fd40)
	/usr/local/Cellar/go/1.17/libexec/src/net/http/transport.go:2087 +0x1ac
created by net/http.(*Transport).dialConn
	/usr/local/Cellar/go/1.17/libexec/src/net/http/transport.go:1747 +0x1e05

@dimabru dimabru mentioned this pull request Sep 2, 2021
6 tasks
@chenrui333
Copy link
Member

it is the x/sys call issue, let me file a fix PR rather than using [email protected]

@chenrui333
Copy link
Member

Should be good after merging this PR

@chenrui333
Copy link
Member

There are some CI issues with this PR

@BrewTestBot BrewTestBot added the no ARM bottle Formula has no ARM bottle label Sep 14, 2021
@branchv
Copy link
Member

branchv commented Sep 14, 2021

looks like the x/sys bump was not enough, so unfortunately [email protected] is necessary. created a tracking issue at newrelic/infrastructure-agent#723. since this is currently broken for users, I'm approving

@brushknight sorry for the long delay here and thanks for raising this issue. note, I also fixed the git hash missing from newrelic-infra -version

Copy link
Member

@branchv branchv left a comment

Choose a reason for hiding this comment

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

thanks again @brushknight

@BrewTestBot
Copy link
Contributor

🤖 A scheduled task has triggered a merge.

@branchv branchv mentioned this pull request Sep 14, 2021
@github-actions github-actions bot added the outdated PR was locked due to age label Oct 15, 2021
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Oct 15, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

go Go use is a significant feature of the PR or issue no ARM bottle Formula has no ARM bottle outdated PR was locked due to age

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants