Cronos zkEVM Sepolia Testnet

This guide covers running a node for Cronos zkEVM testnet (Chain ID: 240) with external-node v24.23.0 on docker.

Pre-requisites

Prepare your machine

This configuration is approximate and should be considered as minimal requirements:

Full Node - is configured to build and store the last 7 days of data for Cronos zkEVM Sepolia Testnet by default. Check here for details on the pruning setting.

  • 4-core of CPU

  • 16GB of RAM

  • 100G of SSD storage

Step 1: Download the DB Dump

1.1 - Download the pgdump

Create a new folder and download the dump file into it by:

wget https://storage.googleapis.com/cronos-zkevm-testnet-en-pgdump/external_node.tar.gz

1.2 - Extract the data from dump

After extracting the file, locate the dump folder and the pg_restore.list file. Put both to the main directory, instead of default under β€œexternal_node”.

Step 2: Docker Preparations

2.1 - Pull Docker Image

Under the same directory, pull docker image from Github Container Registry:

2.2 - Create Docker Compose Configuration

Inside that directory, create and edit docker-compose.yml :

Add the following configuration to docker-compose.yml:

Note

  • EN_PRUNING_ENABLED: Determines whether the node is set to pruning mode. When enabled, the node retains only recent chain data and discards older data to conserve storage space.

  • EN_SNAPSHOTS_RECOVERY_ENABLED, EN_SNAPSHOTS_OBJECT_STORE_BUCKET_BASE_URL, and EN_SNAPSHOTS_OBJECT_STORE_MODE: Enable snapshots recovery (similar to state-sync) and allows the node to recover from the latest batch without containing the full historical data.

  • Add debug to namespaces: Enables debug tracing and saves debug data.EN_API_NAMESPACES:Defines the enabled API namespaces, including eth, net, web3, zks, pubsub, and debug.

  • Read more on Snapshots Recovery here.

Step 3: Database Restoration

3.1 - Start PostgreSQL Container:

Please note postgres was named in docker-compose.

When container is running, list containers to find the container ID:

Below is the example output:

3.2 - Restore Database from Dump

Run the following and docker retrieve and manipulate the data from data dump:

Example:

NOTE

The username and database names were defined in thedocker-compose; in this example, they are zksync and mydb, respectively.

During the process, on the docker side, you should see:

Depending on the specs, the process might take several hours.

Step 4: Run everything

Once the pg restore completed, start the cronoszk node service:

Example output should be like:

You should see in the Docker logs that the node is fetching block data from the RPCs.

For example:

Once the node is synchronized, you may use EN_HTTP_PORT: 3060 as defined for ETH-JSON RPC calls.

Last updated