You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@hbase.apache.org by "Ferdy (Created) (JIRA)" <ji...@apache.org> on 2011/10/25 17:44:32 UTC

[jira] [Created] (HBASE-4671) HBaseTestingUtility unable to connect to regionserver because of 127.0.0.1 / 127.0.1.1 discrepancy

HBaseTestingUtility unable to connect to regionserver because of 127.0.0.1 / 127.0.1.1 discrepancy
--------------------------------------------------------------------------------------------------

                 Key: HBASE-4671
                 URL: https://issues.apache.org/jira/browse/HBASE-4671
             Project: HBase
          Issue Type: Bug
          Components: test
    Affects Versions: 0.90.4
         Environment: At least Ubuntu 11.10 with a default hosts file.
            Reporter: Ferdy


When /etc/hosts contains following lines (and this is not uncommon) it will cause HBaseTestingUtility to malfunction.
127.0.0.1	localhost
127.0.1.1	myMachineName

Symptoms:
2011-10-25 17:38:30,875 WARN  master.AssignmentManager - Failed assignment of -ROOT-,,0.70236052 to serverName=localhost,34462,1319557102914, load=(requests=0, regions=0, usedHeap=46, maxHeap=865), trying to assign elsewhere instead; retry=0
org.apache.hadoop.hbase.client.RetriesExhaustedException: Failed setting up proxy interface org.apache.hadoop.hbase.ipc.HRegionInterface to /127.0.0.1:34462 after attempts=1

because

2011-10-25 17:38:28,371 INFO  regionserver.HRegionServer - Serving as localhost,34462,1319557102914, RPC listening on /127.0.1.1:34462, sessionid=0x1333bbb7a180002

caused by /127.0.0.1:34462 vs /127.0.1.1:34462

Workaround:
Changing 127.0.1.1 to 127.0.0.1 works.

Permanent solution:
Dunno, my understanding of inner workings is not sufficient enough. Although it seems like it has something to do with changing the machine name from myMachineName to localhost during the test:
2011-10-25 17:38:28,056 INFO  regionserver.HRegionServer - Master passed us address to use. Was=myMachineName:34462, Now=localhost:34462

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (HBASE-4671) HBaseTestingUtility unable to connect to regionserver because of 127.0.0.1 / 127.0.1.1 discrepancy

Posted by "Alexey Zotov (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HBASE-4671?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13399966#comment-13399966 ] 

Alexey Zotov commented on HBASE-4671:
-------------------------------------

It's actual for Ubuntu 12.04 too.
                
> HBaseTestingUtility unable to connect to regionserver because of 127.0.0.1 / 127.0.1.1 discrepancy
> --------------------------------------------------------------------------------------------------
>
>                 Key: HBASE-4671
>                 URL: https://issues.apache.org/jira/browse/HBASE-4671
>             Project: HBase
>          Issue Type: Bug
>          Components: test
>    Affects Versions: 0.90.4
>         Environment: At least Ubuntu 11.10 with a default hosts file.
>            Reporter: Ferdy Galema
>
> When /etc/hosts contains following lines (and this is not uncommon) it will cause HBaseTestingUtility to malfunction.
> 127.0.0.1	localhost
> 127.0.1.1	myMachineName
> Symptoms:
> 2011-10-25 17:38:30,875 WARN  master.AssignmentManager - Failed assignment of -ROOT-,,0.70236052 to serverName=localhost,34462,1319557102914, load=(requests=0, regions=0, usedHeap=46, maxHeap=865), trying to assign elsewhere instead; retry=0
> org.apache.hadoop.hbase.client.RetriesExhaustedException: Failed setting up proxy interface org.apache.hadoop.hbase.ipc.HRegionInterface to /127.0.0.1:34462 after attempts=1
> because
> 2011-10-25 17:38:28,371 INFO  regionserver.HRegionServer - Serving as localhost,34462,1319557102914, RPC listening on /127.0.1.1:34462, sessionid=0x1333bbb7a180002
> caused by /127.0.0.1:34462 vs /127.0.1.1:34462
> Workaround:
> Changing 127.0.1.1 to 127.0.0.1 works.
> Permanent solution:
> Dunno, my understanding of inner workings is not sufficient enough. Although it seems like it has something to do with changing the machine name from myMachineName to localhost during the test:
> 2011-10-25 17:38:28,056 INFO  regionserver.HRegionServer - Master passed us address to use. Was=myMachineName:34462, Now=localhost:34462

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (HBASE-4671) HBaseTestingUtility unable to connect to regionserver because of 127.0.0.1 / 127.0.1.1 discrepancy

Posted by "Ferdy (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HBASE-4671?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13135180#comment-13135180 ] 

Ferdy commented on HBASE-4671:
------------------------------

(Changing 127.0.1.1 to 127.0.0.1 in the hosts file that is.)
                
> HBaseTestingUtility unable to connect to regionserver because of 127.0.0.1 / 127.0.1.1 discrepancy
> --------------------------------------------------------------------------------------------------
>
>                 Key: HBASE-4671
>                 URL: https://issues.apache.org/jira/browse/HBASE-4671
>             Project: HBase
>          Issue Type: Bug
>          Components: test
>    Affects Versions: 0.90.4
>         Environment: At least Ubuntu 11.10 with a default hosts file.
>            Reporter: Ferdy
>
> When /etc/hosts contains following lines (and this is not uncommon) it will cause HBaseTestingUtility to malfunction.
> 127.0.0.1	localhost
> 127.0.1.1	myMachineName
> Symptoms:
> 2011-10-25 17:38:30,875 WARN  master.AssignmentManager - Failed assignment of -ROOT-,,0.70236052 to serverName=localhost,34462,1319557102914, load=(requests=0, regions=0, usedHeap=46, maxHeap=865), trying to assign elsewhere instead; retry=0
> org.apache.hadoop.hbase.client.RetriesExhaustedException: Failed setting up proxy interface org.apache.hadoop.hbase.ipc.HRegionInterface to /127.0.0.1:34462 after attempts=1
> because
> 2011-10-25 17:38:28,371 INFO  regionserver.HRegionServer - Serving as localhost,34462,1319557102914, RPC listening on /127.0.1.1:34462, sessionid=0x1333bbb7a180002
> caused by /127.0.0.1:34462 vs /127.0.1.1:34462
> Workaround:
> Changing 127.0.1.1 to 127.0.0.1 works.
> Permanent solution:
> Dunno, my understanding of inner workings is not sufficient enough. Although it seems like it has something to do with changing the machine name from myMachineName to localhost during the test:
> 2011-10-25 17:38:28,056 INFO  regionserver.HRegionServer - Master passed us address to use. Was=myMachineName:34462, Now=localhost:34462

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (HBASE-4671) HBaseTestingUtility unable to connect to regionserver because of 127.0.0.1 / 127.0.1.1 discrepancy

Posted by "nkeywal (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HBASE-4671?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13399974#comment-13399974 ] 

nkeywal commented on HBASE-4671:
--------------------------------

>From the hbase reference guide: http://hbase.apache.org/book.html#os

{noformat}
2.2.3. Loopback IP

HBase expects the loopback IP address to be 127.0.0.1. Ubuntu and some other distributions, for example, will default to 127.0.1.1 and this will cause problems for you.

/etc/hosts should look something like this:

            127.0.0.1 localhost
            127.0.0.1 ubuntu.ubuntu-domain ubuntu
{noformat}

                
> HBaseTestingUtility unable to connect to regionserver because of 127.0.0.1 / 127.0.1.1 discrepancy
> --------------------------------------------------------------------------------------------------
>
>                 Key: HBASE-4671
>                 URL: https://issues.apache.org/jira/browse/HBASE-4671
>             Project: HBase
>          Issue Type: Bug
>          Components: test
>    Affects Versions: 0.90.4
>         Environment: At least Ubuntu 11.10 with a default hosts file.
>            Reporter: Ferdy Galema
>
> When /etc/hosts contains following lines (and this is not uncommon) it will cause HBaseTestingUtility to malfunction.
> 127.0.0.1	localhost
> 127.0.1.1	myMachineName
> Symptoms:
> 2011-10-25 17:38:30,875 WARN  master.AssignmentManager - Failed assignment of -ROOT-,,0.70236052 to serverName=localhost,34462,1319557102914, load=(requests=0, regions=0, usedHeap=46, maxHeap=865), trying to assign elsewhere instead; retry=0
> org.apache.hadoop.hbase.client.RetriesExhaustedException: Failed setting up proxy interface org.apache.hadoop.hbase.ipc.HRegionInterface to /127.0.0.1:34462 after attempts=1
> because
> 2011-10-25 17:38:28,371 INFO  regionserver.HRegionServer - Serving as localhost,34462,1319557102914, RPC listening on /127.0.1.1:34462, sessionid=0x1333bbb7a180002
> caused by /127.0.0.1:34462 vs /127.0.1.1:34462
> Workaround:
> Changing 127.0.1.1 to 127.0.0.1 works.
> Permanent solution:
> Dunno, my understanding of inner workings is not sufficient enough. Although it seems like it has something to do with changing the machine name from myMachineName to localhost during the test:
> 2011-10-25 17:38:28,056 INFO  regionserver.HRegionServer - Master passed us address to use. Was=myMachineName:34462, Now=localhost:34462

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (HBASE-4671) HBaseTestingUtility unable to connect to regionserver because of 127.0.0.1 / 127.0.1.1 discrepancy

Posted by "Alexey Zotov (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HBASE-4671?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13399995#comment-13399995 ] 

Alexey Zotov commented on HBASE-4671:
-------------------------------------

nkeywal, thank you for reference and quick response! 
You made me curious :) So, I've looked into sources and found that some services start on 'localhost' and some on 'ubuntu' (accordingly to your example) domain name. 
I'll try to look into sources more deeply and create a patch if it's possible. 
                
> HBaseTestingUtility unable to connect to regionserver because of 127.0.0.1 / 127.0.1.1 discrepancy
> --------------------------------------------------------------------------------------------------
>
>                 Key: HBASE-4671
>                 URL: https://issues.apache.org/jira/browse/HBASE-4671
>             Project: HBase
>          Issue Type: Bug
>          Components: test
>    Affects Versions: 0.90.4
>         Environment: At least Ubuntu 11.10 with a default hosts file.
>            Reporter: Ferdy Galema
>
> When /etc/hosts contains following lines (and this is not uncommon) it will cause HBaseTestingUtility to malfunction.
> 127.0.0.1	localhost
> 127.0.1.1	myMachineName
> Symptoms:
> 2011-10-25 17:38:30,875 WARN  master.AssignmentManager - Failed assignment of -ROOT-,,0.70236052 to serverName=localhost,34462,1319557102914, load=(requests=0, regions=0, usedHeap=46, maxHeap=865), trying to assign elsewhere instead; retry=0
> org.apache.hadoop.hbase.client.RetriesExhaustedException: Failed setting up proxy interface org.apache.hadoop.hbase.ipc.HRegionInterface to /127.0.0.1:34462 after attempts=1
> because
> 2011-10-25 17:38:28,371 INFO  regionserver.HRegionServer - Serving as localhost,34462,1319557102914, RPC listening on /127.0.1.1:34462, sessionid=0x1333bbb7a180002
> caused by /127.0.0.1:34462 vs /127.0.1.1:34462
> Workaround:
> Changing 127.0.1.1 to 127.0.0.1 works.
> Permanent solution:
> Dunno, my understanding of inner workings is not sufficient enough. Although it seems like it has something to do with changing the machine name from myMachineName to localhost during the test:
> 2011-10-25 17:38:28,056 INFO  regionserver.HRegionServer - Master passed us address to use. Was=myMachineName:34462, Now=localhost:34462

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Resolved] (HBASE-4671) HBaseTestingUtility unable to connect to regionserver because of 127.0.0.1 / 127.0.1.1 discrepancy

Posted by "Jesse Yates (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HBASE-4671?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jesse Yates resolved HBASE-4671.
--------------------------------

    Resolution: Fixed

Marking as fixed. Looks like a case of RTFM  - unless we actually need to change some hardcoded values?
                
> HBaseTestingUtility unable to connect to regionserver because of 127.0.0.1 / 127.0.1.1 discrepancy
> --------------------------------------------------------------------------------------------------
>
>                 Key: HBASE-4671
>                 URL: https://issues.apache.org/jira/browse/HBASE-4671
>             Project: HBase
>          Issue Type: Bug
>          Components: test
>    Affects Versions: 0.90.4
>         Environment: At least Ubuntu 11.10 with a default hosts file.
>            Reporter: Ferdy Galema
>
> When /etc/hosts contains following lines (and this is not uncommon) it will cause HBaseTestingUtility to malfunction.
> 127.0.0.1	localhost
> 127.0.1.1	myMachineName
> Symptoms:
> 2011-10-25 17:38:30,875 WARN  master.AssignmentManager - Failed assignment of -ROOT-,,0.70236052 to serverName=localhost,34462,1319557102914, load=(requests=0, regions=0, usedHeap=46, maxHeap=865), trying to assign elsewhere instead; retry=0
> org.apache.hadoop.hbase.client.RetriesExhaustedException: Failed setting up proxy interface org.apache.hadoop.hbase.ipc.HRegionInterface to /127.0.0.1:34462 after attempts=1
> because
> 2011-10-25 17:38:28,371 INFO  regionserver.HRegionServer - Serving as localhost,34462,1319557102914, RPC listening on /127.0.1.1:34462, sessionid=0x1333bbb7a180002
> caused by /127.0.0.1:34462 vs /127.0.1.1:34462
> Workaround:
> Changing 127.0.1.1 to 127.0.0.1 works.
> Permanent solution:
> Dunno, my understanding of inner workings is not sufficient enough. Although it seems like it has something to do with changing the machine name from myMachineName to localhost during the test:
> 2011-10-25 17:38:28,056 INFO  regionserver.HRegionServer - Master passed us address to use. Was=myMachineName:34462, Now=localhost:34462

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira