From f840c0bf15adbbff197bf6b33aa235a7ff60628f Mon Sep 17 00:00:00 2001 From: Mike Reeves Date: Mon, 9 Apr 2018 21:33:30 -0400 Subject: [PATCH] Setup Script - Change function for calculating cores --- so-setup-network.sh | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/so-setup-network.sh b/so-setup-network.sh index 149aeeb85..45a61f909 100644 --- a/so-setup-network.sh +++ b/so-setup-network.sh @@ -26,9 +26,9 @@ LISTCORES=$(cat /proc/cpuinfo | grep processor | awk '{print $3 " \"" "core" "\" # Functions -bro_calculate_lbprocs() { +calculate_useable_cores() { #Calculate total lbprocs for basic install - local CORES4BRO=$(( $CPUCORES/2 )) + local CORES4BRO=$(( $CPUCORES/2 - 1 )) LBPROCS=$(printf "%.0f\n" $CORES4BRO) } @@ -649,6 +649,8 @@ if (whiptail_you_sure) then whiptail_management_server whiptail_nids whiptail_sensor_config + # Calculate bro lbprocs so we can call it in the prompts + calculate_useable_cores if [ $NSMSETUP == 'ADVANCED' ]; then whiptail_bro_pins whiptail_bond_nics_mtu