[Tarantool-patches] [PATCH v1 1/1] gitlab-ci: correct OSX limits setup
Alexander V. Tikhonov
avtikhon at tarantool.org
Mon Apr 13 12:59:09 MSK 2020
Limits values can reach the maximum range of the system wide
limits set in kernel (Kernel value >= hard limit >= soft limit):
MAX_FILES <= `sysctl -n kern.maxfilesperproc`
MAX_PROC <= `sysctl -n kern.maxprocperuid`
Part of #4883
---
Github: https://github.com/tarantool/tarantool/tree/avtikhon/osx_15_catalina-full-ci
Issue: https://github.com/tarantool/tarantool/issues/4883
.travis.mk | 24 +++++++++---------------
1 file changed, 9 insertions(+), 15 deletions(-)
diff --git a/.travis.mk b/.travis.mk
index f709a18b6..001752844 100644
--- a/.travis.mk
+++ b/.travis.mk
@@ -4,8 +4,13 @@
DOCKER_IMAGE?=packpack/packpack:debian-stretch
TEST_RUN_EXTRA_PARAMS?=
-MAX_FILES?=65534
-MAX_PROC?=2500
+# limit values can reach the maximum range
+# of the system wide limits set in kernel:
+# Kernel value >= hard limit >= soft limit:
+# kern.maxfiles >= kern.maxfilesperproc >= ulimit -H -n >= ulimit -n
+# kern.maxproc >= kern.maxprocperuid >= ulimit -H -n >= ulimit -n
+MAX_FILES?=$(shell sysctl -n kern.maxfilesperproc)
+MAX_PROC?=$(shell sysctl -n kern.maxprocperuid)
all: package
@@ -171,22 +176,11 @@ build_osx:
make -j
test_osx_no_deps: build_osx
- # Limits: Increase the maximum number of open file descriptors on macOS:
- # Travis-ci needs the "ulimit -n <value>" call
- # Gitlab-ci needs the "launchctl limit maxfiles <value>" call
- # Also gitlib-ci needs the password to change the limits, while
- # travis-ci runs under root user. Limit setup must be in the same
- # call as tests runs call.
# Tests: Temporary excluded replication/ suite with some tests
# from other suites by issues #4357 and #4370
- sudo -S launchctl limit maxfiles ${MAX_FILES} || : ; \
- launchctl limit maxfiles || : ; \
- ulimit -n ${MAX_FILES} || : ; \
- ulimit -n ; \
- sudo -S launchctl limit maxproc ${MAX_PROC} || : ; \
- launchctl limit maxproc || : ; \
+ ulimit -n ${MAX_FILES} || : ; \
ulimit -u ${MAX_PROC} || : ; \
- ulimit -u ; \
+ ulimit -H -a ; ulimit -a ; \
rm -rf /tmp/tnt ; \
cd test && ./test-run.py --vardir /tmp/tnt --force $(TEST_RUN_EXTRA_PARAMS) \
app/ app-tap/ box/ box-py/ box-tap/ engine/ engine_long/ long_run-py/ luajit-tap/ \
--
2.17.1
More information about the Tarantool-patches
mailing list