Improving Tezos Storage : Gitlab branch for testers

This article is the third post of a series of posts on improving Tezos storage.  In our previous post, we announced the availability of a docker image for beta testers, wanting to test our storage and garbage collector. Today, we are glad to announce that we rebased our code on the latest version of mainnet-staging, and pushed a branch mainnet-staging-irontez on our public Gitlab repository:

The only difference with the previous post is a change in the name of the RPCs : /storage/context/gc will trigger a garbage collection (and terminate the node afterwards) and /storage/context/revert will migrate the database back to Irmin (and terminate the node afterwards).

Enjoy and send us feedback !!

4 thoughts on “Improving Tezos Storage : Gitlab branch for testers

  • I must be missing something. I compiled and issued the required rpc trigger:

    /storage/context/gc with the command

    ~/tezos/tezos-client rpc get /storage/context/gc

    But I just got an empty JSON response of {} and the size of the .tezos-node folder is unchanged. Any advice is much appreciated.

    Thank you!

    • By default, garbage collection will keep 9 cycles of blocks (~36000 blocks). If you have fewer blocks, or if you are using Irontez on a former Tezos database, and fewer than 9 cycles have been stored in Irontez, nothing will happen. If you want to force a garbage collection, you should tell Irontez to keep fewer block (but more than 100, that’s the minimum that we enforce):

      ~/tezos/tezos-client rpc get ‘/storage/context/gc?keep=120’

      should trigger a GC if the node has been running on Irontez for at least 2 hours.

      • I think it did work. I was confused because the total disk space for the .tezos-node folder remained unchanged. Upon closer inspection, I see these contents and sizes:

        These are the contents of .tezos-node, can I safely delete context.backup?

        4.0K config.json
        269M context
        75G context.backup
        4.0K identity.json
        4.0K lock
        1.4M peers.json
        5.4G store
        4.0K version.json

        Is it safe to delete context.backup if I do not plan to revert? (/storage/context/revert)

Leave a Reply

Your email address will not be published. Required fields are marked *