Skip to content

Upgrade 0G Data Availability (DA) Node

This guide outlines the mandatory update process for the 0G Data Availability (DA) node to version v1.1.2. This update includes critical binary changes and a required update to the DA contract address within your configuration.

Before upgrading, stop the current service and secure your existing configuration file. This ensures your BLS keys and environment settings are preserved.

Execute the following command to stop the node, backup your config.toml, and clear the previous build directory:

Terminal window
sudo systemctl stop zgda && \
cp $HOME/0g-da-node/config.toml $HOME/config.toml.backup && \
rm -rf $HOME/0g-da-node

Clone the latest repository and checkout the specific tag for version v1.1.2.

Terminal window
git clone https://github.com/0glabs/0g-da-node.git
cd $HOME/0g-da-node
git checkout tags/v1.1.2 -b v1.1.2

Rebuild the DA server binary and ensure the cryptographic parameters are present:

Terminal window
cargo build --release
./dev_support/download_params.sh

This version requires updating the DA contract address. The following steps restore your backup and use sed to perform the address swap automatically.

Terminal window
mv $HOME/config.toml.backup $HOME/0g-da-node/config.toml
sed -i -e "s|0xDFC8B84e3C98e8b550c7FEF00BCB2d8742d80a69|0x857C0A28A8634614BB2C96039Cf4a20AFF709Aa9|" $HOME/0g-da-node/config.toml
ParameterOld ValueNew Value (v1.1.2)
DA Contract0xDFC8...0a690x857C...9Aa9

Apply the changes and restart the DA service infrastructure.

Terminal window
sudo systemctl daemon-reload
sudo systemctl restart zgda

Check the service logs to confirm the node has successfully joined the network with the new contract parameters:

Terminal window
sudo journalctl -u zgda.service -f -o cat

If the node fails to start, verify the following:

  • Path Accuracy: Ensure ExecStart in your systemd file points to the correct $HOME/0g-da-node/target/release/server path.
  • Contract Address: Manually inspect config.toml to ensure the log_contract_address matches the new value provided above.