diff --git a/python/ray/worker.py b/python/ray/worker.py index a24f25e16..26ebd89c8 100644 --- a/python/ray/worker.py +++ b/python/ray/worker.py @@ -614,7 +614,7 @@ def init( logger.debug("Automatically increasing RLIMIT_NOFILE to max " "value of {}".format(hard)) try: - resource.setrlimit(resource.RLIMIT_NOFILE, (hard, hard)) + resource.setrlimit(resource.RLIMIT_NOFILE, (soft, hard)) except ValueError: logger.debug("Failed to raise limit.") soft, _ = resource.getrlimit(resource.RLIMIT_NOFILE)