# Chatmail should not hardcode a static loadavg check by default

**URL:** <https://forum.delta.chat/t/chatmail-should-not-hardcode-a-static-loadavg-check-by-default/5606>\
**Category:** Chatmail Relays\
**Tags:** server-config, bug\
**Created:** [July 31, 2026, 12:16pm UTC](https://forum.delta.chat/t/chatmail-should-not-hardcode-a-static-loadavg-check-by-default/5606 "2026-07-31T12:16:34Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![ian](https://forum.delta.chat/user_avatar/forum.delta.chat/ian/32/3164_2.png) [@ian](https://forum.delta.chat/u/ian)\
**Post date:** [July 31, 2026, 12:16pm UTC](https://forum.delta.chat/t/chatmail-should-not-hardcode-a-static-loadavg-check-by-default/5606/1 "2026-07-31T12:16:34Z")

</div>

There are multiple problems with disabling registration when load average reached a static magic number such as `5`.

1. If the machine has 128 cores, it is perfectly normal to have a load average of 64. The installer should count the number of cores and may consider to use a multiple of that by default.

2. Virtual machines and commercial VPS can sometimes utilize containerization technology that shares the kernel with other services for improved efficiency, such as OpenVZ and LXC. In this case, you may sometimes see the loadavg for the host, not for your 1 or 2-core virtual CPU (unless you know they are using `lxcfs -l`).

3. Such servers can also be hardened in varied ways to provide a stable service level availability for each tenant, you could easily see the loadavg go up to the hundreds on a 16-core host even if your VPS seems quite responsive (while processed owned by the offending tenant would be crawling to a halt of course).

4. According to Wikipedia, Linux counts each thread individually of a multi-threaded process and includes processes which are running, ready to run and also those queued for uninterruptible sleep such as when doing I/O. Note that if one of your neighbor is executing buggy code, this could even happen when no active I/O is happening.

5. The operator should have an option to disable each of these checks. This is done in various ways, such as unassigning it, assigning it the empty string, infinity, `-1`, `0`. No such outlier value is supported at present, so the only workaround is to assign it a very high “infinite” constant such as `9999`.

> **[Load (computing)](https://en.wikipedia.org/wiki/Load_(computing))**
>
> In UNIX computing, the system load is a measure of the amount of computational work that a computer system performs. The load average represents the average system load over a period of time. It conventionally appears in the form of three numbers which represent the system load during the last one-, five-, and fifteen-minute periods. The Unix load number refers to the number of processes using or waiting for CPU; i.e., the number of processes in the ready queue or run queue. An idle computer ...

> **[Release New System Limits for Address Creation · chatmail/relay](https://github.com/chatmail/relay/releases/tag/1.12.0)**
>
> The most important change is that there are five new config parameters for system limits. If they are reached, users can't create new addresses on your relay anymore. The parameters are documented ...

> **[chatmail.ini - Setting up a chatmail relay - chatmail relay documentation](https://chatmail.at/doc/relay/getting_started.html#configurable-system-limits)**
>
> This section contains everything needed to setup a ready-to-use chatmail relay. The automated setup is designed and optimized for providing chatmail addresses for immediate permission-free onboarding through chat apps and bots. Chatmail addresses are...

> If they are reached, users can’t create new addresses on your relay:  
> max\_load\_1m = 5

---

<div class="post-metadata">

**Author:** ![punkero](https://forum.delta.chat/user_avatar/forum.delta.chat/punkero/32/3455_2.png) [@punkero](https://forum.delta.chat/u/punkero)\
**Post date:** [August 1, 2026, 9:40am UTC](https://forum.delta.chat/t/chatmail-should-not-hardcode-a-static-loadavg-check-by-default/5606/2 "2026-08-01T09:40:03Z")

</div>

Workaround comment: a “typical” pattern used is to allow a setting of 0 to disable the check(s); a peruse of [the commit](https://github.com/chatmail/relay/commit/fa5afadaaa6b7859c3adb3554f1f14f2c3100ce7#diff-8f2bedd9ade52320f81f249f0da21a9f6c6ed140e5890589e382eea66f9f89f2) seems to show that unset (is not None) or 0 will not be not valid. Setting it to 9999 probably works to negate a false positive as that’s what’s used in the test suite added to force a test result.
