Increase Virtual Memory for Elasticsearch on GKE with cloud build

I have created multi-node cluster on GKE and I was using this shell script for fixing the virtual memory on nodes Set vm.max_map_count=262144 on the nodes of a GKE cluster #k8s · GitHub. I want it to be executed in my cloud builder but it just returns Permission denied (publickey). on gcloud compute ssh execution. How can I fix it?

Permission denied (publickey).

Looks like you must install valid SSH keys?

Note that there are other ways to solve this problem: Virtual memory | Elastic Cloud on Kubernetes [2.1] | Elastic.

thanks for your answer! Well, it was basically trying to ssh with root user, so I added my username before instance name and it worked just fine

also, for some reason solution with sysctl as InitContainer wasn't working, GKE was saying that it is forbidden to do sysctl

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