Skip to main content

Linux tips

Example ports and hosts used, change to your own setup.

check if ports are open

nc -vz 30333

see cpu frequencies

lscpu --all --extended

get more disk space by limiting reserved space for root

Default is 5% which is 50GB on a 1000 GB system, 0.1 (1GB) is more suitable.

tune2fs -m0.1 /dev/<disk>

get disk space information

du -sh /home/polkadot/*
df -h


curl -H "Content-Type: application/json" -d '{"id":1, "jsonrpc":"2.0", "method": "author_rotateKeys", "params":[]}' http://localhost:9944 > session.key

check session keys

curl -H "Content-Type: application/json" -d '{"id":1, "jsonrpc":"2.0", "method": "author_hasSessionKeys", "params":["<session key 0x.....>"]}' http://localhost:9944

see number of processes at a certain port

netstat -tn src :30333 | wc -l