Hi, I have a rather busy network, and my ksoftirqd processes are using quite a lot of CPU. I'm trying to optimize my NIC settings, but I think I can't get any better unless I change hardware.
However, I want to make sure I prioritize CPU power for the ksoftirqd processes because I noticed that if by any chance another process runs on any of my 8 cores at a high rate (100% CPU) then the network usually lags for a short while (ping latency soars, etc). For instance, whenever I run "shorewall reload" one of the cores goes up to 100% (perl) for about a minute. During this time frame I can see higher ping latency values for the shorewall itself and for any hosts pinging each other within different zones. I don't need shorewall to run as fast as possible. In fact, I don't need any user-space process to be super responsive (not even Squid TPROXY running on the FW). I just need to make sure there's as little latency as possible. I'm assuming ksoftirqd is running in kernel space. These are my ksoftirqd processes as seen by ps: # ps aux | grep ksoftirqd root 3 1.8 0.0 0 0 ? S Oct10 491:07 [ksoftirqd/0] root 14 3.3 0.0 0 0 ? S Oct10 882:37 [ksoftirqd/1] root 19 1.8 0.0 0 0 ? S Oct10 480:21 [ksoftirqd/2] root 24 2.9 0.0 0 0 ? S Oct10 761:07 [ksoftirqd/3] root 29 1.6 0.0 0 0 ? S Oct10 442:00 [ksoftirqd/4] root 34 2.9 0.0 0 0 ? S Oct10 769:23 [ksoftirqd/5] root 39 3.0 0.0 0 0 ? S Oct10 805:36 [ksoftirqd/6] root 44 7.4 0.0 0 0 ? S Oct10 1946:10 [ksoftirqd/7] top's PR value is 20 for both ksoftirqd and most "normal"/user-space processes. The lower the PR value the higher the priority, right? top's NI value (niceness?) is 0 for ksoftirqd and most "normal"/user-space processes. # chrt -p 3 pid 3's current scheduling policy: SCHED_OTHER pid 3's current scheduling priority: 0 The value of "scheduling priority" (0) reported by chrt confuses me. Shouldn't it have been 20 + 0 = 20? Also, my Shorewall router's kernel has these PREEMPT settings: # grep PREEMPT /usr/src/linux/.config CONFIG_PREEMPT_NONE=y # CONFIG_PREEMPT_VOLUNTARY is not set # CONFIG_PREEMPT is not set 1) Has anyone tried rebuilding the kernel with "Preemptible Kernel (Low-Latency Desktop)" on a Shorewall router? Do you think the CONFIG_PREEMPT* values should be set to some specific values in the case of a router? 2) If I leave the kernel untouched, I'm tempted to try something like: chrt -f -p 20 $pid_of_ksoftirqd That should change the scheduling policy to SCHED_FIFO. Does that make sense? Any undesired side-effects? Vieri _______________________________________________ Shorewall-users mailing list Shorewall-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/shorewall-users