32 lines
968 B
Bash
32 lines
968 B
Bash
#!/bin/bash
|
|
|
|
#rpc=https://go.getblock.io/61bed5f600ab47ff903baacab0e37c36
|
|
#rpc=https://api.mainnet-beta.solana.com
|
|
rpc=https://crimson-nameless-season.solana-mainnet.quiknode.pro/05858e8f2f620b3705dc985711ee7681a3d00bbd/
|
|
|
|
# 定义RPC URL数组
|
|
rpcurls=($rpc)
|
|
|
|
for keypair in *.json;
|
|
do
|
|
# 随机选择一个RPC URL
|
|
index=$((RANDOM % ${#rpcurls[@]}))
|
|
rpcurl=${rpcurls[$index]}
|
|
echo "选中rpc=$rpcurl"
|
|
|
|
screen -dmS mining_$keypair bash -c "
|
|
while true; do
|
|
if [ -f rpc_config ]; then
|
|
source rpc_config
|
|
fi
|
|
echo \"Starting indefinite ore mining iteration with $keypair....\"
|
|
nice -n 20 ore --rpc $rpc --keypair ./$keypair --priority-fee 1000 mine --threads 2
|
|
#ore --rpc $rpc --keypair ./$keypair --priority-fee 1000000 mine --threads 16 &
|
|
#sleep 5
|
|
#ore --rpc $rpc --keypair ./$keypair --priority-fee 1000000 mine --threads 16 &
|
|
#wait
|
|
done
|
|
"
|
|
# exit
|
|
done
|