[SOLVED] Vm.max_map_count sysctl parameter

Hi forum people,

I have changed a container sysctl setting and now I get the following error. The parameter that was changed by me is ’ vm.max_map_count’. Here is the command that I applied with. Thanks.

lxc config set elasticsearch raw.lxc 'lxc.sysctl.vm.max_map_count = 262144'

Name: elasticsearch
Location: none
Remote: unix://
Architecture: x86_64
Created: 2020/05/17 10:51 UTC
Status: Stopped
Type: container
Profiles: default

Log:

lxc elasticsearch 20200517113240.680 ERROR    cgfsng - cgroups/cgfsng.c:mkdir_eexist_on_last:1143 - File exists - Failed to create directory "/sys/fs/cgroup/cpuset//lxc.monitor.elasticsearch"
lxc elasticsearch 20200517113240.684 ERROR    cgfsng - cgroups/cgfsng.c:mkdir_eexist_on_last:1143 - File exists - Failed to create directory "/sys/fs/cgroup/cpuset//lxc.payload.elasticsearch"
lxc elasticsearch 20200517113240.697 WARN     cgfsng - cgroups/cgfsng.c:fchowmodat:1455 - No such file or directory - Failed to fchownat(17, memory.oom.group, 1000000000, 0, AT_EMPTY_PATH | AT_SYMLINK_NOFOLLOW )
lxc elasticsearch 20200517113240.828 ERROR    conf - conf.c:setup_sysctl_parameters:2467 - Permission denied - Failed to setup sysctl parameters vm.max_map_count to 262144
lxc elasticsearch 20200517113240.828 ERROR    conf - conf.c:lxc_setup:3437 - Failed to setup sysctl parameters
lxc elasticsearch 20200517113240.828 ERROR    start - start.c:do_start:1224 - Failed to setup container "elasticsearch"
lxc elasticsearch 20200517113240.828 ERROR    sync - sync.c:__sync_wait:41 - An error occurred in another process (expected sequence number 5)
lxc elasticsearch 20200517113240.833 WARN     network - network.c:lxc_delete_network_priv:3213 - Failed to rename interface with index 0 from "eth0" to its initial name "vethe359ea4b"
lxc elasticsearch 20200517113240.834 ERROR    lxccontainer - lxccontainer.c:wait_on_daemonized_start:850 - Received container state "ABORTING" instead of "RUNNING"
lxc elasticsearch 20200517113240.834 ERROR    start - start.c:__lxc_start:1945 - Failed to spawn container "elasticsearch"
lxc elasticsearch 20200517113240.834 WARN     start - start.c:lxc_abort:1018 - No such process - Failed to send SIGKILL via pidfd 30 for process 369570
lxc 20200517113241.840 WARN     commands - commands.c:lxc_cmd_rsp_recv:122 - Connection reset by peer - Failed to receive response for command "get_state"

Here I unset the container sysctl parameter and set the host parameter solved the case. Indeed dont know that action is the right thing or not.
Thanks.