Update default values for docker nofile and vm.max_map_count
Task: 40801 Story: 2008098 Change-Id: I1802e4002d9aa89a321f130a16fd8021a773b73a
This commit is contained in:
parent
cbf0a3924c
commit
385bc9700b
|
@ -28,6 +28,9 @@ configure_storage_driver_generic() {
|
|||
fi
|
||||
if [ ${CONTAINER_RUNTIME} = "host-docker" ] ; then
|
||||
sed -i -E 's/^OPTIONS=("|'"'"')/OPTIONS=\1--storage-driver='$1' /' /etc/sysconfig/docker
|
||||
# NOTE(flwang): The default nofile limit it too low, update it to
|
||||
# match the default value in containerd
|
||||
sed -i -E 's/--default-ulimit nofile=1024:1024/--default-ulimit nofile=1048576:1048576/' /etc/sysconfig/docker
|
||||
fi
|
||||
}
|
||||
|
||||
|
|
|
@ -29,6 +29,10 @@ _addtl_mounts=',{"type":"bind","source":"/opt/cni","destination":"/opt/cni","opt
|
|||
|
||||
if [ "$NETWORK_DRIVER" = "calico" ]; then
|
||||
echo "net.ipv4.conf.all.rp_filter = 1" >> /etc/sysctl.conf
|
||||
# NOTE(flwang): The default value for vm.max_map_count is too low, update
|
||||
# it to 262144 to meet the minium requirement of Elasticsearch
|
||||
echo "vm.max_map_count = 262144" >> /etc/sysctl.conf
|
||||
|
||||
$ssh_cmd sysctl -p
|
||||
if [ "$($ssh_cmd systemctl status NetworkManager.service | grep -o "Active: active")" = "Active: active" ]; then
|
||||
CALICO_NM=/etc/NetworkManager/conf.d/calico.conf
|
||||
|
|
Loading…
Reference in New Issue