Can i set vm.max_map_count at creation?

I am getting this error: max virtual memory areas vm.max_map_count [65530] is too low, increase to at least [262144] The research I've done shows that once elasticsearch is running, I could go in and raise the limit by using sysctl -w vm.max_map_count=262144. This isn't great for my setup though since I am trying to wrap everything up in a helm chart and want to be able to fire it up and have all the configurations set in advance. Is there anywhere I ca place this setting so that when elasticsearch starts, it has the correct vm setting?

1 Like

we solved this with an init container:

      - name: sysctl
         image: busybox
         imagePullPolicy: IfNotPresent
         command: ["sysctl", "-w", "vm.max_map_count=262144"]
         securityContext: {"privileged": true}

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.