skalenetwork / skaled

Running more than 20 production blockchains, SKALED is Ethereum-compatible, high performance C++ Proof-of-Stake client, tools and libraries. Uses SKALE consensus as a blockchain consensus core. Includes dynamic Oracle. Implements file storage and retrieval as an EVM extension.
https://skale.network
GNU General Public License v3.0
84 stars 39 forks source link

Disable block rotation for consensus blcoks.db on archival node #1843

Open oleksandrSydorenkoJ opened 6 months ago

oleksandrSydorenkoJ commented 6 months ago

Currently, archival node archives only skaled blocks and extras databases.

But Consensus DB sill rotated after the filling the allocated 60 GB of spaces and then the oldest database will be pruned.

To avoid losing data and to save the ability to run archival nodes, we need to implement a consensus-DB archive, as it implemented for blocks and extras db

PolinaKiporenko commented 6 months ago

will be discuss on separate call

kladkogex commented 4 months ago

image

kladkogex commented 4 months ago

To disable storage limit set the following in the config file

"maxConsensusStorageBytes" : 1000000000000000000

(18 zeroes)

This sets max storage to million terabytes, which is de-facto infinite

oleksandrSydorenkoJ commented 3 months ago

blocked by https://github.com/skalenetwork/internal-support/issues/988

oleksandrSydorenkoJ commented 2 months ago

before update root@Regression-archive:/var/lib/skale/schains/sandy-ignorant-alya/blocks_17.db# du -sh * 16K db.2 16K db.3 1.3G db.4 19M db.5

root@Regression-Node-17:/mnt/schains-sandy-ignorant-alya/blocks_16.db# du -sh * 12K db.2 12K db.3 1.3G db.4 18M db.5

root@ip-172-31-46-235:/home/ubuntu# docker logs proxy_nginx --since 2024-07-05T16:27:18 --until 2024-07-05T16:27:28

after update Archival node 2024-07-08 09:46:25.640625 Block sealed #89751 (#cd8e0265…)

root@Regression-archive:/var/lib/skale/schains/sandy-ignorant-alya/blocks_17.db# du -sh * 16K db.2 16K db.3 1.3G db.4 1.5G db.5

core node

[2024-07-08 09:46:21.748] [16:main] [info] 89750:CWT:366:TLWT:10159:SBPT:143 2024-07-08 09:46:21.749488 createBlock ID = #89751 2024-07-08 09:46:21.749686 Block sealed #89751 (#cd8e0265…)

root@Regression-Node-17:/mnt/schains-sandy-ignorant-alya/blocks_16.db# du -sh * 12K db.3 1.3G db.4 1.3G db.5 214M db.6