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

runtime: fatal error: unexpected signal during runtime execution #24861

Closed
iceooacai opened this issue Apr 14, 2018 · 11 comments
Closed

runtime: fatal error: unexpected signal during runtime execution #24861

iceooacai opened this issue Apr 14, 2018 · 11 comments
Labels
FrozenDueToAge NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. OS-Windows WaitingForInfo Issue is not actionable because of missing required information, which needs to be provided.
Milestone

Comments

@iceooacai
Copy link

iceooacai commented Apr 14, 2018

Please answer these questions before submitting your issue. Thanks!

What version of Go are you using (go version)?

go version go1.10 windows/amd64

Does this issue reproduce with the latest release?

no

What operating system and processor architecture are you using (go env)?

set GOARCH=amd64
set GOBIN=
set GOCACHE=C:\Users\Administrator\AppData\Local\go-build
set GOEXE=.exe
set GOHOSTARCH=amd64
set GOHOSTOS=windows
set GOOS=windows
set GOPATH=C:\GoPath;D:\Server_正式服
set GORACE=
set GOROOT=C:\Go
set GOTMPDIR=
set GOTOOLDIR=C:\Go\pkg\tool\windows_amd64
set GCCGO=gccgo
set CC=gcc
set CXX=g++
set CGO_ENABLED=1
set CGO_CFLAGS=-g -O2
set CGO_CPPFLAGS=
set CGO_CXXFLAGS=-g -O2
set CGO_FFLAGS=-g -O2
set CGO_LDFLAGS=-g -O2
set PKG_CONFIG=pkg-config
set GOGCCFLAGS=-m64 -mthreads -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=C:\Users\ADMINI~1\AppData\Local\Temp\2\go-build259
987786=/tmp/go-build -gno-record-gcc-switches

What did you do?

I did nothing

What did you expect to see?

Was expecting program could run fluently without any crash

What did you see instead?

fatal error: unexpected signal during runtime execution
[signal 0xc0000005 code=0x0 addr=0x7ef0128 pc=0x450f79]

runtime stack:
runtime.throw(0xf94e32, 0x2a)
	C:/Go/src/runtime/panic.go:619 +0x88
runtime.sigpanic()
	C:/Go/src/runtime/signal_windows.go:161 +0x170
runtime.gentraceback(0x45c90e, 0x7eefe60, 0x0, 0xc047af9b00, 0x0, 0x88ef260, 0x40, 0x0, 0x0, 0x6, ...)
	C:/Go/src/runtime/traceback.go:280 +0x14f9
runtime.sigprof(0x45c90e, 0x7eefe60, 0x0, 0xc047af9b00, 0xc0422a6c00)
	C:/Go/src/runtime/proc.go:3707 +0x4aa
runtime.profilem(0xc0422a6c00)
	C:/Go/src/runtime/os_windows.go:839 +0xea
runtime.profileloop1(0x0, 0x0)
	C:/Go/src/runtime/os_windows.go:858 +0xe6
runtime.externalthreadhandler(0x88efb90, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
	C:/Go/src/runtime/sys_windows_amd64.s:263 +0x95

goroutine 1 [chan receive]:
MyEngine/routineevent.(*RoutineEvent).Run(0x14e5c40, 0xc0430e4000)
	D:/Server/src/MyEngine/routineevent/routineevent.go:119 +0x541
MyServer_Module/module_logic.Run()
	D:/Server/src/MyServer_Module/module_logic/module_logic.go:305 +0x132
MyServer_Module/module_run.Start(0xc042210fc0, 0x1, 0x1, 0x0, 0x0)
	D:/Server/src/MyServer_Module/module_run/module_run.go:31 +0xb7
main.main()
	D:/Server/src/MyServerAll/main.go:34 +0x35f

goroutine 17 [syscall, 1212 minutes]:
os/signal.signal_recv(0x0)
	C:/Go/src/runtime/sigqueue.go:139 +0xad
os/signal.loop()
	C:/Go/src/os/signal/signal_unix.go:22 +0x29
created by os/signal.init.0
	C:/Go/src/os/signal/signal_unix.go:28 +0x48
@ALTree
Copy link
Member

ALTree commented Apr 14, 2018

Was expecting program could run fluently without any crash

What program? There's no code in your message.

@ALTree ALTree added the WaitingForInfo Issue is not actionable because of missing required information, which needs to be provided. label Apr 14, 2018
@iceooacai
Copy link
Author

It's a large program , server part of an online game, too much code to attach, can't position which part cost the crash right now

@ALTree
Copy link
Member

ALTree commented Apr 14, 2018

  1. Does it use cgo?
  2. Does compiling and then running it with the race detector enabled (-race) print any race warning?

@iceooacai
Copy link
Author

1.No cgo
2.Hundreds of player online right now, can't use race detector in case of high CPU&RAM usage

@iceooacai
Copy link
Author

iceooacai commented Apr 14, 2018

Oh, it does use cgo, it imported a package "gopkg.in/mgo.v2" and this package use cgo

And this Error just happened randomly, several times a day or once a week are both in chance

@ALTree
Copy link
Member

ALTree commented Apr 14, 2018

This looks like it may be caused by memory corruption, either by erroneous cgo code or by a data race in your code. You should find a way to deploy a race-enabled version of the code on some subset of your servers or something like that.

I don't see how we could investigate (or do anything about) this, without having a reproducer or anything to work on.

cc @aclements in case he has something to say about the stack-trace

@ALTree ALTree changed the title runtime:fatal error: unexpected signal during runtime execution runtime: fatal error: unexpected signal during runtime execution Apr 14, 2018
@iceooacai
Copy link
Author

Thank you very much, I'll try to find one

@ianlancetaylor
Copy link
Contributor

This looks like a profiling signal occurred on a stack with an invalid frame pointer. That should in general be impossible; not sure what happened here.

@ianlancetaylor ianlancetaylor added this to the Go1.11 milestone Apr 18, 2018
@ianlancetaylor ianlancetaylor added OS-Windows NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. labels Apr 18, 2018
@ianlancetaylor
Copy link
Contributor

I think that to fix this we will need a way to reproduce this ourselves.

@ianlancetaylor ianlancetaylor modified the milestones: Go1.11, Go1.12 Jul 11, 2018
@agnivade
Copy link
Contributor

Hey @iceooacai - just wanted to check if you were able to make any progress on this ? We would need a short reproducer to debug this further, or you can also try running a race-detection enabled version of your code.

As a last resort, please also try with 1.12beta2 if that makes any difference. Thanks.

@agnivade agnivade added WaitingForInfo Issue is not actionable because of missing required information, which needs to be provided. and removed WaitingForInfo Issue is not actionable because of missing required information, which needs to be provided. labels Jan 14, 2019
@andybons andybons modified the milestones: Go1.12, Go1.13 Feb 12, 2019
@gopherbot
Copy link

Timed out in state WaitingForInfo. Closing.

(I am just a bot, though. Please speak up if this is a mistake or you have the requested information.)

@golang golang locked and limited conversation to collaborators Feb 14, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
FrozenDueToAge NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. OS-Windows WaitingForInfo Issue is not actionable because of missing required information, which needs to be provided.
Projects
None yet
Development

No branches or pull requests

6 participants