From b1451c8321727a8f67e65c81566bc0ed0c420515 Mon Sep 17 00:00:00 2001 From: Michael Krotscheck Date: Thu, 2 Jun 2016 10:48:39 -0700 Subject: [PATCH] Increased open file limits on debian systems This change is prompted by npm-based builds, which tends to open many files due to the 'microlibrary' approach that many javascript projects take. In particular, horizon's npm-based builds were running into this limit- while the tests were executing well, the file open limit was exceeded during report generation. This patch ups the soft limit from 1024 to 4096, and the hard limit from 4096 to 8192 on all debian systems. Change-Id: I8fc4a23eb34da88f7076a4c1ef2ec4c975dc450e --- modules/openstack_project/files/debian_limits.conf | 4 ++++ modules/openstack_project/manifests/template.pp | 8 ++++++++ 2 files changed, 12 insertions(+) create mode 100644 modules/openstack_project/files/debian_limits.conf diff --git a/modules/openstack_project/files/debian_limits.conf b/modules/openstack_project/files/debian_limits.conf new file mode 100644 index 0000000000..860c08b8d8 --- /dev/null +++ b/modules/openstack_project/files/debian_limits.conf @@ -0,0 +1,4 @@ +# Original 1024 +* soft nofile 4096 +# Original 4096 +* hard nofile 8192 diff --git a/modules/openstack_project/manifests/template.pp b/modules/openstack_project/manifests/template.pp index 87e0a9357a..7682e31d72 100644 --- a/modules/openstack_project/manifests/template.pp +++ b/modules/openstack_project/manifests/template.pp @@ -334,6 +334,14 @@ class openstack_project::template ( } } + file { '/etc/security/limits.d/60-nofile-limit.conf': + owner => 'root', + group => 'root', + mode => '0644', + source => 'puppet:///modules/openstack_project/debian_limits.conf', + replace => true, + } + file { '/etc/apt/apt.conf.d/80retry': owner => 'root', group => 'root',