* Enable booting testnet validators without tower required (#19298)
(cherry picked from commit 7d135f185c
)
# Conflicts:
# net/net.sh
* Fix conflicts
Co-authored-by: Tyera Eulberg <teulberg@gmail.com>
Co-authored-by: Tyera Eulberg <tyera@solana.com>
This commit is contained in:
@ -20,6 +20,7 @@ else
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
no_restart=0
|
no_restart=0
|
||||||
|
maybeRequireTower=true
|
||||||
|
|
||||||
args=()
|
args=()
|
||||||
while [[ -n $1 ]]; do
|
while [[ -n $1 ]]; do
|
||||||
@ -78,6 +79,9 @@ while [[ -n $1 ]]; do
|
|||||||
elif [[ $1 == --accounts-db-skip-shrink ]]; then
|
elif [[ $1 == --accounts-db-skip-shrink ]]; then
|
||||||
args+=("$1")
|
args+=("$1")
|
||||||
shift
|
shift
|
||||||
|
elif [[ $1 == --skip-require-tower ]]; then
|
||||||
|
maybeRequireTower=false
|
||||||
|
shift
|
||||||
else
|
else
|
||||||
echo "Unknown argument: $1"
|
echo "Unknown argument: $1"
|
||||||
$program --help
|
$program --help
|
||||||
@ -102,8 +106,11 @@ ledger_dir="$SOLANA_CONFIG_DIR"/bootstrap-validator
|
|||||||
exit 1
|
exit 1
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if [[ $maybeRequireTower = true ]]; then
|
||||||
|
args+=(--require-tower)
|
||||||
|
fi
|
||||||
|
|
||||||
args+=(
|
args+=(
|
||||||
--require-tower
|
|
||||||
--ledger "$ledger_dir"
|
--ledger "$ledger_dir"
|
||||||
--rpc-port 8899
|
--rpc-port 8899
|
||||||
--snapshot-interval-slots 200
|
--snapshot-interval-slots 200
|
||||||
|
@ -45,6 +45,8 @@ EOF
|
|||||||
exit 1
|
exit 1
|
||||||
}
|
}
|
||||||
|
|
||||||
|
maybeRequireTower=true
|
||||||
|
|
||||||
positional_args=()
|
positional_args=()
|
||||||
while [[ -n $1 ]]; do
|
while [[ -n $1 ]]; do
|
||||||
if [[ ${1:0:1} = - ]]; then
|
if [[ ${1:0:1} = - ]]; then
|
||||||
@ -158,6 +160,9 @@ while [[ -n $1 ]]; do
|
|||||||
elif [[ $1 == --accounts-db-skip-shrink ]]; then
|
elif [[ $1 == --accounts-db-skip-shrink ]]; then
|
||||||
args+=("$1")
|
args+=("$1")
|
||||||
shift
|
shift
|
||||||
|
elif [[ $1 == --skip-require-tower ]]; then
|
||||||
|
maybeRequireTower=false
|
||||||
|
shift
|
||||||
elif [[ $1 = -h ]]; then
|
elif [[ $1 = -h ]]; then
|
||||||
usage "$@"
|
usage "$@"
|
||||||
else
|
else
|
||||||
@ -230,7 +235,10 @@ default_arg --identity "$identity"
|
|||||||
default_arg --vote-account "$vote_account"
|
default_arg --vote-account "$vote_account"
|
||||||
default_arg --ledger "$ledger_dir"
|
default_arg --ledger "$ledger_dir"
|
||||||
default_arg --log -
|
default_arg --log -
|
||||||
default_arg --require-tower
|
|
||||||
|
if [[ $maybeRequireTower = true ]]; then
|
||||||
|
default_arg --require-tower
|
||||||
|
fi
|
||||||
|
|
||||||
if [[ -n $SOLANA_CUDA ]]; then
|
if [[ -n $SOLANA_CUDA ]]; then
|
||||||
program=$solana_validator_cuda
|
program=$solana_validator_cuda
|
||||||
|
@ -309,7 +309,7 @@ startBootstrapLeader() {
|
|||||||
${#clientIpList[@]} \"$benchTpsExtraArgs\" \
|
${#clientIpList[@]} \"$benchTpsExtraArgs\" \
|
||||||
${#clientIpList[@]} \"$benchExchangeExtraArgs\" \
|
${#clientIpList[@]} \"$benchExchangeExtraArgs\" \
|
||||||
\"$genesisOptions\" \
|
\"$genesisOptions\" \
|
||||||
\"$maybeNoSnapshot $maybeSkipLedgerVerify $maybeLimitLedgerSize $maybeWaitForSupermajority $maybeAccountsDbSkipShrink\" \
|
\"$maybeNoSnapshot $maybeSkipLedgerVerify $maybeLimitLedgerSize $maybeWaitForSupermajority $maybeAccountsDbSkipShrink $maybeSkipRequireTower\" \
|
||||||
\"$gpuMode\" \
|
\"$gpuMode\" \
|
||||||
\"$maybeWarpSlot\" \
|
\"$maybeWarpSlot\" \
|
||||||
\"$waitForNodeInit\" \
|
\"$waitForNodeInit\" \
|
||||||
@ -381,7 +381,7 @@ startNode() {
|
|||||||
${#clientIpList[@]} \"$benchTpsExtraArgs\" \
|
${#clientIpList[@]} \"$benchTpsExtraArgs\" \
|
||||||
${#clientIpList[@]} \"$benchExchangeExtraArgs\" \
|
${#clientIpList[@]} \"$benchExchangeExtraArgs\" \
|
||||||
\"$genesisOptions\" \
|
\"$genesisOptions\" \
|
||||||
\"$maybeNoSnapshot $maybeSkipLedgerVerify $maybeLimitLedgerSize $maybeWaitForSupermajority $maybeAccountsDbSkipShrink\" \
|
\"$maybeNoSnapshot $maybeSkipLedgerVerify $maybeLimitLedgerSize $maybeWaitForSupermajority $maybeAccountsDbSkipShrink $maybeSkipRequireTower\" \
|
||||||
\"$gpuMode\" \
|
\"$gpuMode\" \
|
||||||
\"$maybeWarpSlot\" \
|
\"$maybeWarpSlot\" \
|
||||||
\"$waitForNodeInit\" \
|
\"$waitForNodeInit\" \
|
||||||
@ -783,6 +783,7 @@ maybeSkipLedgerVerify=""
|
|||||||
maybeDisableAirdrops=""
|
maybeDisableAirdrops=""
|
||||||
maybeWaitForSupermajority=""
|
maybeWaitForSupermajority=""
|
||||||
maybeAccountsDbSkipShrink=""
|
maybeAccountsDbSkipShrink=""
|
||||||
|
maybeSkipRequireTower=""
|
||||||
debugBuild=false
|
debugBuild=false
|
||||||
doBuild=true
|
doBuild=true
|
||||||
gpuMode=auto
|
gpuMode=auto
|
||||||
@ -910,6 +911,9 @@ while [[ -n $1 ]]; do
|
|||||||
elif [[ $1 = --accounts-db-skip-shrink ]]; then
|
elif [[ $1 = --accounts-db-skip-shrink ]]; then
|
||||||
maybeAccountsDbSkipShrink="$1"
|
maybeAccountsDbSkipShrink="$1"
|
||||||
shift 1
|
shift 1
|
||||||
|
elif [[ $1 = --skip-require-tower ]]; then
|
||||||
|
maybeSkipRequireTower="$1"
|
||||||
|
shift 1
|
||||||
else
|
else
|
||||||
usage "Unknown long option: $1"
|
usage "Unknown long option: $1"
|
||||||
fi
|
fi
|
||||||
|
Reference in New Issue
Block a user