Setup Tezos Node with RPC
The best way to inject operations into the Tezos blockchain and to fetch RPC information is from your own node. You get the information faster and you trust fewer people. You get priority.
The best way to inject operations into the Tezos blockchain and to fetch RPC information is from your own node. You get the information faster and you trust fewer people. You get priority.
This guide starts with the latest Ubuntu 20.10 server version but it should work on all Debian based distributions and older (not ancient) versions.
This guide currently only describes how to run an RPC node on the same computer as your wallet. An example of this setup would be running Ubuntu Desktop /w Firefox & Temple/Kukai wallet. Adding an RPC node in the background is a very safe option which will also improve your wallet performance, especially in cases of high network demand.
You need to keep the node process running in the background when you want to make transactions with it. Keep in mind it might take a while to fully synchronize again if you have it off for a long time. For every day it's offline, add 20-40 minutes to sync back up.
sudo apt update
sudo apt install -y curl xz-utils jq screen build-essential git m4 unzip rsync curl bubblewrap libev-dev libgmp-dev pkg-config libhidapi-dev jbuilder software-properties-common opam autoconf libffi-dev
cd /tmp
wget https://sh.rustup.rs/rustup-init.sh
chmod +x rustup-init.sh
./rustup-init.sh --profile minimal --default-toolchain 1.60.0 -y
cd /tmp
wget https://raw.githubusercontent.com/zcash/zcash/master/zcutil/fetch-params.sh
chmod +x fetch-params.sh
./fetch-params.sh
You can can work on next step while this one runs
Use one of the sources below to obtain a full or rolling (both work for baking) snapshot of the Tezos blockchain. A rolling snapshot will get you started the fastest and is completely fine to use for most purposes like farming.
XTZ-Shots
MIDL
https://snaps.teztools.io/
TezTools
cd ~ && git clone https://gitlab.com/tezos/tezos.git && cd tezos && git checkout latest-release
opam init --bare
# (answer yes to questions)
make build-deps
eval $(opam env)
make
./octez-node identity generate
The import of the snapshot will take a no more than an hour on most systems. If you're importing a full snapshot, the process may take up to a full day if you're running on a slow VM or fanless system
./octez-node snapshot import /path/to/chain.full --block <ENTER_BLOCK_HASH_HERE>
Replace the made up path to where your downloaded and uncompressed the Tezos chain snapshot. Navigate to any Tezos blockchain explorer like https://tzstats.com and https://tzkt.io and look up the block number referenced by the snapshot website. The block will have a hash # associated with it, which you will need to copy into the
<ENTER_BLOCK_HASH_HERE>
portion. This verifies the integrity of the chain and saves you many hours of synchronization and waiting.screen -S TezosNode
./tezos-node run --rpc-addr 127.0.0.1 --cors-header='content-type' --cors-origin='*'
CTRL+A then H to log/record session
CTRL+A then d to disconnect from Screen session
You can also start your node in detached screen mode and let it run in the background
screen -mdSL OctezNode bash -c "cd ~/tezos; ./octez-node run --rpc-addr 127.0.0.1:8732 --cors-header='content-type' --cors-origin='*'; exec $SHELL"
This starts your node in a "screen" session, which keeps running in the background.
Once your node is up and fully synchronized, you are ready to inject operations into the blockchain using ./tezos-client or your own RPC running on port 8732 via the Temple wallet.
You can monitor your node by running:
cd ~/tezos
tail -f screen*
The node is synchronized when you see a message like this with blocks which have recent timestamps passing by:

Fully synchronized node
To use your own computer's RPC node on the Temple wallet select the network icon and choose the option on the bottom
localhost:8732

localhost:8732
Any other service which has "RPC" in the settings will allow you to set your own RPC server to your own node by using the same address. It's possible you will need to include
http://localhost:8732
or use http://127.0.0.1:8732
.This will ONLY work with your RPC node is the same node where you have Temple installed. The guide will be expanded to support scenarios where your RPC node is separate from your wallet computer.
🙏 Donate & help us grow. All proceeds go to more baking capacity. tz1S5WxdZR5f9NzsPXhr7L9L1vrEb5spZFur