Return-Path: X-Original-To: apmail-hadoop-common-user-archive@www.apache.org Delivered-To: apmail-hadoop-common-user-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 3E01B10D16 for ; Thu, 9 Jan 2014 00:54:30 +0000 (UTC) Received: (qmail 68160 invoked by uid 500); 9 Jan 2014 00:54:24 -0000 Delivered-To: apmail-hadoop-common-user-archive@hadoop.apache.org Received: (qmail 67983 invoked by uid 500); 9 Jan 2014 00:54:24 -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 67976 invoked by uid 99); 9 Jan 2014 00:54:24 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 09 Jan 2014 00:54:24 +0000 X-ASF-Spam-Status: No, hits=1.7 required=5.0 tests=FREEMAIL_ENVFROM_END_DIGIT,HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of bugcy013@gmail.com designates 209.85.212.46 as permitted sender) Received: from [209.85.212.46] (HELO mail-vb0-f46.google.com) (209.85.212.46) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 09 Jan 2014 00:54:20 +0000 Received: by mail-vb0-f46.google.com with SMTP id w20so1725463vbb.33 for ; Wed, 08 Jan 2014 16:53:59 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:from:date:message-id:subject:to:content-type; bh=X3+Hy/kNguniKvd9RY9wzDmPBfltelOEl/YBvo1IE0A=; b=cnjSQEBg4Fu/auvLv17i3Tc06OtfTMeyJn9lsfZ52VA10er9JQUNpNCfy3Q2zMLeos m5QBZ3u2A6cXGr5pLq4NDvxyZNINcgk/lpdyTmjDnnyRlKZjx3bAvRi9NxXKOHZGv2yh V77Q2ZlQN1aNuQZddHsR7tTjWLUwwgsGl+KCHDMacYEkWPWOkFcvJRznWAQeFsvPVtgt l65upidcP3LZFMZ+S83JvRTxQMdTdz4RZdhsZFOj3f/3S2d9/lqzUOLOuoXzOEJzVO95 j5FzBMtnAjWLMOva8T/Wh4XNQFOciJSoW9mfDBzJquWRgQv2qE9ETiQb4RvbnBRz0jtZ imag== X-Received: by 10.58.67.9 with SMTP id j9mr78000vet.3.1389228839368; Wed, 08 Jan 2014 16:53:59 -0800 (PST) MIME-Version: 1.0 Received: by 10.58.30.38 with HTTP; Wed, 8 Jan 2014 16:53:39 -0800 (PST) From: Dhanasekaran Anbalagan Date: Wed, 8 Jan 2014 19:53:39 -0500 Message-ID: Subject: Hadoop-streaming : PYTHONPATH not working when mapper runs To: cdh-user , user Content-Type: multipart/alternative; boundary=047d7b339e077b7efb04ef7f0b44 X-Virus-Checked: Checked by ClamAV on apache.org --047d7b339e077b7efb04ef7f0b44 Content-Type: text/plain; charset=UTF-8 Hi Guys, I have problem when I ran hadoop streaming PYTHONPATH environment variable not properly getting value. when I try to extend sys.path code level not working. It's says KeyError:'PYTHONPATH' In my case I already exported PYTHONPATH in /etc/bashrc mapper logs: ========== stderr logs Traceback (most recent call last): File "/disk1/mapred/local/taskTracker/tech/jobcache/job_201312121801_0053/attempt_201312121801_0053_m_000000_0/work/./cmapper.py", line 14, in * sys.path.extend(os.environ['PYTHONPATH'].split(os.path.pathsep))* File "/usr/lib/python2.7/UserDict.py", line 23, in __getitem__ raise KeyError(key) *KeyError: 'PYTHONPATH'* I tried /etc/sudoers file I added PYTHONPATH Defaults env_keep ="PYTHONPATH" also not working. can you please guide me How to fix this. -Dhanasekaran. Did I learn something today? If not, I wasted it. --047d7b339e077b7efb04ef7f0b44 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Hi Guys,

I have problem when= I ran hadoop streaming PYTHONPATH environment variable not properly gettin= g value. when I try to extend sys.path code level =C2=A0not working. It'= ;s says KeyError:'PYTHONPATH' In my case I already exported PYTHONP= ATH in /etc/bashrc=C2=A0

mapper logs:
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
stderr logs
Traceback (most recent call last):
=C2=A0 File "/disk1/mapred/local/taskTracker/tech/jobcache/job_2= 01312121801_0053/attempt_201312121801_0053_m_000000_0/work/./cmapper.py&quo= t;, line 14, in <module>
=C2=A0 =C2=A0 sys.path.extend(os.environ['PYTHONPATH'].spli= t(os.path.pathsep))
=C2=A0 File "/usr/lib/python2.7/User= Dict.py", line 23, in __getitem__
=C2=A0 =C2=A0 raise KeyErr= or(key)
KeyError: 'PYTHONPATH'


I tried /etc/sudoers file I added PYTHONPATH

Defaults =C2=A0 =C2=A0 =C2=A0 =C2=A0env_keep =3D"PYTHONPATH"

also not working.

can you please guide me How= to fix this.

-Dhanasekaran.

<= div>Did I learn something today? If not, I wasted it.
--047d7b339e077b7efb04ef7f0b44--