I downloaded Apache Drill v1.8, edited the conf/drill-override.conf
to have the following changes:
drill.exec: {
cluster-id: "drillbits1",
zk.connect: "10.178.23.140:2181,10.178.23.140:2182,10.178.23.140:2183,10.178.23.140:2184"
}
..zookeeper cluster is effectively consisted of 4 Zookeeper instances started on the same, one machine, I'm trying to start Drill on. (i.e. I'm only using one machine for Apache Drill and Zookeeper's cluster, the machine's IP is 10.178.23.140)
So I keep getting this error:
Exception in thread "main" org.apache.drill.exec.exception.DrillbitStartupException: Failure during initial startup of Drillbit.
at org.apache.drill.exec.server.Drillbit.start(Drillbit.java:295)
at org.apache.drill.exec.server.Drillbit.start(Drillbit.java:271)
at org.apache.drill.exec.server.Drillbit.main(Drillbit.java:267)
Caused by: org.apache.drill.exec.exception.DrillbitStartupException: Drillbit is disallowed to bind to loopback address in distributed mode.
at org.apache.drill.exec.service.ServiceEngine.checkLoopbackAddress(ServiceEngine.java:186)
at org.apache.drill.exec.service.ServiceEngine.start(ServiceEngine.java:146)
at org.apache.drill.exec.server.Drillbit.run(Drillbit.java:119)
at org.apache.drill.exec.server.Drillbit.start(Drillbit.java:291)
... 2 more
Why does drillbit complain about being bound to a loopback address ?!
- I didn't configure an IP for drillbit to bind to !
- And since I'm starting drillbit process on my machine, what other IP that my machine would it be try to bind to ?!
The problem was that my /etc/hosts file had this entry
This made my hostname resolvable to a loopback address. To resolve this, you can do either of the following
Source
The reason why Drill refuses to startup while bound to a loopback address, is to differentiate between Drill nodes registered in Zookeeper.