There it is claimed that Arch's default is 1073741816, which matches your number above. A bug was filed against mariadb, which has the same behavior you described with mysql here:
All that being said, this works fine when the host is Ubuntu, because the limits are set to lower values there by default. One could still argue that mysql is running on Ubuntu, just with an "odd" non-ubuntu kernel, and that it shouldn't allocate memory like that.
Since the LimitNOFILE=5000 isn't applied, the process gets whatever default the host has. In this case, Arch's kernel, since this is an LXC container.
Aug 08 18:19:23 mysql57 bash[13131]: open files (-n) 1073741816 <--- see this?
You probably have the same value on the host. I've seen another bug recently that involved arch linux and high limits: https:/ /github. com/kubernetes- sigs/kind/ pull/760
There it is claimed that Arch's default is 1073741816, which matches your number above. A bug was filed against mariadb, which has the same behavior you described with mysql here:
https:/ /jira.mariadb. org/browse/ MDEV-18360
The same code is in mysql 5.7
All that being said, this works fine when the host is Ubuntu, because the limits are set to lower values there by default. One could still argue that mysql is running on Ubuntu, just with an "odd" non-ubuntu kernel, and that it shouldn't allocate memory like that.