From user-return-2697-apmail-hadoop-user-archive=hadoop.apache.org@hadoop.apache.org Tue Nov 6 20:11:46 2012 Return-Path: X-Original-To: apmail-hadoop-user-archive@minotaur.apache.org Delivered-To: apmail-hadoop-user-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id AA241DBD4 for ; Tue, 6 Nov 2012 20:11:46 +0000 (UTC) Received: (qmail 98821 invoked by uid 500); 6 Nov 2012 20:11:41 -0000 Delivered-To: apmail-hadoop-user-archive@hadoop.apache.org Received: (qmail 98689 invoked by uid 500); 6 Nov 2012 20:11:41 -0000 Mailing-List: contact user-help@hadoop.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@hadoop.apache.org Delivered-To: mailing list user@hadoop.apache.org Received: (qmail 98565 invoked by uid 99); 6 Nov 2012 20:11:41 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 06 Nov 2012 20:11:41 +0000 X-ASF-Spam-Status: No, hits=1.5 required=5.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of forrie@gmail.com designates 209.85.212.48 as permitted sender) Received: from [209.85.212.48] (HELO mail-vb0-f48.google.com) (209.85.212.48) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 06 Nov 2012 20:11:13 +0000 Received: by mail-vb0-f48.google.com with SMTP id e21so906666vbm.35 for ; Tue, 06 Nov 2012 12:10:39 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=message-id:date:from:user-agent:mime-version:to:subject:references :in-reply-to:content-type; bh=9nzJcKxQA6UHbCV/6wyBNuHuYVCosPSypj88GbND62o=; b=EYqt35GZIWYZHGxqyDvX/BXgr6MnR70+tAgjOMqYaZHmT2Y8FW7gRDXUzDyiSkGf/R 4A7f4FHU8s9QrxcMqHcVC1m0ompjdT96QzxuAZxs5qJQllWhgRLYKB6w9cilD3BC8emR 5fgNx8iYU+/PdsWWU9FbTKuKJ72rVJnhjLyzIcRWKMFd3vJvfU1hBnM4r+PHQ3Pi8AxN 2fkQA6CO3ThV1n/d54q9/EwowcHmT+ag5J63B5zS80p9IXT2wXYoNvuywn9eZWOmTc1L +0/FSN11E5uWKsL2CG9DpKdFG04k4ZfBCdJopGQQP4x4YcKNqeuBhEN6cYlaGk+W+2k1 eRSg== Received: by 10.52.96.97 with SMTP id dr1mr1754960vdb.100.1352232638845; Tue, 06 Nov 2012 12:10:38 -0800 (PST) Received: from gump.de-prod.harvard.edu (1story-vpn-gw.dce.harvard.edu. [140.247.198.51]) by mx.google.com with ESMTPS id dp6sm10137093vec.11.2012.11.06.12.10.36 (version=TLSv1/SSLv3 cipher=OTHER); Tue, 06 Nov 2012 12:10:37 -0800 (PST) Message-ID: <50996E70.2030607@gmail.com> Date: Tue, 06 Nov 2012 15:09:20 -0500 From: Forrest Aldrich User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.7; rv:16.0) Gecko/20121026 Thunderbird/16.0.2 MIME-Version: 1.0 To: user@hadoop.apache.org Subject: Re: starting Daemons remotely, through ssh - SOLVED References: In-Reply-To: Content-Type: multipart/alternative; boundary="------------010003020109050307010807" X-Virus-Checked: Checked by ClamAV on apache.org This is a multi-part message in MIME format. --------------010003020109050307010807 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 8bit Andy, I noticed you are splitting up your /etc/init.d startup -- we're new-ish to Hadoop and found that the supplied init.d script doesn't necessarily stop services properly, so I end up doing it manually. If you could share your info that would be great... I can see where they can be time-delayed in the startup with chkconfig (RHEL). Thanks. On 11/6/12 3:07 PM, Kartashov, Andy wrote: > > Harsh/Ravi, > > I wrote my own scripts to [start|stop|restart] [hdfs|mapred] daemons. > The content of the script is > > $sudo service /etc/init.d/hadoop-[hdfs-*|mapred-*] > > I have no problem starting Daemons locally on each node. I have > sudo-access granted. I run script and enter password. > > I have passwordless ssh enabled. But when I am trying to start slave > Daemons from NN I get > > ": sudo: sorry, you must have a tty to run sudo". > > I just solved this issue by: > > a.Modifying slaves.sh script to add --t after ssh "-t" > > a1. Someone suggested to: > > $sudo sudeors and commenting out Defaults requiretty > > But a. worked just fine. > > Cheers, > > AK47 > > *From:*Ravi Mutyala [mailto:ravi@hortonworks.com] > *Sent:* Tuesday, November 06, 2012 2:31 PM > *To:* user@hadoop.apache.org > *Subject:* Re: starting Daemons remotely, through ssh > > Andy, > > Which specific scripts are these? As far as I know, all daemons on the > hadoop side can be started with hadoop/hdfs or any non-sudo username. > You will require passwordless ssh for that user if you are using > slaves/regionservers configured to start the daemons remotely from the > NameNode/HBase Master. > > On Tue, Nov 6, 2012 at 1:25 PM, Kartashov, Andy > > wrote: > > Hadoopers, > > How does one start Daemons remotely when scripts normally require root > user to start them? Do you modify scripts? > > Thanks, > > NOTICE: This e-mail message and any attachments are confidential, > subject to copyright and may be privileged. Any unauthorized use, > copying or disclosure is prohibited. If you are not the intended > recipient, please delete and contact the sender immediately. Please > consider the environment before printing this e-mail. AVIS : le > présent courriel et toute pièce jointe qui l'accompagne sont > confidentiels, protégés par le droit d'auteur et peuvent être couverts > par le secret professionnel. Toute utilisation, copie ou divulgation > non autorisée est interdite. Si vous n'êtes pas le destinataire prévu > de ce courriel, supprimez-le et contactez immédiatement l'expéditeur. > Veuillez penser à l'environnement avant d'imprimer le présent courriel > > NOTICE: This e-mail message and any attachments are confidential, > subject to copyright and may be privileged. Any unauthorized use, > copying or disclosure is prohibited. If you are not the intended > recipient, please delete and contact the sender immediately. Please > consider the environment before printing this e-mail. AVIS : le > présent courriel et toute pièce jointe qui l'accompagne sont > confidentiels, protégés par le droit d'auteur et peuvent être couverts > par le secret professionnel. Toute utilisation, copie ou divulgation > non autorisée est interdite. Si vous n'êtes pas le destinataire prévu > de ce courriel, supprimez-le et contactez immédiatement l'expéditeur. > Veuillez penser à l'environnement avant d'imprimer le présent courriel --------------010003020109050307010807 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Andy, I noticed you are splitting up your /etc/init.d startup -- we're new-ish to Hadoop and found that the supplied init.d script doesn't necessarily stop services properly, so I end up doing it manually.   If you could share your info that would be great... I can see where they can be time-delayed in the startup with chkconfig (RHEL).


Thanks.

On 11/6/12 3:07 PM, Kartashov, Andy wrote:

Harsh/Ravi,

 

I wrote my own scripts to [start|stop|restart]  [hdfs|mapred] daemons. The content of the script is

 

$sudo service /etc/init.d/hadoop-[hdfs-*|mapred-*]

 

I have no problem starting Daemons locally on each node. I have sudo-access granted. I run script and enter password.

I have passwordless ssh enabled. But when I am trying to start slave Daemons from NN I get  

“<remothsot>:  sudo: sorry, you must have a tty to run sudo”.

 

I just solved this issue by:

a.       Modifying slaves.sh script to add –t after ssh “-t” <host-ip> <command>

 

a1. Someone suggested to:

$sudo sudeors and commenting out Defaults requiretty

But a. worked just fine.

 

Cheers,

AK47  

 

From: Ravi Mutyala [mailto:ravi@hortonworks.com]
Sent: Tuesday, November 06, 2012 2:31 PM
To: user@hadoop.apache.org
Subject: Re: starting Daemons remotely, through ssh

 

Andy, 

 

Which specific scripts are these? As far as I know, all daemons on the hadoop side can be started with hadoop/hdfs or any non-sudo username. You will require passwordless ssh for that user if you are using slaves/regionservers configured to start the daemons remotely from the NameNode/HBase Master. 

 

 

On Tue, Nov 6, 2012 at 1:25 PM, Kartashov, Andy <Andy.Kartashov@mpac.ca> wrote:

Hadoopers,

 

How does one start Daemons remotely when scripts normally require root user to start them? Do you modify scripts?

 

Thanks,

NOTICE: This e-mail message and any attachments are confidential, subject to copyright and may be privileged. Any unauthorized use, copying or disclosure is prohibited. If you are not the intended recipient, please delete and contact the sender immediately. Please consider the environment before printing this e-mail. AVIS : le présent courriel et toute pièce jointe qui l'accompagne sont confidentiels, protégés par le droit d'auteur et peuvent être couverts par le secret professionnel. Toute utilisation, copie ou divulgation non autorisée est interdite. Si vous n'êtes pas le destinataire prévu de ce courriel, supprimez-le et contactez immédiatement l'expéditeur. Veuillez penser à l'environnement avant d'imprimer le présent courriel

 

NOTICE: This e-mail message and any attachments are confidential, subject to copyright and may be privileged. Any unauthorized use, copying or disclosure is prohibited. If you are not the intended recipient, please delete and contact the sender immediately. Please consider the environment before printing this e-mail. AVIS : le présent courriel et toute pièce jointe qui l'accompagne sont confidentiels, protégés par le droit d'auteur et peuvent être couverts par le secret professionnel. Toute utilisation, copie ou divulgation non autorisée est interdite. Si vous n'êtes pas le destinataire prévu de ce courriel, supprimez-le et contactez immédiatement l'expéditeur. Veuillez penser à l'environnement avant d'imprimer le présent courriel

--------------010003020109050307010807--