]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
cephadm: set --ulimit nofiles with Docker 50890/head
authorMichal Nasiadka <mnasiadka@gmail.com>
Mon, 27 Feb 2023 08:15:50 +0000 (09:15 +0100)
committerAdam King <adking@redhat.com>
Wed, 5 Apr 2023 18:22:47 +0000 (14:22 -0400)
cephadm is setting LimitNOFILE in systemd units, but it doesn't
get picked up by Docker.

Fixes: https://tracker.ceph.com/issues/58855
Signed-off-by: Michal Nasiadka <mnasiadka@gmail.com>
(cherry picked from commit ce169004f749f088c4f05505b6457e7a190db680)

Conflicts:
src/cephadm/tests/test_cephadm.py

src/cephadm/cephadm

index dbe2e639b661455d16e4dcd0a1bb5695d64d2876..8595f72153c0de7485f6bd3e93fde3f5cea304f2 100755 (executable)
@@ -4018,6 +4018,9 @@ class CephContainer:
             if os.path.exists('/etc/ceph/podman-auth.json'):
                 cmd_args.append('--authfile=/etc/ceph/podman-auth.json')
 
+        if isinstance(self.ctx.container_engine, Docker):
+            cmd_args.extend(['--ulimit', 'nofile=1048576'])
+
         envs: List[str] = [
             '-e', 'CONTAINER_IMAGE=%s' % self.image,
             '-e', 'NODE_NAME=%s' % get_hostname(),