remove IPADDR, which was making Rob feel ill
IPADDR is simple, but not exactly what we need for testnet, where NAT'd folks need to join in, need to advertize themselves as on the interweb. myip() helps, but there's some TODOs: fullnode-config probably needs to be told where it lives in the real world (machine interfaces tell us dick), or incorporate something like the "ifconfig.co" code in myip.sh
This commit is contained in:
@@ -1,14 +1,26 @@
|
||||
#!/bin/bash
|
||||
here=$(dirname $0)
|
||||
. "${here}"/myip.sh
|
||||
|
||||
myip=$(myip) || exit $?
|
||||
|
||||
[[ -f leader-"${myip}".json ]] || {
|
||||
echo "I can't find a matching leader config file for \"${myip}\"...
|
||||
Please run ${here}/setup.sh first.
|
||||
"
|
||||
exit 1
|
||||
}
|
||||
|
||||
# if RUST_LOG is unset, default to info
|
||||
export RUST_LOG=${RUST_LOG:-solana=info}
|
||||
|
||||
set -x
|
||||
[[ $(uname) = Linux ]] && sudo sysctl -w net.core.rmem_max=26214400
|
||||
[[ $(uname) = Linux ]] && sudo sysctl -w net.core.rmem_max=26214400 1>/dev/null 2>/dev/null
|
||||
|
||||
IPADDR="$(ifconfig | awk '/inet (addr)?/ {print $2}' | cut -d: -f2 | grep -v '127.0.0.1')"
|
||||
|
||||
cp leader-"$IPADDR".json leader.json
|
||||
# this makes a leader.json file available alongside genesis, etc. for
|
||||
# validators and clients
|
||||
cp leader-"${myip}".json leader.json
|
||||
|
||||
cargo run --release --bin solana-fullnode -- \
|
||||
-l leader.json < genesis.log tx-*.log > tx-"$(date -u +%Y%m%d%k%M%S%N)".log
|
||||
-l leader-"${myip}".json \
|
||||
< genesis.log tx-*.log \
|
||||
> tx-"$(date -u +%Y%m%d%H%M%S%N)".log
|
||||
|
Reference in New Issue
Block a user