-
Notifications
You must be signed in to change notification settings - Fork 9.1k
Closed
Labels
Description
Description
1-2 times a month my peers randomly crashed with the message invalid memory address or nil pointer dereference.
The system uses more than 50 peers and 50 channels, so exchanges through gossip are very active.
Peers, Orderers v2.5.5
The section of code where the bug appears clearly requires adding a check for the existence of a map element.
Panic example 1
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x8 pc=0x151112d]
goroutine 32595521 [running]:
github.com/hyperledger/fabric/gossip/util.(*Set).Remove(0x0, {0x191b6e0, 0xc0051e4020})
/gossip/util/misc.go:118 +0x2d
github.com/hyperledger/fabric/gossip/util.(*PubSub).unSubscribe(0xc002b89840, 0xc0051e4020)
/gossip/util/pubsub.go:115 +0x8d
github.com/hyperledger/fabric/gossip/util.(*PubSub).Subscribe.func1()
/gossip/util/pubsub.go:107 +0x1b
created by time.goFunc
/usr/local/go/src/time/sleep.go:176 +0x2d
Panic example 2
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x8 pc=0x151112d]
goroutine 1909191 [running]:
github.com/hyperledger/fabric/gossip/util.(*Set).Remove(0x0, {0x191b6e0, 0xc0064e7fa0})
/gossip/util/misc.go:118 +0x2d
github.com/hyperledger/fabric/gossip/util.(*PubSub).unSubscribe(0xc005aaf980, 0xc0064e7fa0)
/gossip/util/pubsub.go:115 +0x8d
github.com/hyperledger/fabric/gossip/util.(*PubSub).Subscribe.func1()
/gossip/util/pubsub.go:107 +0x1b
created by time.goFunc
/usr/local/go/src/time/sleep.go:176 +0x2d
Steps to reproduce
- Make more then 50 peers.
- Make more then 50 channels.
- idk what else (It happens unpredictably).
Reactions are currently unavailable