aboutsummaryrefslogtreecommitdiff
path: root/units
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2018-10-01 18:08:27 +0200
committerLennart Poettering <lennart@poettering.net>2018-10-16 16:33:55 +0200
commitc35ee02c61d17b0656e16b0b2fa0449bda9df507 (patch)
tree859db77c0f36b0207d65e32ac5358f7fb6562d9c /units
parentcore: raise the RLIMIT_NOFILE hard limit for all services by default (diff)
downloadsystemd-c35ee02c61d17b0656e16b0b2fa0449bda9df507.tar.gz
systemd-c35ee02c61d17b0656e16b0b2fa0449bda9df507.tar.bz2
systemd-c35ee02c61d17b0656e16b0b2fa0449bda9df507.zip
units: bump the RLIMIT_NOFILE soft limit for all services that access the journal
This updates the unit files of all our serviecs that deal with journal stuff to use a higher RLIMIT_NOFILE soft limit by default. The new value is the same as used for the new HIGH_RLIMIT_NOFILE we just added. With this we ensure all code that access the journal has higher RLIMIT_NOFILE. The code that runs as daemon via the unit files, the code that is run from the user's command line via C code internal to the relevant tools. In some cases this means we'll redundantly bump the limits as there are tools run both from the command line and as service.
Diffstat (limited to 'units')
-rw-r--r--units/systemd-journal-gatewayd.service.in6
-rw-r--r--units/systemd-journal-remote.service.in4
-rw-r--r--units/systemd-journal-upload.service.in6
-rw-r--r--units/systemd-journald.service.in8
-rw-r--r--units/systemd-logind.service.in6
5 files changed, 16 insertions, 14 deletions
diff --git a/units/systemd-journal-gatewayd.service.in b/units/systemd-journal-gatewayd.service.in
index 9768928c5..7530d4c2d 100644
--- a/units/systemd-journal-gatewayd.service.in
+++ b/units/systemd-journal-gatewayd.service.in
@@ -30,9 +30,9 @@ RestrictAddressFamilies=AF_UNIX AF_INET AF_INET6
SystemCallArchitectures=native
LockPersonality=yes
-# If there are many split upjournal files we need a lot of fds to
-# access them all and combine
-LimitNOFILE=16384
+# If there are many split up journal files we need a lot of fds to access them
+# all in parallel.
+LimitNOFILE=262144
[Install]
Also=systemd-journal-gatewayd.socket
diff --git a/units/systemd-journal-remote.service.in b/units/systemd-journal-remote.service.in
index a94265f21..c1de676b5 100644
--- a/units/systemd-journal-remote.service.in
+++ b/units/systemd-journal-remote.service.in
@@ -32,5 +32,9 @@ SystemCallArchitectures=native
LockPersonality=yes
LogsDirectory=journal/remote
+# If there are many split up journal files we need a lot of fds to access them
+# all in parallel.
+LimitNOFILE=262144
+
[Install]
Also=systemd-journal-remote.socket
diff --git a/units/systemd-journal-upload.service.in b/units/systemd-journal-upload.service.in
index 42da70f47..b6920094f 100644
--- a/units/systemd-journal-upload.service.in
+++ b/units/systemd-journal-upload.service.in
@@ -32,9 +32,9 @@ SystemCallArchitectures=native
LockPersonality=yes
StateDirectory=systemd/journal-upload
-# If there are many split up journal files we need a lot of fds to
-# access them all and combine
-LimitNOFILE=16384
+# If there are many split up journal files we need a lot of fds to access them
+# all in parallel.
+LimitNOFILE=262144
[Install]
WantedBy=multi-user.target
diff --git a/units/systemd-journald.service.in b/units/systemd-journald.service.in
index 52939e682..2c09a8b35 100644
--- a/units/systemd-journald.service.in
+++ b/units/systemd-journald.service.in
@@ -35,8 +35,6 @@ SystemCallArchitectures=native
LockPersonality=yes
IPAddressDeny=any
-# Increase the default a bit in order to allow many simultaneous
-# services being run since we keep one fd open per service. Also, when
-# flushing journal files to disk, we might need a lot of fds when many
-# journal files are combined.
-LimitNOFILE=16384
+# If there are many split up journal files we need a lot of fds to access them
+# all in parallel.
+LimitNOFILE=262144
diff --git a/units/systemd-logind.service.in b/units/systemd-logind.service.in
index 5e090bcf2..8b264ff29 100644
--- a/units/systemd-logind.service.in
+++ b/units/systemd-logind.service.in
@@ -37,6 +37,6 @@ LockPersonality=yes
IPAddressDeny=any
FileDescriptorStoreMax=512
-# Increase the default a bit in order to allow many simultaneous
-# logins since we keep one fd open per session.
-LimitNOFILE=16384
+# Increase the default a bit in order to allow many simultaneous logins since
+# we keep one fd open per session.
+LimitNOFILE=262144