From: John Mulligan Date: Tue, 1 Nov 2022 14:03:31 +0000 (-0400) Subject: quincy: run-make-check: use get_processors in run-make-check script X-Git-Tag: v17.2.8~72^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=62ed1f143c86aea9f4302bf1712d3cffd8e16d3b;p=ceph.git quincy: run-make-check: use get_processors in run-make-check script Signed-off-by: John Mulligan (cherry picked from commit 7edc4309f4781362f86fd83fd2d53eba42e5f73f) Conflicts: run-make-check.sh --- diff --git a/run-make-check.sh b/run-make-check.sh index abe1670f5660..f8ff3d898360 100755 --- a/run-make-check.sh +++ b/run-make-check.sh @@ -37,10 +37,14 @@ function run() { # increase the aio-max-nr, which is by default 65536. we could reach this # limit while running seastar tests and bluestore tests. local m=16 - if [ $(nproc) -gt $m ]; then - m=$(nproc) + local procs="$(($(get_processors) * 2))" + if [ "${procs}" -gt $m ]; then + m="${procs}" + fi + local aiomax="$((65536 * procs))" + if [ "$(/sbin/sysctl -n fs.aio-max-nr )" -lt "${aiomax}" ]; then + $DRY_RUN sudo /sbin/sysctl -q -w fs.aio-max-nr="${aiomax}" fi - $DRY_RUN sudo /sbin/sysctl -q -w fs.aio-max-nr=$((65536 * $(nproc))) CHECK_MAKEOPTS=${CHECK_MAKEOPTS:-$DEFAULT_MAKEOPTS} if in_jenkins; then