IntersectMBO / cardano-node

The core component that is used to participate in a Cardano decentralised blockchain.
https://cardano.org
Apache License 2.0
3.06k stars 720 forks source link

stake-snapshot crashes cardano-node #2717

Closed seriru closed 2 years ago

seriru commented 3 years ago

When I run docker exec -e CARDANO_NODE_SOCKET_PATH=/cardano/node.sock cardano-node cardano-cli query stake-snapshot --stake-pool-id 6a37c771eb33798edea1cc2b95759fc30a7765bbfc63668bdc92c633 --mainnet it sometimes crashes the cardano-node process on my 8GB RAM machines. This is not the case with a machine running 16GB RAM.

Could you advise which +RTS flags I can use to minimise the memory used for this operation, please?

Best Regards,

Richard

woltere commented 3 years ago

I have seen the same happen on a machine with 16GB of RAM. The cardano-node get OOM kill. The reason being that the cardano-cli query stake-snapshot seems to require several GBs of RAM.

Running the cli with max 3GB of Heap can't run to completion

cardano-cli +RTS -M3G -RTS  query stake-snapshot --stake-pool-id xxxxxxx --mainnet

cardano-cli: Heap exhausted;
cardano-cli: Current maximum heap size is 3221225472 bytes (3072 MB).
cardano-cli: Use `+RTS -M<size>' to increase it.
Jimbo4350 commented 2 years ago

Closing this. If this is still relevant please reopen.

Jimbo4350 commented 2 years ago

Closing this. If this is still relevant please reopen.