goquarkchain icon indicating copy to clipboard operation
goquarkchain copied to clipboard

cannot gracefully shutdown

Open qizhou opened this issue 5 years ago • 1 comments

Setup a cluster with latest git commit 2cecca63bd17a05a054212e29d58f29f69968896, synced 5530 blocks and try to shutdown with CTRL+C. The cluster cannot gracefully shutdown (shutting down forever)

image

qizhou avatar Nov 19 '19 00:11 qizhou

It is hard to reproduce in a dev environment. Most likely it caused by the stop operation of p2p service is blocked by active peer connections. A normal shutdown would be like:

^CINFO [11-20|10:39:44.731] Got interrupt, shutting down... 
INFO [11-20|10:39:44.731] grpc endpoint closed                     url=192.168.183.173:38191
INFO [11-20|10:39:44.731] public HTTP endpoint closed              url=http://127.0.0.1:38391
INFO [11-20|10:39:44.731] private HTTP endpoint closed             url=http://127.0.0.1:38491
INFO [11-20|10:39:44.731] Stopping Master protocol 
INFO [11-20|10:39:44.732] cluster protocol stopped 
INFO [11-20|10:39:44.732] Blockchain manager stopped 
INFO [11-20|10:39:44.734] stoped P2P networking   

Ctrl+c 10 times to cause panic, and we can get the full debug trace.

syntrust avatar Nov 20 '19 03:11 syntrust