Lots of network chatter (new transactions from many nodes) in combination with slower disk I/O can cause a Nuts node to fail to start:
network.connectToKnownNodes() causes syncing of the network, which can many transactions from many nodes
- this leads to lots of write transactions, which block read transactions
- then the network notifiers are
Run() in Start(), but they fail due to lock time-outs
- then the node stops because it couldn't start the network module
"Could not start the server" error="unable to start Network: failed to start notifiers: unable to obtain BBolt read lock: database error: context deadline exceeded
Mitigations:
- don't let
Start() return an error when it can't start a notifier; do it in a goroutine instead, retrying if it failed
- limit the number of parallel TransactionList queries
Lots of network chatter (new transactions from many nodes) in combination with slower disk I/O can cause a Nuts node to fail to start:
network.connectToKnownNodes()causes syncing of the network, which can many transactions from many nodesRun()inStart(), but they fail due to lock time-outsMitigations:
Start()return an error when it can't start a notifier; do it in a goroutine instead, retrying if it failed