Yes, simple. Don't run out of memory.Does anybody know how to protect daemon in jail from OOM Killer?
# protect -p $<pid of mysql daemon>
.It is documented now in protect(1) (see https://cgit.freebsd.org/src/commit/?id=6452fb1e87ed9d00b52fa1e63e7c3a7516c9586c).The OOM protection is done by procctl(2) in the background used by the protect(1) command. This tracing is not allowed in jails for security reasons.
Is that really a bug? There's not much one can do in such a situation, right? It's basically inevitable?