From issues-return-404741-archive-asf-public=cust-asf.ponee.io@flink.apache.org Fri Oct 9 09:47:03 2020 Return-Path: X-Original-To: archive-asf-public@cust-asf.ponee.io Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mxout1-ec2-va.apache.org (mxout1-ec2-va.apache.org [3.227.148.255]) by mx-eu-01.ponee.io (Postfix) with ESMTPS id 5631C180642 for ; Fri, 9 Oct 2020 11:47:03 +0200 (CEST) Received: from mail.apache.org (mailroute1-lw-us.apache.org [207.244.88.153]) by mxout1-ec2-va.apache.org (ASF Mail Server at mxout1-ec2-va.apache.org) with SMTP id 93BA245A96 for ; Fri, 9 Oct 2020 09:47:02 +0000 (UTC) Received: (qmail 70651 invoked by uid 500); 9 Oct 2020 09:47:02 -0000 Mailing-List: contact issues-help@flink.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@flink.apache.org Delivered-To: mailing list issues@flink.apache.org Received: (qmail 70633 invoked by uid 99); 9 Oct 2020 09:47:02 -0000 Received: from mailrelay1-us-west.apache.org (HELO mailrelay1-us-west.apache.org) (209.188.14.139) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 09 Oct 2020 09:47:02 +0000 Received: from jira2-he-de.apache.org (static.54.33.119.168.clients.your-server.de [168.119.33.54]) by mailrelay1-us-west.apache.org (ASF Mail Server at mailrelay1-us-west.apache.org) with ESMTP id 6512042A1C for ; Fri, 9 Oct 2020 09:47:01 +0000 (UTC) Received: from jira2-he-de.apache.org (localhost.localdomain [127.0.0.1]) by jira2-he-de.apache.org (ASF Mail Server at jira2-he-de.apache.org) with ESMTP id 60AA6C806C5 for ; Fri, 9 Oct 2020 09:47:00 +0000 (UTC) Date: Fri, 9 Oct 2020 09:47:00 +0000 (UTC) From: "Chesnay Schepler (Jira)" To: issues@flink.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (FLINK-15843) Gracefully shutdown TaskManagers on Kubernetes MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/FLINK-15843?page=3Dcom.atlassia= n.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=3D172= 10769#comment-17210769 ]=20 Chesnay Schepler commented on FLINK-15843: ------------------------------------------ [~felixzheng] ping > Gracefully shutdown TaskManagers on Kubernetes > ---------------------------------------------- > > Key: FLINK-15843 > URL: https://issues.apache.org/jira/browse/FLINK-15843 > Project: Flink > Issue Type: Improvement > Components: Deployment / Kubernetes > Affects Versions: 1.10.0 > Reporter: Canbin Zheng > Priority: Major > Fix For: 1.12.0 > > > The current solution of stopping a TaskManager instance when JobManager s= ends a deletion request is by directly calling {{KubernetesClient.pods().wi= thName().delete}}, thus that instance would be violently killed with a _KIL= L_ signal and having no chance to clean up, which could cause problems beca= use we expect the process to gracefully terminate when it is no longer need= ed. > Refer to the guide of [Termination of Pods|#termination-of-pods], we know= that on Kubernetes a _TERM_ signal would be first sent to the main process= in each container, and may be followed up with a force _KILL_ signal if th= e graceful shut-down period has expired; the Unix signal will be sent to th= e process which has PID 1 ([Docker Kill|https://docs.docker.com/engine/refe= rence/commandline/kill/]), however, the TaskManagerRunner process is spawne= d by {color:#172b4d}/opt/flink/bin/kubernetes-entry.sh {color}and could nev= er have PID 1, so it would never receive the TERM signal. > =C2=A0 > =C2=A0 > =C2=A0 -- This message was sent by Atlassian Jira (v8.3.4#803005)