Hello, since a while back, there was a commit (haven't found it) which
limits the number of children/workers to 8 + <num_cpu> * 2, which in a
normal case like a 4 core/cpu machine is 16 children/workers.

This limit is way too low even for a single core VM, that actually
means 10 children/workers.

I've attached the patch which increased this number to 8 + <num_cpu> *
256, which is 1032 for a 4 core/cpu machine and 264 for a
single core/cpu machine.

Also the patch changes the logging level of 'maximum number of children
reached' to an error, this should be visible as an error when the
number has been reached.

Reference bug: http://bugzilla.opensuse.org/show_bug.cgi?id=907393

-- 
Robert Milasan

L3 Support Engineer
SUSE Linux (http://www.suse.com)
email: rmila...@suse.com
GPG fingerprint: B6FE F4A8 0FA3 3040 3402  6FE7 2F64 167C 1909 6D1A
>From 4fb50b784c7aa6f5ea9cdf2e5a65ba48a2b9ce1b Mon Sep 17 00:00:00 2001
From: Robert Milasan <rmila...@suse.com>
Date: Fri, 28 Nov 2014 08:49:38 +0100
Subject: [PATCH] udevd: increase maximum number of children

Signed-off-by: Robert Milasan <rmila...@suse.com>
---
 src/udev/udevd.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/udev/udevd.c b/src/udev/udevd.c
index 3c3de76..c327c38 100644
--- a/src/udev/udevd.c
+++ b/src/udev/udevd.c
@@ -445,7 +445,7 @@ static void event_run(struct event *event) {
 
         if (children >= arg_children_max) {
                 if (arg_children_max > 1)
-                        log_debug("maximum number (%i) of children reached", children);
+                        log_error("maximum number (%i) of children reached", children);
                 return;
         }
 
@@ -1270,7 +1270,7 @@ int main(int argc, char *argv[]) {
                 arg_children_max = 8;
 
                 if (sched_getaffinity(0, sizeof (cpu_set), &cpu_set) == 0) {
-                        arg_children_max +=  CPU_COUNT(&cpu_set) * 2;
+                        arg_children_max += CPU_COUNT(&cpu_set) * 256;
                 }
         }
         log_debug("set children_max to %u", arg_children_max);
-- 
1.8.4.5

_______________________________________________
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/systemd-devel

Reply via email to