[systemd-devel] SHM parameters on nspawn containers
Lennart Poettering
lennart at poettering.net
Thu Aug 27 11:18:50 PDT 2015
On Wed, 26.08.15 11:34, Chris Bell (cwbell at narmos.org) wrote:
> Hello all,
>
> I'm attempting to run GitLab (with postgresql) on a CentOS 7 container with
> systemd-nspawn. Postgre keeps failing, because it tries to allocate more
> shared memory than the container seems to allow. I cannot use sysctl to
> write the kernel.shmmax and kernel.shmall properties, since /sys isn't
> *real* (sysctl -w fails with 'read-only file system'). I have the values set
> correctly in the host machine, but they do not seem to propagate/be
> available to the container. Is there any way I can set (increase) the
> kernel.shmmax and kernel.shmall values in the container?
Hmm, one option would be to temporarily remount /proc/sys to writable
(mount /proc/sys -o rw,remount,bind) and make the change.
Would be happy to take a patch that automatically propagates these
values from the host into the container.
Lennart
--
Lennart Poettering, Red Hat
More information about the systemd-devel
mailing list