Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 27 Dec 2022 21:34:25 +0100
From:      Mateusz Guzik <mjguzik@gmail.com>
To:        Mathias Picker <Mathias.Picker@virtual-earth.de>
Cc:        freebsd-jail@freebsd.org
Subject:   Re: debian jail, setting max open files soft limit does not work
Message-ID:  <CAGudoHFyUp-FXkk-1DC3LSS4tPOZUjVL3kPQERvEmidAFO0%2BDw@mail.gmail.com>
In-Reply-To: <86sfh0pquo.fsf@virtual-earth.de>
References:  <86sfh0pquo.fsf@virtual-earth.de>

next in thread | previous in thread | raw e-mail | index | archive | help
On 12/27/22, Mathias Picker <Mathias.Picker@virtual-earth.de> wrote:
> Hi all,
>
>
> I=E2=80=99ve set up a jail on 13.1 running debian stretch, and now a
> triplestore needing many openfiles for a data import.
>
> Since on Linux the soft limit is pretty hard :) I need to set the
> soft limit.
>
> I=E2=80=99ve edited /etc/security/limits.conf to set soft and hard limit
> to 20000 (just to check), but after login the soft limit stays at
> 1024.
>
> Using prlimit I can change the limits of a running process, but
> that is not passed on to subprocesses, which the app creates
> constantly for import, there, the soft limit returns to 1024 :(
>
> Running prlimit --nofile 20000 or prlimit --nofile 20000:20000
> does not work, either, the soft limit stays at 1024, and the
> import fails.
>
> Does anyone know a way to change the soft limit permenantly?
>

kernel code is buggy here, from a quick read you should be able to
work around it by:

sysctl compat.linux.default_openfiles=3D-1


--=20
Mateusz Guzik <mjguzik gmail.com>



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAGudoHFyUp-FXkk-1DC3LSS4tPOZUjVL3kPQERvEmidAFO0%2BDw>