Exceeding System Limit of Network Connections#
Clusters with a large number of nodes (e.g., many hundreds or more) may observe
a problem when executing a workload that attempts to communicate concurrently
with many or most of the nodes,
such as scyld-nodectl --up exec
or mpirun
executing a multi-threaded,
multi-node application.
The problem exhibits itself with an error message that refers to being unable
to allocate a TCP/IP socket or network connection,
or arp_cache reporting a "neighbor table overflow!" error.
A possible solution is to increase the number of available "neighbor" entries.
These are managed by a coordinated increase of gc_thresh1
,
gc_thresh2
, and gc_thresh3
values.
See https://www.kernel.org/doc/Documentation/networking/ip-sysctl.txt for
the semantics of these variables.
See the current values with:
sysctl net.ipv4.neigh.default.gc_thresh1
sysctl net.ipv4.neigh.default.gc_thresh2
sysctl net.ipv4.neigh.default.gc_thresh3
Default CentOS/RHEL values are 128, 512, and 1024, respectively. Experiment with higher values until your workloads are all successful. For example:
sudo sysctl -w net.ipv4.neigh.default.gc_thresh1=2048
sudo sysctl -w net.ipv4.neigh.default.gc_thresh2=4096
sudo sysctl -w net.ipv4.neigh.default.gc_thresh3=8192
See man sysctl.conf
for how to make the successful values persistent
across a reboot by putting them in a new /etc/sysctl.d/
file.