Skip to content
This repository was archived by the owner on Jan 22, 2025. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
Enable booting testnet validators without tower required (#19298)
(cherry picked from commit 7d135f1)

# Conflicts:
#	net/net.sh
  • Loading branch information
CriesofCarrots authored and mergify-bot committed Aug 19, 2021
commit 1986d170f6d03741e16fac2a974fa0fc17e4d842
9 changes: 8 additions & 1 deletion multinode-demo/bootstrap-validator.sh
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ else
fi

no_restart=0
maybeRequireTower=true

args=()
while [[ -n $1 ]]; do
Expand Down Expand Up @@ -78,6 +79,9 @@ while [[ -n $1 ]]; do
elif [[ $1 == --accounts-db-skip-shrink ]]; then
args+=("$1")
shift
elif [[ $1 == --skip-require-tower ]]; then
maybeRequireTower=false
shift
else
echo "Unknown argument: $1"
$program --help
Expand All @@ -102,8 +106,11 @@ ledger_dir="$SOLANA_CONFIG_DIR"/bootstrap-validator
exit 1
}

if [[ $maybeRequireTower = true ]]; then
args+=(--require-tower)
fi

args+=(
--require-tower
--ledger "$ledger_dir"
--rpc-port 8899
--snapshot-interval-slots 200
Expand Down
10 changes: 9 additions & 1 deletion multinode-demo/validator.sh
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,8 @@ EOF
exit 1
}

maybeRequireTower=true

positional_args=()
while [[ -n $1 ]]; do
if [[ ${1:0:1} = - ]]; then
Expand Down Expand Up @@ -158,6 +160,9 @@ while [[ -n $1 ]]; do
elif [[ $1 == --accounts-db-skip-shrink ]]; then
args+=("$1")
shift
elif [[ $1 == --skip-require-tower ]]; then
maybeRequireTower=false
shift
elif [[ $1 = -h ]]; then
usage "$@"
else
Expand Down Expand Up @@ -230,7 +235,10 @@ default_arg --identity "$identity"
default_arg --vote-account "$vote_account"
default_arg --ledger "$ledger_dir"
default_arg --log -
default_arg --require-tower

if [[ $maybeRequireTower = true ]]; then
default_arg --require-tower
fi

if [[ -n $SOLANA_CUDA ]]; then
program=$solana_validator_cuda
Expand Down
12 changes: 12 additions & 0 deletions net/net.sh
Original file line number Diff line number Diff line change
Expand Up @@ -309,7 +309,11 @@ startBootstrapLeader() {
${#clientIpList[@]} \"$benchTpsExtraArgs\" \
${#clientIpList[@]} \"$benchExchangeExtraArgs\" \
\"$genesisOptions\" \
<<<<<<< HEAD
\"$maybeNoSnapshot $maybeSkipLedgerVerify $maybeLimitLedgerSize $maybeWaitForSupermajority $maybeAccountsDbSkipShrink\" \
=======
\"$maybeNoSnapshot $maybeSkipLedgerVerify $maybeLimitLedgerSize $maybeWaitForSupermajority $maybeAllowPrivateAddr $maybeAccountsDbSkipShrink $maybeSkipRequireTower\" \
>>>>>>> 7d135f185 (Enable booting testnet validators without tower required (#19298))
\"$gpuMode\" \
\"$maybeWarpSlot\" \
\"$waitForNodeInit\" \
Expand Down Expand Up @@ -381,7 +385,11 @@ startNode() {
${#clientIpList[@]} \"$benchTpsExtraArgs\" \
${#clientIpList[@]} \"$benchExchangeExtraArgs\" \
\"$genesisOptions\" \
<<<<<<< HEAD
\"$maybeNoSnapshot $maybeSkipLedgerVerify $maybeLimitLedgerSize $maybeWaitForSupermajority $maybeAccountsDbSkipShrink\" \
=======
\"$maybeNoSnapshot $maybeSkipLedgerVerify $maybeLimitLedgerSize $maybeWaitForSupermajority $maybeAllowPrivateAddr $maybeAccountsDbSkipShrink $maybeSkipRequireTower\" \
>>>>>>> 7d135f185 (Enable booting testnet validators without tower required (#19298))
\"$gpuMode\" \
\"$maybeWarpSlot\" \
\"$waitForNodeInit\" \
Expand Down Expand Up @@ -783,6 +791,7 @@ maybeSkipLedgerVerify=""
maybeDisableAirdrops=""
maybeWaitForSupermajority=""
maybeAccountsDbSkipShrink=""
maybeSkipRequireTower=""
debugBuild=false
doBuild=true
gpuMode=auto
Expand Down Expand Up @@ -910,6 +919,9 @@ while [[ -n $1 ]]; do
elif [[ $1 = --accounts-db-skip-shrink ]]; then
maybeAccountsDbSkipShrink="$1"
shift 1
elif [[ $1 = --skip-require-tower ]]; then
maybeSkipRequireTower="$1"
shift 1
else
usage "Unknown long option: $1"
fi
Expand Down