[
https://issues.apache.org/jira/browse/HBASE-12742?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14256781#comment-14256781
]
Jurriaan Mous commented on HBASE-12742:
---------------------------------------
I was encountering the failure in TestHCM which test the
HbaceConnectionManager. I needed to run this test to be able to find issues in
the new AsyncRpcClient. I always run that above patch to be able to run that
test.
It happens because in TestHCM the "hbase.status.published" is set so the master
sends out multicast messages of its status on which the test reacts. The
multicast messaging is handled by a Netty datagram implementation.
It fails because the server started with an IPv4 address and the first network
interface it finds on my machine is an IPv6 tunnel. And then the Datagram
freaks out because those two are not compatible.
I think disabling TestHCM is not an option since it is such a core
functionality test.
The best option is to make that IP stack a bit smarter on what IP version the
cluster runs so it only fetches matching interfaces. I will look into it if it
is within my capabilities to find a right solution.
> ClusterStatusPublisher crashes with a IPv6 network interface.
> -------------------------------------------------------------
>
> Key: HBASE-12742
> URL: https://issues.apache.org/jira/browse/HBASE-12742
> Project: HBase
> Issue Type: Bug
> Reporter: Jurriaan Mous
> Assignee: Jurriaan Mous
> Attachments: HBASE-12742.patch
>
>
> On my dev machine the first network interface is an IPv6 tunnel. Hbase works
> internally with ipv4 addresses. Addressing selects the first tunnel to use.
> This causes the ClusterStatusPublisher its DatagramChannel group join to
> crash.
> Fix: Do not select IPv6 network interfaces in Addressing.
> Stack trace:
> {code}
> java.io.IOException: Shutting down
> at
> org.apache.hadoop.hbase.MiniHBaseCluster.init(MiniHBaseCluster.java:231)
> at
> org.apache.hadoop.hbase.MiniHBaseCluster.<init>(MiniHBaseCluster.java:93)
> at
> org.apache.hadoop.hbase.HBaseTestingUtility.startMiniHBaseCluster(HBaseTestingUtility.java:976)
> at
> org.apache.hadoop.hbase.HBaseTestingUtility.startMiniCluster(HBaseTestingUtility.java:936)
> at
> org.apache.hadoop.hbase.HBaseTestingUtility.startMiniCluster(HBaseTestingUtility.java:810)
> at
> org.apache.hadoop.hbase.HBaseTestingUtility.startMiniCluster(HBaseTestingUtility.java:792)
> at
> org.apache.hadoop.hbase.HBaseTestingUtility.startMiniCluster(HBaseTestingUtility.java:779)
> at
> org.apache.hadoop.hbase.client.TestHCM.setUpBeforeClass(TestHCM.java:140)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
> at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> at
> org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:47)
> at
> org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
> at
> org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:44)
> at
> org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:24)
> at
> org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:27)
> at org.junit.runners.ParentRunner.run(ParentRunner.java:309)
> at org.junit.runner.JUnitCore.run(JUnitCore.java:160)
> at
> com.intellij.junit4.JUnit4IdeaTestRunner.startRunnerWithArgs(JUnit4IdeaTestRunner.java:74)
> at
> com.intellij.rt.execution.junit.JUnitStarter.prepareStreamsAndStart(JUnitStarter.java:211)
> at
> com.intellij.rt.execution.junit.JUnitStarter.main(JUnitStarter.java:67)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
> at com.intellij.rt.execution.application.AppMain.main(AppMain.java:134)
> Caused by: java.lang.RuntimeException: Failed construction of Master: class
> org.apache.hadoop.hbase.master.HMaster
> at
> org.apache.hadoop.hbase.util.JVMClusterUtil.createMasterThread(JVMClusterUtil.java:143)
> at
> org.apache.hadoop.hbase.LocalHBaseCluster.addMaster(LocalHBaseCluster.java:215)
> at
> org.apache.hadoop.hbase.LocalHBaseCluster.<init>(LocalHBaseCluster.java:153)
> at
> org.apache.hadoop.hbase.MiniHBaseCluster.init(MiniHBaseCluster.java:213)
> ... 26 more
> Caused by: java.io.IOException: Network interface not configured for IPv4
> at
> sun.nio.ch.DatagramChannelImpl.innerJoin(DatagramChannelImpl.java:860)
> at sun.nio.ch.DatagramChannelImpl.join(DatagramChannelImpl.java:885)
> at
> io.netty.channel.socket.nio.NioDatagramChannel.joinGroup(NioDatagramChannel.java:409)
> at
> org.apache.hadoop.hbase.master.ClusterStatusPublisher$MulticastPublisher.connect(ClusterStatusPublisher.java:286)
> at
> org.apache.hadoop.hbase.master.ClusterStatusPublisher.<init>(ClusterStatusPublisher.java:129)
> at org.apache.hadoop.hbase.master.HMaster.<init>(HMaster.java:379)
> at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
> at
> sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57)
> at
> sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
> at java.lang.reflect.Constructor.newInstance(Constructor.java:526)
> at
> org.apache.hadoop.hbase.util.JVMClusterUtil.createMasterThread(JVMClusterUtil.java:139)
> ... 29 more
> {code}
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)