The mongo daemon 7.0.11 only. Based on Rocky 9.4 with Bash, the Coreutils and other system tools
661
Because mongodb is an in-memory database, there are some Kernel Parameters that must be set somehow. The best way do this varies according to your use case ( e.g. kubernetes vs. Docker Compose ). Two choices are to run the container privileged for docker, or possibly to dedicate a node to mongodb in kube, and set these K-params on the tainted worker node.
Here are the settings:
echo 'never' > /sys/kernel/mm/transparent_hugepage/enabled && echo 'never' > /sys/kernel/mm/transparent_hugepage/defrag
check /proc/sys/fs/file-max
fs.file-max = 2097152
This file contains the maximum number of memory map areas a process may have. Memory map areas are used as a side-effect of calling malloc, directly by mmap and mprotect, and also when loading shared libraries. This is not the total memory mongod can have, but rather how many distinct regions in the heap that are available to mongod.
vm.max_map_count = 262144
turn off swapping altogether if the container runtime's host has it on in the first place
vm.swappiness = 0
podman run -it --rm -p 27017:27017 mongodb-server:7.0.11-0.5 /usr/bin/mongod -f /etc/mongod.conf
or:
podman run -it --rm -p 27017:27017 mongodb-server:7.0.11-0.5 /usr/bin/mongod --bind_ip_all
This image is not fully tested yet....
Content type
Image
Digest
sha256:59685adcf…
Size
73 MB
Last updated
over 2 years ago
docker pull optimoz/mongodb-server:7.0.11-0.5