Return-Path: Delivered-To: apmail-hadoop-core-dev-archive@www.apache.org Received: (qmail 82625 invoked from network); 11 Mar 2008 10:30:17 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 11 Mar 2008 10:30:17 -0000 Received: (qmail 80834 invoked by uid 500); 11 Mar 2008 10:30:11 -0000 Delivered-To: apmail-hadoop-core-dev-archive@hadoop.apache.org Received: (qmail 80784 invoked by uid 500); 11 Mar 2008 10:30:11 -0000 Mailing-List: contact core-dev-help@hadoop.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: core-dev@hadoop.apache.org Delivered-To: mailing list core-dev@hadoop.apache.org Received: (qmail 80765 invoked by uid 99); 11 Mar 2008 10:30:11 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 11 Mar 2008 03:30:11 -0700 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.140] (HELO brutus.apache.org) (140.211.11.140) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 11 Mar 2008 10:29:42 +0000 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 6AB8E234C08B for ; Tue, 11 Mar 2008 03:28:46 -0700 (PDT) Message-ID: <96388290.1205231326422.JavaMail.jira@brutus> Date: Tue, 11 Mar 2008 03:28:46 -0700 (PDT) From: "Craig Macdonald (JIRA)" To: core-dev@hadoop.apache.org Subject: [jira] Updated: (HADOOP-2983) [HOD] local_fqdn() returns None when gethostbyname_ex doesnt return any FQDNs. In-Reply-To: <1780114556.1205154707371.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/HADOOP-2983?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Craig Macdonald updated HADOOP-2983: ------------------------------------ Attachment: HOD_util_local_fqdn_AL_GRANTED.patch Re-attached patch and ticked the granted option. C > [HOD] local_fqdn() returns None when gethostbyname_ex doesnt return any FQDNs. > ------------------------------------------------------------------------------ > > Key: HADOOP-2983 > URL: https://issues.apache.org/jira/browse/HADOOP-2983 > Project: Hadoop Core > Issue Type: Bug > Components: contrib/hod > Affects Versions: 0.16.0 > Environment: Linux, PBS > Reporter: Craig Macdonald > Attachments: HOD_util_local_fqdn.py, HOD_util_local_fqdn_AL_GRANTED.patch > > > For some reason (probably in our local DNS setup) gethostbyname_ex() does not return any fully qualified hostnames. This has never been an issue, everything has worked fully with the hostnames. > However, this causes HOD to fail, as local_fqn() in util.py returns None. > {noformat} > Python 2.5.1 (r251:54863, Sep 21 2007, 16:05:06) > [GCC 3.4.6 20060404 (Red Hat 3.4.6-3)] on linux2 > Type "help", "copyright", "credits" or "license" for more information. > >>> import socket, os > >>> socket.gethostbyname_ex(os.uname()[1]) > ('bohol', [], ['130.209.252.70']) > >>> > {noformat} > The solution is to fix local_fqdn in until.py, such that it falls back to the contents of the variable me if fqdn is still None. > Ta muchly. > Craig -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.