Skip to content
This repository has been archived by the owner on Jan 13, 2025. It is now read-only.

Commit

Permalink
fixups
Browse files Browse the repository at this point in the history
  • Loading branch information
rob-solana committed Jul 12, 2018
1 parent d70622b commit a3922d2
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions multinode-demo/common.sh
Original file line number Diff line number Diff line change
Expand Up @@ -107,12 +107,14 @@ tune_networking() {
# Reference: https://medium.com/@CameronSparr/increase-os-udp-buffers-to-improve-performance-51d167bb1360
[[ $(uname) = Linux ]] && (
set -x
set +e # these error out on WSL
# TODO: Check values and warn instead, it's a little rude to set them here.
sudo sysctl -w net.core.rmem_max=26214400 1>/dev/null 2>/dev/null
sudo sysctl -w net.core.rmem_default=26214400 1>/dev/null 2>/dev/null
:
# test the existence of the sysctls before trying to set them
sysctl net.core.rmem_max=26214400 2>/dev/null 1>/dev/null &&
sudo sysctl -w net.core.rmem_max=26214400 1>/dev/null 2>/dev/null

sysctl net.core.rmem_default=26214400 2>/dev/null 1>/dev/null &&
sudo sysctl -w net.core.rmem_default=26214400 1>/dev/null 2>/dev/null
)
return 0
}

SOLANA_CONFIG_DIR=${SNAP_DATA:-$PWD}/config
Expand Down

0 comments on commit a3922d2

Please sign in to comment.