You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@hbase.apache.org by Zhou <ne...@gmail.com> on 2008/04/28 18:42:18 UTC

HBase region server id problem with ipv6 address

Hi,

I've met a problem startup HBase.

I setup hbase with hdfs,
My server's network card has a ipv4 address and also a ipv6 address.

When I first startup hbase with default configuration file,
I found that the region server can't 
register to master. And I found lots of 127.0.0.1 in log.

So I suppose interface "default" would not work and add following:

<property>
  <name>dfs.datanode.dns.interface</name>
  <value>eth0</value>
  <description>The name of the Network Interface from which a data node should 
  report its IP address.
  </description>
 </property>

However, when this is done. HBase master crashes;
And I see ipv6 addresses in the log.

So I dig into the source code,
found that HBase fails to deal with IPv6 address.

Details is in following:
In class  org.apache.hadoop.hbase.HRegionServer
the method getThisIP() invoke the method of class belongs to Hadoop-core package
The class is: org.apache.hadoop.net.DNS
the method is: getDefaultIP(String strInterface)
This method invokes another method in the same class: getIPs(String strInterface)
Method getIPs always returns the first ip address  no matter it is ipv4 or ipv6

I have fixed it by modifying method of org.apache.hadoop.net.DNS.getIPs(String
strInterface)
Such that it always returns ipv4 address
It is working now for me.
But when hadoop upgrades, I have to modify again.

I hope that HBase can fix this problem.

Many thanks,

Zhou



Re: HBase region server id problem with ipv6 address

Posted by Zhou <ne...@gmail.com>.
Bryan Duxbury <br...@...> writes:

> 
> Zhou,
> 
> Can you create an issue and post a patch of the changes you made?

OK

> 
> -Bryan
> 







Re: HBase region server id problem with ipv6 address

Posted by Bryan Duxbury <br...@rapleaf.com>.
Zhou,

Can you create an issue and post a patch of the changes you made?

-Bryan

On Apr 28, 2008, at 9:42 AM, Zhou wrote:

> Hi,
>
> I've met a problem startup HBase.
>
> I setup hbase with hdfs,
> My server's network card has a ipv4 address and also a ipv6 address.
>
> When I first startup hbase with default configuration file,
> I found that the region server can't
> register to master. And I found lots of 127.0.0.1 in log.
>
> So I suppose interface "default" would not work and add following:
>
> <property>
>   <name>dfs.datanode.dns.interface</name>
>   <value>eth0</value>
>   <description>The name of the Network Interface from which a data  
> node should
>   report its IP address.
>   </description>
>  </property>
>
> However, when this is done. HBase master crashes;
> And I see ipv6 addresses in the log.
>
> So I dig into the source code,
> found that HBase fails to deal with IPv6 address.
>
> Details is in following:
> In class  org.apache.hadoop.hbase.HRegionServer
> the method getThisIP() invoke the method of class belongs to Hadoop- 
> core package
> The class is: org.apache.hadoop.net.DNS
> the method is: getDefaultIP(String strInterface)
> This method invokes another method in the same class: getIPs(String  
> strInterface)
> Method getIPs always returns the first ip address  no matter it is  
> ipv4 or ipv6
>
> I have fixed it by modifying method of  
> org.apache.hadoop.net.DNS.getIPs(String
> strInterface)
> Such that it always returns ipv4 address
> It is working now for me.
> But when hadoop upgrades, I have to modify again.
>
> I hope that HBase can fix this problem.
>
> Many thanks,
>
> Zhou
>
>