erigontech / erigon

Ethereum implementation on the efficiency frontier https://erigon.gitbook.io
GNU Lesser General Public License v3.0
3.1k stars 1.09k forks source link

Erigon-v3.0.0-alpha2 blocking and do not serve when query history data #11719

Closed hitdavid closed 2 weeks ago

hitdavid commented 3 weeks ago

System information

Erigon version: Erigon-v3.0.0-alpha2

OS & Version: Linux

Commit hash:

Erigon Command (with flags/config):

Consensus Layer: both internal an external CL

Chain/Network: eth-mainnet

Expected behaviour

When querying or debugging transactions from a long time ago (e.g. a transaction in block 15000000), RPCDaemon need extremely high I/O requests, typically reaching 100G-2T/s for SSD disk reads. As a result, Erigon starts to fail to provide normal service, consuming almost all CPU time, and it cannot synchronize data properly. When I tried to reproduce the issue, I found that rpcdaemon reads files including:

I added timeout settings when running rpcdaemon with parameters --http.timeouts.read 5s --http.timeouts.write 10s --rpc.evmtimeout 10s, but this did not resolve the problem. Is this a case of misuse or a design flaw?

What methods can I use to make the performance of Erigon 3 similar to that of Erigon v2.60, at least to ensure it works?

AskAlexSharov commented 3 weeks ago

fixed by https://github.com/erigontech/erigon/pull/11700

hitdavid commented 2 weeks ago

fixed by #11700

Thank you, I pulled source from main branch

git pull                                                                                                                                                                                                       
Updating 959bc3752f..13b4b77684

and build from source. The disk-io usage is cut down by now, but RPCdaemon CPU usage is still high(about 80% CPU usage of machine).

wish info above may help.

Thanks

AskAlexSharov commented 2 weeks ago

RPCdaemon CPU usage add --pprof --pprof.port=6061 then go tool pprof -png http://127.0.0.1:6060/debug/pprof/profile\?seconds\=30 > cpu.png

hitdavid commented 2 weeks ago

will open another issue to track cpu usage, and close this