Maxim
1 min readJun 2

--

Fantom setup archive node for TheGraph MIPs program

1. 📸 Snapshots

- https://download.fantom.network (you’ll need the `~~mainnet-109331-full-mpt.g~~` `mainnet-5577-full-mpt.g` file)

2. Deploy and sync
Official guides available https://docs.fantom.foundation/node/run-an-api-node

# Install build-essential
$ sudo apt-get install -y build-essential

# Install latest Go
$ wget https://go.dev/dl/go1.20.4.linux-amd64.tar.gz
$ rm -rf /usr/local/go && tar -C /usr/local -xzf go1.20.4.linux-amd64.tar.gz
$ sudo mv go /usr/local

# Append the following lines
export GOROOT=/usr/local/go
export GOPATH=$HOME/go
export PATH=$GOPATH/bin:$GOROOT/bin:$PATH

# Validate your Go installation
$ go version

# Install Opera
$ git clone https://github.com/Fantom-foundation/go-opera.git
$ cd go-opera/
$ git checkout release/1.1.2-rc.5
$ make

Config file `/etc/opera/config.toml`:

[Opera]
RPCGasCap = 10000000
RPCEVMTimeout = 10000000000
RPCTimeout = 60000000000
# The final start command(systemd):

opera \\
- genesis=/datadir/mainnet-5577-full-mpt.g \\
- config=/etc/opera/config.toml \\
- port=5050 \\
- maxpeers=200 \\
- datadir=/datadir \\
- http \\
- http.addr=0.0.0.0 \\
- http.port=18545 \\
- http.corsdomain="*" \\
- http.vhosts="*" \\
- ws \\
- ws.addr=0.0.0.0 \\
- ws.port=18546 \\
- ws.origins="*" \\
- nousb \\
- db.preset pbl-1 \\
- tracenode \\
- http.api=eth,web3,net,ftm,trace

--

--

Maxim