File tree Expand file tree Collapse file tree 2 files changed +18
-2
lines changed Expand file tree Collapse file tree 2 files changed +18
-2
lines changed Original file line number Diff line number Diff line change 189
189
fi
190
190
191
191
echo " Starting dockerd rootless"
192
- # dockerd ${DOCKERD_PARAMS} <&- &
192
+
193
+ if [ ! -f /sys/fs/cgroup/cgroup.controllers ]; then
194
+ echo " Using cgroup v1"
195
+ else
196
+ echo " Using cgroup v2"
197
+ CURRENT_CGROUP=$( cat /proc/self/cgroup | sed ' s/0:://' )
198
+ echo " Current cgroup: ${CURRENT_CGROUP} "
199
+
200
+ MEMORY_OOM_GROUP_VALUE=$( cat " /sys/fs/cgroup/${CURRENT_CGROUP} /memory.oom.group" )
201
+ echo " Current memory.oom.group value: ${MEMORY_OOM_GROUP_VALUE} "
202
+
203
+ if [[ " ${MEMORY_OOM_GROUP_VALUE} " == " 1" ]]; then
204
+ echo " Warning! memory.oom.group is set to 1 for the current cgroup, OOM events will not be handled properly by the platform. \
205
+ Set singleProcessOOMKill=true for kubelet configuration to fix it." 1>&2 ;
206
+ fi
207
+ fi
208
+
193
209
export DOCKERD_ROOTLESS_ROOTLESSKIT_FLAGS=" -p 0.0.0.0:1300:1300/tcp" # Expose rooltelsskit port
194
210
dockerd-entrypoint.sh dockerd ${DOCKERD_PARAMS} < & - &
195
211
Original file line number Diff line number Diff line change 1
- version : 3.0.2
1
+ version : 3.0.3
You can’t perform that action at this time.
0 commit comments