How to Run as a Collator on Battery Station
Run the node in Collator mode
Download and set up the node environment
- We can use the following command line to get the latest Zeitgeist node binary.
curl -o zeitgeist https://github.com/zeitgeistpm/zeitgeist/releases/download/v0.3.2/zeitgeist_parachain
chmod +x zeitgeist
Register a non-privileged user to run the Zeitgeist node service. Docker is not recommended, as it may not guarantee high performance.
sudo useradd -M -r -s /sbin/nologin zeitgeist
Copy the node binary to the specified folder.
sudo mkdir -p /services/zeitgeist/bin
sudo cp /path/to/your/target/release/zeitgeist /services/zeitgeist/bin
sudo chown -R zeitgeist:zeitgeist /services/zeitgeist
sudo chmod -R go=-rwx /services/zeitgeist
Create a new service.
sudo nano /etc/systemd/system/zeitgeist-node.service
Configure the relevant information in the file.
[Unit]
Description=Zeitgeist Battery Station parachain full node
After=network.target
Requires=network.target
[Service]
Type=simple
User=zeitgeist
Group=zeitgeist
RestartSec=5
Restart=always
Nice=0
ExecStart=/services/zeitgeist/bin/zeitgeist \
--base-path=/services/zeitgeist/battery_station \
--chain=battery_station \
--name-=zeitgeist-whisker \
--port=30333 \
--rpc-port=9933 \
--ws-port=9944 \
--collator \
--rpc-cors=all \
--pruning=archive \
--\
--port=30334 \
--rpc-port=9934 \
--ws-port=9945
[Install]
WantedBy=multi-user.target
- Enable and start the service.
sudo systemctl enable zeitgeist-node
sudo systemctl start zeitgeist-node
Check the status of the service:
systemctl status zeitgeist-node
To view the service logging.
journalctl -u zeitgeist-node