Database installation container Oracle Postgresql

Good Afternoon,
I am trying to install Oracle DB 12c in a container.
Host: Ubuntu 18.04.1
LXC Client version: 3.0.3
LXC Server version: 3.0.3
I could as well go for Postgresql.

Database processing > 100 Millions records needs to have several kernel parameters setup properly.

kernel.shmall = 1073741824
kernel.shmmax = 4398046511104
kernel.panic_on_oops = 1
kernel.shmmni = 4096
kernel.sem = 250 32000 100 128
fs.file-max = 6815744
fs.aio-max-nr = 1048576
net.ipv4.ip_local_port_range = 9000 65500
net.core.rmem_default = 262144
net.core.rmem_max = 4194304
net.core.wmem_default = 262144
net.core.wmem_max = 1048576

I have tried I believe all possible setup.
“Privileged” “Not priviledged”
Apparmor disabled on host
Different containers Oracle linux 7, Centos 7

Two questions
Is it a good idea to setup a Database inside a container?
Do some people have experience with DB setup inside a container? How did they get control over those parameters? Unfortunately, even when those parameters are properly setup on the host, they are not inherited in the container.




As far as I know, a few sysctl parameters can be set inside the LXD containers and can override those set on the host, the rest will be inherited. I don’t have a list or a way to know it unless to test and verify which ones are available to change.

I have run large MySQL database instances inside LXD containers without a problem.