Skip to content
New issue

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

panic in portallocator when updating service #1480

Closed
allencloud opened this issue Sep 1, 2016 · 0 comments · Fixed by #1481
Closed

panic in portallocator when updating service #1480

allencloud opened this issue Sep 1, 2016 · 0 comments · Fixed by #1481

Comments

@allencloud
Copy link
Contributor

allencloud commented Sep 1, 2016

Hi, All,

When I was updating service, panic happened in docker engine's log, like below:

time="2016-09-01T12:03:35.697250351+08:00" level=error msg="Handler for GET /v1.24/services/dy7yajeu246ztckluq367wvfo returned error: service dy7yajeu246ztckluq367wvfo not found" 
time="2016-09-01T12:03:55.532280461+08:00" level=error msg="Error updating service adnfj9n8um05: rpc error: code = 5 desc = service adnfj9n8um05 not found" 
time="2016-09-01T12:03:55.532477499+08:00" level=error msg="Handler for POST /v1.24/services/adnfj9n8um05/update returned error: rpc error: code = 5 desc = service adnfj9n8um05 not found" 
panic: runtime error: invalid memory address or nil pointer dereference
[signal 0xb code=0x1 addr=0x10 pc=0x14b2dcc]

goroutine 264 [running]:
panic(0x1a619a0, 0xc820010070)
    /usr/local/go/src/runtime/panic.go:481 +0x3e6
github.com/docker/swarmkit/manager/allocator/networkallocator.(*portAllocator).isPortsAllocated(0xc82001e278, 0xc82170b500, 0xc820811880)
    /usr/src/docker/vendor/src/github.com/docker/swarmkit/manager/allocator/networkallocator/portallocator.go:164 +0x4c
github.com/docker/swarmkit/manager/allocator/networkallocator.(*NetworkAllocator).IsServiceAllocated(0xc82075cd50, 0xc82170b500, 0xc82175ac20)
    /usr/src/docker/vendor/src/github.com/docker/swarmkit/manager/allocator/networkallocator/networkallocator.go:309 +0xeb
github.com/docker/swarmkit/manager/allocator.(*Allocator).doNetworkAlloc(0xc82075c2a0, 0x7f861aed9a38, 0xc8201835c0, 0x1b1c4c0, 0xc82175ac20)
    /usr/src/docker/vendor/src/github.com/docker/swarmkit/manager/allocator/network.go:318 +0x369
github.com/docker/swarmkit/manager/allocator.(*Allocator).(github.com/docker/swarmkit/manager/allocator.doNetworkAlloc)-fm(0x7f861aed9a38, 0xc8201835c0, 0x1b1c4c0, 0xc82175ac20)
    /usr/src/docker/vendor/src/github.com/docker/swarmkit/manager/allocator/allocator.go:117 +0x48
github.com/docker/swarmkit/manager/allocator.(*Allocator).run(0xc82075c2a0, 0x7f861aed9a38, 0xc8201835c0, 0xc82075a000, 0xc82075cc00, 0x1d44b28, 0x7, 0xc8208a1680, 0xc8208a1670)
    /usr/src/docker/vendor/src/github.com/docker/swarmkit/manager/allocator/allocator.go:175 +0x118
github.com/docker/swarmkit/manager/allocator.(*Allocator).Run.func2.1(0xc8208a1600, 0xc82075c2a0, 0xc8208a15e0, 0xc82075a000, 0xc82075cc00, 0x1d44b28, 0x7, 0xc8208a1680, 0xc8208a1670)
    /usr/src/docker/vendor/src/github.com/docker/swarmkit/manager/allocator/allocator.go:142 +0xa9
created by github.com/docker/swarmkit/manager/allocator.(*Allocator).Run.func2
    /usr/src/docker/vendor/src/github.com/docker/swarmkit/manager/allocator/allocator.go:143 +0x13c

It leads to the restart of engine. In some case, it brings severe consequence.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants