Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 5 Jan 2017 11:53:55 -0700
From:      markham breitbach <markham@ssimicro.com>
To:        freebsd-questions@freebsd.org, freebsd-jail <freebsd-jail@freebsd.org>
Subject:   Resource Limits Within Jails
Message-ID:  <118410c1-1e3e-2388-ea5b-682515bc39f1@ssimicro.com>

next in thread | raw e-mail | index | archive | help
I am trying to figure out the best way to manage resource limits for a
particular daemon within a jail (specifically memory usage), without
having to limit the entire jail and other processes within.

I have searched around and looked at the handbook and man pages for rctl
and login.conf, but neither seems to really do what I want.

rctl only seems to be able to operate from the jail host, and afaik can
only limit a process once you have the PID, so you can't just set it
somewhere and be done with it.  rctl user limits only apply to the host,
and not the same user within a jail, and I have not even investigated
how that behaves for a process that has started as root and done a
privilege drop.

Similarly, login.conf seems to have no effect whatsoever within a jail,
even after restarting the jail and logging in again.

Is there something I am missing?  Does anyone know how to do this?

Thanks,

-Markham






Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?118410c1-1e3e-2388-ea5b-682515bc39f1>