There is no guarantee for any information on this page and if you decide to follow any instruction or command on this page then it is on your own risk and if it is not allowed for you to run a miner for any reason then I want to strongly advice you to not run a miner and if it is not allowed by law for you to follow other instructions on this page then I want to advice you not to follow it. There might be errors on this page.

~/mnr.ai

Do you want to see all open TMUX sessions?

tmux list-sessions

Do you want to go to a TMUX session?


tmux attach -t <ID>

Do you want to see the logs of a miner or validator in PM2?


pm2 log <ID>

Do you want to stop a miner or validator in PM2?


pm2 stop <ID>

Do you want to restart a miner or validator in PM2?


pm2 stop <ID> && pm2 start <ID>

Do you want to restart all processes in PM2?


pm2 stop all && pm2 start all

Do you want to see all processes running in PM2?


pm2 monitor all

Do you want to see on what ports miners are running if you have miners running in PM2?


echo "" > ports___.sh && chmod 700 ports___.sh && pm2 monitor all | awk '$2 > -1 { print "pm2 info "$2" | grep axon.port"}' >> ports___.sh && ./ports___.sh && rm ./ports___.sh

Do you want to see logs of processes that are running in pm2 for a few seconds per process?


echo "" > logger___.sh && chmod 700 logger___.sh && pm2 monitor all | awk '$2 > -1 { print "pm2 logs "$2" --lines 50 --nostream && sleep 2"}' >> logger___.sh && ./logger___.sh && rm ./logger___.sh

Do you want to see if a miner had many timeouts?


pm2 log <ID> --nostream --lines 100000 | grep timeout

Do you want to know what command you ran to start a specific miner?


pm2 describe <pm2 process name> | grep "script args" | sed "s/│ script args │ /pm2 start \/root\/.bittensor\/bittensor\/bittensor\/_neuron\/text\/core_server\/main.py --name <pm2 process name> --time --interpreter python3 -- /g" | sed "s/ │//g"

Do you want to regenerate some hotkeys?


for c in $(ls ~/.bittensor/wallets/);do for h in $(ls ~/.bittensor/wallets/$c/hotkeys);do echo ""; echo -n "btcli regen_hotkey --wallet.name $c --wallet.hotkey $h --menemonic "; cat ~/.bittensor/wallets/coldkey/hotkeys/$h | sed 's/"//g' | sed 's/,//g' | awk '{ print $6" "$7" "$8" "$9" "$10" "$11" "$12" "$13" "$14" "$15" "$16" "$17 }' ;done;done;