Return-Path: X-Original-To: apmail-hadoop-common-dev-archive@www.apache.org Delivered-To: apmail-hadoop-common-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id A4851188D8 for ; Mon, 7 Dec 2015 18:34:13 +0000 (UTC) Received: (qmail 73849 invoked by uid 500); 7 Dec 2015 18:34:11 -0000 Delivered-To: apmail-hadoop-common-dev-archive@hadoop.apache.org Received: (qmail 73403 invoked by uid 500); 7 Dec 2015 18:34:11 -0000 Mailing-List: contact common-dev-help@hadoop.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: common-dev@hadoop.apache.org Delivered-To: mailing list common-dev@hadoop.apache.org Received: (qmail 73065 invoked by uid 99); 7 Dec 2015 18:34:11 -0000 Received: from arcas.apache.org (HELO arcas) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 07 Dec 2015 18:34:11 +0000 Received: from arcas.apache.org (localhost [127.0.0.1]) by arcas (Postfix) with ESMTP id 1414B2C1F5C for ; Mon, 7 Dec 2015 18:34:11 +0000 (UTC) Date: Mon, 7 Dec 2015 18:34:11 +0000 (UTC) From: "Jon Bringhurst (JIRA)" To: common-dev@hadoop.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Created] (HADOOP-12621) Allow shutdown before full YARN_STOP_TIMEOUT has elapsed MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 Jon Bringhurst created HADOOP-12621: --------------------------------------- Summary: Allow shutdown before full YARN_STOP_TIMEOUT has elapsed Key: HADOOP-12621 URL: https://issues.apache.org/jira/browse/HADOOP-12621 Project: Hadoop Common Issue Type: Improvement Reporter: Jon Bringhurst Assignee: Jon Bringhurst I noticed that yarn-daemon.sh will wait the full time of YARN_STOP_TIMEOUT on shutdown. Here's a snippet from yarn-daemon.sh in release-2.7.1: {noformat} if [ -f $pid ]; then TARGET_PID=`cat $pid` if kill -0 $TARGET_PID > /dev/null 2>&1; then echo stopping $command kill $TARGET_PID sleep $YARN_STOP_TIMEOUT if kill -0 $TARGET_PID > /dev/null 2>&1; then echo "$command did not stop gracefully after $YARN_STOP_TIMEOUT seconds: killing with kill -9" kill -9 $TARGET_PID fi else echo no $command to stop fi rm -f $pid else echo no $command to stop fi {noformat} The script should poll the process rather than wait the entire time. I'll also dig into trunk to see what the behavior is there. -- This message was sent by Atlassian JIRA (v6.3.4#6332)