When a pod requests a e.g. glusterfs, kubelet mounter will in the end invoke the glusterfs mount daemon. The daemon stays till the volume is unmounted. If systemd stops kubelet with killMode=control-group (the default), both kubelet and glusterfs daemon is killed, while the container stays alive with a broken bind mount. When systemd starts kubelet again, even though kubelet is able to re-mount the volume, the broken bind mount in the container cannot be repaired. This is what happened in #13511
When a pod requests a e.g. glusterfs, kubelet mounter will in the end invoke the glusterfs mount daemon. The daemon stays till the volume is unmounted. If systemd stops kubelet with killMode=control-group (the default), both kubelet and glusterfs daemon is killed, while the container stays alive with a broken bind mount. When systemd starts kubelet again, even though kubelet is able to re-mount the volume, the broken bind mount in the container cannot be repaired. This is what happened in #13511

The proposed fix is to tell systemd to just kill kubelet and leave other processes alive by setting killMode=process, the glusterfs daemon stays with the container when kubelet is stopped.

Signed-off-by: Huamin Chen <189ba2094394fe2405c0b389ea871c17bd3a5861@redhat.com>

devlinmr/contrib,hongchaodeng/contrib,devlinmr/contrib,krousey/contrib,caesarxuchao/contrib,moul/contrib,fcvarela/contrib,danushkaf/contrib,lavalamp/contrib,danehans/contrib,eastbanctech/kubernetes-contrib,simonswine/kubernetes-contrib,moul/contrib,widgetpl/contrib,widgetpl/contrib,vishpat/contrib,eparis/contrib,widgetpl/contrib,mikedanese/contrib,chiradeep/contrib,xialonglee/contrib,devlinmr/contrib,marketlogicsoftware/contrib,widgetpl/contrib,vishpat/contrib,verb/contrib,xialonglee/contrib,timstclair/kube-contrib,lewislyou/contrib,kow3ns/contrib,jcmoraisjr/k8s-contrib,pwittrock/contrib,devlinmr/contrib,gouyang/contrib,aknuds1/contrib,Pensu/contrib,atosatto/kubernetes-contrib,jasonbrooks/contrib,olark/kubernetes-contrib,Q-Lee/contrib,spxtr/contrib,gouyang/contrib,stephenrlouie/contrib,grodrigues3/contrib,jdavis7257/contrib,ixdy/kubernetes-contrib,endocode/contrib,upmc-enterprises/contrib,andrew-j-price/contrib,upmc-enterprises/contrib,rmmh/kubernetes-contrib,ingvagabund/contrib,endocode/contrib,upmc-enterprises/contrib,gemini-project/contrib,hongchaodeng/contrib,xialonglee/contrib,Wattpad/kubernetes-contrib,danushkaf/contrib,krousey/contrib,fcvarela/contrib,jdavis7257/contrib,aknuds1/contrib,marketlogicsoftware/contrib,aledbf/contrib,upmc-enterprises/contrib,kokhang/contrib,andrew-j-price/contrib,mikedanese/contrib,adamschaub/contrib,jcmoraisjr/k8s-contrib,foxish/contrib,pwittrock/contrib,spxtr/contrib,aknuds1/contrib,Wattpad/kubernetes-contrib,gmarek/contrib,rmmh/kubernetes-contrib,hongchaodeng/contrib,chiradeep/contrib,aledbf/contrib,pwittrock/contrib,ingvagabund/contrib,atosatto/kubernetes-contrib,aknuds1/contrib,danehans/contrib,thockin/contrib,krousey/contrib,vishpat/contrib,kokhang/contrib,lewislyou/contrib,Pensu/contrib,moul/contrib,k8s-packages-power/contrib,piosz/contrib,cdemers/contrib,rmmh/kubernetes-contrib,kow3ns/contrib,luxas/contrib,marketlogicsoftware/contrib,endocode/contrib,thockin/contrib,olark/kubernetes-contrib,olark/kubernetes-contrib,danushkaf/contrib,aknuds1/contrib,Wattpad/kubernetes-contrib,pwittrock/contrib,luxas/contrib,jasonbrooks/contrib,jdavis7257/contrib,kow3ns/contrib,lavalamp/contrib,girishkalele/contrib,mikedanese/contrib,atosatto/kubernetes-contrib,lavalamp/contrib,fcvarela/contrib,krousey/contrib,adamschaub/contrib,marketlogicsoftware/contrib,jasonbrooks/contrib,lewislyou/contrib,aledbf/contrib,piosz/contrib,micheleorsi/contrib,danehans/contrib,eastbanctech/kubernetes-contrib,k8s-packages-power/contrib,krzyzacy/contrib,x13n/contrib,cdemers/contrib,gmarek/contrib,eparis/contrib,vishpat/contrib,foxish/contrib,rchicoli/kubernetes-contrib,jojimt/contrib,jcmoraisjr/k8s-contrib,timstclair/kube-contrib,k8s-packages-power/contrib,ingvagabund/contrib,gouyang/contrib,jojimt/contrib,fcvarela/contrib,Pensu/contrib,stephenrlouie/contrib,hongchaodeng/contrib,grodrigues3/contrib,vishpat/contrib,chiradeep/contrib,lewislyou/contrib,x13n/contrib,verb/contrib,rmmh/kubernetes-contrib,hongchaodeng/contrib,chiradeep/contrib,freehan/contrib,adamschaub/contrib,widgetpl/contrib,girishkalele/contrib,marketlogicsoftware/contrib,hongchaodeng/contrib,chiradeep/contrib,cdemers/contrib,mikedanese/contrib,upmc-enterprises/contrib,luxas/contrib,rchicoli/kubernetes-contrib,verb/contrib,gmarek/contrib,foxish/contrib,stephenrlouie/contrib,jojimt/contrib,ixdy/contrib,rchicoli/kubernetes-contrib,chiradeep/contrib,andrew-j-price/contrib,piosz/contrib,kskalski/contrib,piosz/contrib,gouyang/contrib,Wattpad/kubernetes-contrib,timstclair/kube-contrib,kokhang/contrib,gemini-project/contrib,grodrigues3/contrib,jojimt/contrib,xialonglee/contrib,foxish/contrib,jcmoraisjr/k8s-contrib,ingvagabund/contrib,pwittrock/contrib,eparis/contrib,simonswine/kubernetes-contrib,micheleorsi/contrib,piosz/contrib,ingvagabund/contrib,ixdy/kubernetes-contrib,krzyzacy/contrib,caesarxuchao/contrib,lavalamp/contrib,xialonglee/contrib,rchicoli/kubernetes-contrib,eparis/contrib,k8s-packages-power/contrib,x13n/contrib,jojimt/contrib,thockin/contrib,aledbf/contrib,adamschaub/contrib,kow3ns/contrib,jojimt/contrib,foxish/contrib,thockin/contrib,xialonglee/contrib,upmc-enterprises/contrib,cdemers/contrib,andrew-j-price/contrib,gemini-project/contrib,micheleorsi/contrib,gmarek/contrib,fcvarela/contrib,lavalamp/contrib,freehan/contrib,krzyzacy/contrib,gmarek/contrib,Q-Lee/contrib,rmmh/kubernetes-contrib,micheleorsi/contrib,olark/kubernetes-contrib,simonswine/kubernetes-contrib,grodrigues3/contrib,atosatto/kubernetes-contrib,eparis/contrib,Pensu/contrib,grodrigues3/contrib,freehan/contrib,Wattpad/kubernetes-contrib,widgetpl/contrib,krousey/contrib,x13n/contrib,Pensu/contrib,ixdy/kubernetes-contrib,gouyang/contrib,freehan/contrib,gemini-project/contrib,danehans/contrib,spxtr/contrib,andrew-j-price/contrib,rchicoli/kubernetes-contrib,simonswine/kubernetes-contrib,piosz/contrib,devlinmr/contrib,krzyzacy/contrib,moul/contrib,mikedanese/contrib,chiradeep/contrib,girishkalele/contrib,jasonbrooks/contrib,stephenrlouie/contrib,freehan/contrib,ixdy/contrib,kskalski/contrib,atosatto/kubernetes-contrib,jasonbrooks/contrib,ixdy/kubernetes-contrib,caesarxuchao/contrib,devlinmr/contrib,kow3ns/contrib,olark/kubernetes-contrib,Pensu/contrib,lewislyou/contrib,thockin/contrib,luxas/contrib,endocode/contrib,freehan/contrib,ixdy/kubernetes-contrib,jasonbrooks/contrib,Q-Lee/contrib,gouyang/contrib,kskalski/contrib,caesarxuchao/contrib,kskalski/contrib,aledbf/contrib,jdavis7257/contrib,marketlogicsoftware/contrib,kow3ns/contrib,danushkaf/contrib,k8s-packages-power/contrib,girishkalele/contrib,thockin/contrib,girishkalele/contrib,x13n/contrib,Q-Lee/contrib,aledbf/contrib,girishkalele/contrib,Q-Lee/contrib,moul/contrib,luxas/contrib,verb/contrib,timstclair/kube-contrib,lavalamp/contrib,timstclair/kube-contrib,vishpat/contrib,spxtr/contrib,timstclair/kube-contrib,krzyzacy/contrib,cdemers/contrib,ixdy/contrib,jdavis7257/contrib,grodrigues3/contrib,fcvarela/contrib,danushkaf/contrib,simonswine/kubernetes-contrib,micheleorsi/contrib,krousey/contrib,atosatto/kubernetes-contrib,verb/contrib,k8s-packages-power/contrib,micheleorsi/contrib,rchicoli/kubernetes-contrib,eastbanctech/kubernetes-contrib,kskalski/contrib,stephenrlouie/contrib,danehans/contrib,endocode/contrib,spxtr/contrib,jdavis7257/contrib,adamschaub/contrib,kskalski/contrib,andrew-j-price/contrib,gmarek/contrib,caesarxuchao/contrib,kokhang/contrib,Wattpad/kubernetes-contrib,mikedanese/contrib,jcmoraisjr/k8s-contrib,eastbanctech/kubernetes-contrib,x13n/contrib,aknuds1/contrib,gemini-project/contrib,luxas/contrib,pwittrock/contrib,Q-Lee/contrib,jcmoraisjr/k8s-contrib,eparis/contrib,ingvagabund/contrib,simonswine/kubernetes-contrib,eastbanctech/kubernetes-contrib,ixdy/kubernetes-contrib,cdemers/contrib,rmmh/kubernetes-contrib,endocode/contrib,caesarxuchao/contrib,lewislyou/contrib,krzyzacy/contrib,eastbanctech/kubernetes-contrib,foxish/contrib,verb/contrib,olark/kubernetes-contrib,spxtr/contrib,kokhang/contrib,gemini-project/contrib,adamschaub/contrib,kokhang/contrib,danehans/contrib,stephenrlouie/contrib,danushkaf/contrib