Description
The failure occurred in a shared library (go build -buildmode=c-shared
) that is loaded as a ulogd plugin. So, obviously, go is not in complete control of its runtime situation. Still, I believe this stack trace represents an issue with the embedded go runtime and not the host application.
Please answer these questions before submitting your issue. Thanks!
What version of Go are you using (go version
)?
go version go1.6 linux/amd64
What operating system and processor architecture are you using (go env
)?
GOARCH="amd64"
GOBIN=""
GOEXE=""
GOHOSTARCH="amd64"
GOHOSTOS="linux"
GOOS="linux"
GOPATH=""
GORACE=""
GOROOT="/usr/lib/go-1.6"
GOTOOLDIR="/usr/lib/go-1.6/pkg/tool/linux_amd64"
GO15VENDOREXPERIMENT="1"
CC="gcc"
GOGCCFLAGS="-fPIC -m64 -pthread -fmessage-length=0"
CXX="g++"
CGO_ENABLED="1"
What did you do?
If possible, provide a recipe for reproducing the error.
I may be able to obtain clearance from my employer to share binary code and/or source for the application in which this panic appeared. I don't yet have such clearance.
At a high level, this is a shared library that is compiled against Linux ulogd sources (http://www.netfilter.org/projects/ulogd/) to produce a plugin for the ulogd host app. The plugin receives callbacks from the host application and composes log messages sent through dropsonde (https://github.com/cloudfoundry/dropsonde) to be collected via Cloud Foundry's Loggregator services.
Because the panic stack trace does not refer to any code outside of the Go runtime, it is difficult for me to see which allocation provoked the allocator failure.
A complete runnable program is good.
A link on play.golang.org is best.
What did you expect to see?
normally (in thousands of instances of restarting the host application that is loading the go shared library) the app runs fine. The stack trace comes from exactly once-ever-witnessed failure of this kind.
What did you see instead?
stack trace follows:
------------ STARTING connection-logger_ctl at Tue Aug 30 15:38:29 UTC 2016 --------------
[... elided irrelevant log prefix ...]
runtime: address space conflict: map(0xc820000000) = 0x7f4db163c000
fatal error: runtime: address space conflict
2016/08/30 15:38:31 init() for diego
runtime stack:
runtime.throw(0x7f4daf389da0, 0x1f)
/usr/lib/go-1.6/src/runtime/panic.go:530 +0x92 fp=0x7f4dae86d9e0 sp=0x7f4dae86d9c8
runtime.sysMap(0xc820000000, 0x100000, 0x6600, 0x7f4daf57f778)
/usr/lib/go-1.6/src/runtime/mem_linux.go:210 +0x13a fp=0x7f4dae86da20 sp=0x7f4dae86d9e0
runtime.(*mheap).sysAlloc(0x7f4daf565a60, 0x100000, 0x0)
/usr/lib/go-1.6/src/runtime/malloc.go:429 +0x193 fp=0x7f4dae86daa8 sp=0x7f4dae86da20
runtime.(*mheap).grow(0x7f4daf565a60, 0x8, 0x0)
/usr/lib/go-1.6/src/runtime/mheap.go:651 +0x65 fp=0x7f4dae86db00 sp=0x7f4dae86daa8
runtime.(*mheap).allocSpanLocked(0x7f4daf565a60, 0x1, 0x0)
/usr/lib/go-1.6/src/runtime/mheap.go:553 +0x4f8 fp=0x7f4dae86db58 sp=0x7f4dae86db00
runtime.(*mheap).alloc_m(0x7f4daf565a60, 0x1, 0x15, 0x7f4db174c000)
/usr/lib/go-1.6/src/runtime/mheap.go:437 +0x11d fp=0x7f4dae86db88 sp=0x7f4dae86db58
runtime.(*mheap).alloc.func1()
/usr/lib/go-1.6/src/runtime/mheap.go:502 +0x43 fp=0x7f4dae86dbb8 sp=0x7f4dae86db88
runtime.systemstack(0x7f4dae86dbd8)
/usr/lib/go-1.6/src/runtime/asm_amd64.s:307 +0xa1 fp=0x7f4dae86dbc0 sp=0x7f4dae86dbb8
runtime.(*mheap).alloc(0x7f4daf565a60, 0x1, 0x10000000015, 0x7f4daebdcc38)
/usr/lib/go-1.6/src/runtime/mheap.go:503 +0x65 fp=0x7f4dae86dc08 sp=0x7f4dae86dbc0
runtime.(*mcentral).grow(0x7f4daf567660, 0x0)
/usr/lib/go-1.6/src/runtime/mcentral.go:209 +0x95 fp=0x7f4dae86dc70 sp=0x7f4dae86dc08
runtime.(*mcentral).cacheSpan(0x7f4daf567660, 0x7f4daf5604c8)
/usr/lib/go-1.6/src/runtime/mcentral.go:89 +0x47f fp=0x7f4dae86dcb0 sp=0x7f4dae86dc70
runtime.(*mcache).refill(0x7f4db174c000, 0x7f4d00000015, 0x7f4dae86dd18)
/usr/lib/go-1.6/src/runtime/mcache.go:119 +0xd0 fp=0x7f4dae86dce8 sp=0x7f4dae86dcb0
runtime.mallocgc.func2()
/usr/lib/go-1.6/src/runtime/malloc.go:642 +0x2d fp=0x7f4dae86dd08 sp=0x7f4dae86dce8
runtime.systemstack(0x7f4dae86dda8)
/usr/lib/go-1.6/src/runtime/asm_amd64.s:307 +0xa1 fp=0x7f4dae86dd10 sp=0x7f4dae86dd08
runtime.mallocgc(0x180, 0x7f4daf310da0, 0x0, 0x800000000)
/usr/lib/go-1.6/src/runtime/malloc.go:643 +0x87c fp=0x7f4dae86dde8 sp=0x7f4dae86dd10
runtime.newobject(0x7f4daf310da0, 0x7f4daf560990)
/usr/lib/go-1.6/src/runtime/malloc.go:781 +0x44 fp=0x7f4dae86de10 sp=0x7f4dae86dde8
runtime.malg(0x7f4d00008000, 0x7f4daf560d40)
/usr/lib/go-1.6/src/runtime/proc.go:2634 +0x29 fp=0x7f4dae86de48 sp=0x7f4dae86de10
runtime.mpreinit(0x7f4daf5612e0)
/usr/lib/go-1.6/src/runtime/os1_linux.go:205 +0x21 fp=0x7f4dae86de60 sp=0x7f4dae86de48
runtime.mcommoninit(0x7f4daf5612e0)
/usr/lib/go-1.6/src/runtime/proc.go:494 +0x109 fp=0x7f4dae86dea8 sp=0x7f4dae86de60
runtime.schedinit()
/usr/lib/go-1.6/src/runtime/proc.go:434 +0x7d fp=0x7f4dae86def0 sp=0x7f4dae86dea8
runtime.rt0_go(0x7fff1f836a58, 0x7, 0x7fff1f836a58, 0x7f4dae86e700, 0x7f4db13a1184, 0x0, 0x7f4dae86e700, 0x7f4dae86e700, 0xa48c0a2111c02ce0, 0x0, ...)
/usr/lib/go-1.6/src/runtime/asm_amd64.s:138 +0x134 fp=0x7f4dae86def8 sp=0x7f4dae86def0