syzbot


panic: Decrementing non-positive ref count

Status: fixed on 2018/12/12 09:36
Fix commit: 0e277a39c8b6 Prevent premature destruction of shm segments.
First crash: 2349d, last: 2271d
Similar bugs (1)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
gvisor panic: Decrementing non-positive ref count (2) 1 1489d 1482d 0/26 auto-closed as invalid on 2021/01/26 23:28

Sample crash report:
panic: Decrementing non-positive ref count

goroutine 30 [running]:
gvisor.googlesource.com/gvisor/pkg/refs.(*AtomicRefCount).DecRefWithDestructor(0xc4203de0c0, 0xc42038bd58)
	pkg/refs/refcounter.go:267 +0x162
gvisor.googlesource.com/gvisor/pkg/sentry/kernel/shm.(*Shm).DecRef(0xc4203de0c0)
	pkg/sentry/kernel/shm/shm.go:373 +0x48
gvisor.googlesource.com/gvisor/pkg/sentry/mm.(*MemoryManager).removeVMAsLocked(0xc42043cc80, 0xc75c20, 0xc42047a5a0, 0x10000, 0x7fffffff0000, 0x67af1d, 0xc42038be48)
	pkg/sentry/mm/vma.go:338 +0x1a4
gvisor.googlesource.com/gvisor/pkg/sentry/mm.(*MemoryManager).unmapLocked(0xc42043cc80, 0xc75c20, 0xc42047a5a0, 0x10000, 0x7fffffff0000, 0x18, 0x0)
	pkg/sentry/mm/vma.go:310 +0x7e
gvisor.googlesource.com/gvisor/pkg/sentry/mm.(*MemoryManager).DecUsers(0xc42043cc80, 0xc75c20, 0xc42047a5a0)
	pkg/sentry/mm/lifecycle.go:220 +0x1dd
gvisor.googlesource.com/gvisor/pkg/sentry/kernel.(*TaskContext).release(0xc4204f3030)
	pkg/sentry/kernel/task_context.go:62 +0xd6
gvisor.googlesource.com/gvisor/pkg/sentry/kernel.(*runExitMain).execute(0x0, 0xc4204f2900, 0xc68a20, 0x0)
	pkg/sentry/kernel/task_exit.go:261 +0xc5
gvisor.googlesource.com/gvisor/pkg/sentry/kernel.(*Task).run(0xc4204f2900, 0x7)
	pkg/sentry/kernel/task_run.go:95 +0x174
created by gvisor.googlesource.com/gvisor/pkg/sentry/kernel.(*Task).Start
	pkg/sentry/kernel/task_start.go:251 +0x100

Crashes (4804):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2018/06/30 00:26 https://gvisor.googlesource.com/gvisor master 1b5e09f968bf 5739f7be .config console log report syz C ci-gvisor-ptrace-direct-overlay-host
2018/06/30 00:21 https://gvisor.googlesource.com/gvisor master 1b5e09f968bf 5739f7be .config console log report syz C ci-gvisor-main
2018/06/22 14:26 https://gvisor.googlesource.com/gvisor master 0e434b66a625 78c2562d console log report syz C ci-gvisor-main
2018/06/30 00:27 https://github.com/dvyukov/gvisor.git race 77e5397d66ab 5739f7be .config console log report syz C ci-gvisor-ptrace-proxy-sandbox-race
2018/08/28 15:12 https://gvisor.googlesource.com/gvisor master ae648bafda2d 7ef1de9e .config console log report syz ci-gvisor-ptrace-direct-overlay-host
2018/08/28 15:12 https://gvisor.googlesource.com/gvisor master db81c0b02f2f 7ef1de9e .config console log report syz ci-gvisor-kvm-direct-sandbox
2018/08/28 15:10 https://gvisor.googlesource.com/gvisor master b17e80ef5a44 7ef1de9e .config console log report syz ci-gvisor-kvm-proxy-overlay-sandbox
2018/08/28 15:00 https://gvisor.googlesource.com/gvisor master 2524111fc633 7ef1de9e .config console log report syz ci-gvisor-main
2018/08/28 15:01 https://github.com/dvyukov/gvisor.git race d4d5ed1d9def 7ef1de9e .config console log report syz ci-gvisor-ptrace-proxy-sandbox-race
2018/08/28 14:54 https://github.com/dvyukov/gvisor.git race d4d5ed1d9def 7ef1de9e .config console log report syz ci-gvisor-kvm-direct-overlay-host-race
2018/09/08 12:07 https://gvisor.googlesource.com/gvisor master ae648bafda2d 6b5120a4 .config console log report ci-gvisor-ptrace-direct-overlay-host
2018/09/08 10:05 https://gvisor.googlesource.com/gvisor master ae648bafda2d 6b5120a4 .config console log report ci-gvisor-ptrace-direct-overlay-host
2018/09/08 10:04 https://gvisor.googlesource.com/gvisor master ae648bafda2d 6b5120a4 .config console log report ci-gvisor-ptrace-direct-overlay-host
2018/09/08 07:11 https://gvisor.googlesource.com/gvisor master ae648bafda2d 6b5120a4 .config console log report ci-gvisor-ptrace-direct-overlay-host
2018/09/08 02:57 https://gvisor.googlesource.com/gvisor master ae648bafda2d 69cfeb80 .config console log report ci-gvisor-ptrace-direct-overlay-host
2018/09/08 01:42 https://gvisor.googlesource.com/gvisor master ae648bafda2d 69cfeb80 .config console log report ci-gvisor-ptrace-direct-overlay-host
2018/09/08 00:21 https://gvisor.googlesource.com/gvisor master ae648bafda2d 69cfeb80 .config console log report ci-gvisor-ptrace-direct-overlay-host
2018/09/07 22:29 https://gvisor.googlesource.com/gvisor master ae648bafda2d 69cfeb80 .config console log report ci-gvisor-ptrace-direct-overlay-host
2018/09/07 21:03 https://gvisor.googlesource.com/gvisor master ae648bafda2d 69cfeb80 .config console log report ci-gvisor-ptrace-direct-overlay-host
2018/09/07 19:53 https://gvisor.googlesource.com/gvisor master ae648bafda2d 69cfeb80 .config console log report ci-gvisor-ptrace-direct-overlay-host
2018/09/07 17:53 https://gvisor.googlesource.com/gvisor master ae648bafda2d 69cfeb80 .config console log report ci-gvisor-ptrace-direct-overlay-host
2018/09/07 14:10 https://gvisor.googlesource.com/gvisor master ae648bafda2d e30d3b52 .config console log report ci-gvisor-ptrace-direct-overlay-host
2018/09/07 13:47 https://gvisor.googlesource.com/gvisor master ae648bafda2d e30d3b52 .config console log report ci-gvisor-ptrace-direct-overlay-host
2018/09/07 12:27 https://gvisor.googlesource.com/gvisor master ae648bafda2d e30d3b52 .config console log report ci-gvisor-ptrace-direct-overlay-host
2018/09/07 11:01 https://gvisor.googlesource.com/gvisor master ae648bafda2d e30d3b52 .config console log report ci-gvisor-ptrace-direct-overlay-host
2018/09/07 09:47 https://gvisor.googlesource.com/gvisor master ae648bafda2d e30d3b52 .config console log report ci-gvisor-ptrace-direct-overlay-host
2018/09/07 07:39 https://gvisor.googlesource.com/gvisor master ae648bafda2d e30d3b52 .config console log report ci-gvisor-ptrace-direct-overlay-host
2018/09/07 06:38 https://gvisor.googlesource.com/gvisor master ae648bafda2d e30d3b52 .config console log report ci-gvisor-ptrace-direct-overlay-host
2018/09/07 05:33 https://gvisor.googlesource.com/gvisor master ae648bafda2d e30d3b52 .config console log report ci-gvisor-ptrace-direct-overlay-host
2018/09/07 04:31 https://gvisor.googlesource.com/gvisor master ae648bafda2d e30d3b52 .config console log report ci-gvisor-ptrace-direct-overlay-host
2018/09/07 02:53 https://gvisor.googlesource.com/gvisor master ae648bafda2d 0bb7a7eb .config console log report ci-gvisor-ptrace-direct-overlay-host
2018/09/07 00:28 https://gvisor.googlesource.com/gvisor master ae648bafda2d 0bb7a7eb .config console log report ci-gvisor-ptrace-direct-overlay-host
2018/09/06 22:04 https://gvisor.googlesource.com/gvisor master ae648bafda2d 0bb7a7eb .config console log report ci-gvisor-ptrace-direct-overlay-host
2018/09/06 20:46 https://gvisor.googlesource.com/gvisor master ae648bafda2d 0bb7a7eb .config console log report ci-gvisor-ptrace-direct-overlay-host
2018/09/06 19:28 https://gvisor.googlesource.com/gvisor master ae648bafda2d 0bb7a7eb .config console log report ci-gvisor-ptrace-direct-overlay-host
2018/09/06 17:32 https://gvisor.googlesource.com/gvisor master ae648bafda2d 0bb7a7eb .config console log report ci-gvisor-ptrace-direct-overlay-host
2018/09/06 14:39 https://gvisor.googlesource.com/gvisor master ae648bafda2d 873745f2 .config console log report ci-gvisor-ptrace-direct-overlay-host
2018/09/06 13:27 https://gvisor.googlesource.com/gvisor master ae648bafda2d 873745f2 .config console log report ci-gvisor-ptrace-direct-overlay-host
2018/09/06 11:29 https://gvisor.googlesource.com/gvisor master ae648bafda2d 873745f2 .config console log report ci-gvisor-ptrace-direct-overlay-host
2018/09/06 10:15 https://gvisor.googlesource.com/gvisor master ae648bafda2d 873745f2 .config console log report ci-gvisor-ptrace-direct-overlay-host
2018/09/06 08:51 https://gvisor.googlesource.com/gvisor master ae648bafda2d 873745f2 .config console log report ci-gvisor-ptrace-direct-overlay-host
2018/09/06 07:23 https://gvisor.googlesource.com/gvisor master ae648bafda2d 873745f2 .config console log report ci-gvisor-ptrace-direct-overlay-host
2018/09/06 06:20 https://gvisor.googlesource.com/gvisor master ae648bafda2d 873745f2 .config console log report ci-gvisor-ptrace-direct-overlay-host
2018/09/06 05:19 https://gvisor.googlesource.com/gvisor master ae648bafda2d 873745f2 .config console log report ci-gvisor-ptrace-direct-overlay-host
2018/09/05 14:16 https://gvisor.googlesource.com/gvisor master ae648bafda2d 5c6bf6c5 .config console log report ci-gvisor-ptrace-direct-overlay-host
2018/09/05 12:41 https://gvisor.googlesource.com/gvisor master ae648bafda2d 5c6bf6c5 .config console log report ci-gvisor-ptrace-direct-overlay-host
2018/08/29 23:09 https://gvisor.googlesource.com/gvisor master 2524111fc633 4937cb2b .config console log report ci-gvisor-main
2018/08/02 19:11 https://gvisor.googlesource.com/gvisor master 3cd782441030 0a7cf4ec .config console log report ci-gvisor-kvm-direct-sandbox
2018/08/02 15:29 https://gvisor.googlesource.com/gvisor master 3cd782441030 0a7cf4ec .config console log report ci-gvisor-kvm-proxy-overlay-sandbox
2018/08/30 00:14 https://github.com/dvyukov/gvisor.git race d4d5ed1d9def 4937cb2b .config console log report ci-gvisor-kvm-direct-overlay-host-race
2018/08/29 16:45 https://github.com/dvyukov/gvisor.git race d4d5ed1d9def 53ff8784 .config console log report ci-gvisor-ptrace-proxy-sandbox-race
* Struck through repros no longer work on HEAD.