복붙노트

[HADOOP] 배 사육사 타임 아웃 기간 30000 내에서 사육사에 연결하지 못했습니다

HADOOP

배 사육사 타임 아웃 기간 30000 내에서 사육사에 연결하지 못했습니다

Failed to connect to zookeeper (10.10.10.205:2181) within 2x zookeeper timeout period 30000

나는 내 로컬 시스템에 geomesa 클라이언트를 실행하기 위해 노력하고있어. 내 가상 머신에 설치 하둡, accumulo 및 사육사를했습니다 (그 IP 10.10.10.205입니다) 내 사육사가 실행되는 것을 볼 수 있습니다.

2187 Jps
24929 NameNode
25610 Main
25729 Main
25203 SecondaryNameNode
25055 DataNode
30767 QuorumPeerMain

그러나 때 나는 클라이언트를 통해 연결을 시도하고있다. 이 오류가 계속.

java.lang.RuntimeException: Failed to connect to zookeeper (10.10.10.205:2181) within 2x zookeeper timeout period 30000
    at org.apache.accumulo.fate.zookeeper.ZooSession.connect(ZooSession.java:124)
    at org.apache.accumulo.fate.zookeeper.ZooSession.getSession(ZooSession.java:164)
    at org.apache.accumulo.fate.zookeeper.ZooReader.getSession(ZooReader.java:43)
    at org.apache.accumulo.fate.zookeeper.ZooReader.getZooKeeper(ZooReader.java:47)
    at org.apache.accumulo.fate.zookeeper.ZooCache.getZooKeeper(ZooCache.java:75)
    at org.apache.accumulo.fate.zookeeper.ZooCache.access$800(ZooCache.java:50)
    at org.apache.accumulo.fate.zookeeper.ZooCache$2.run(ZooCache.java:318)
    at org.apache.accumulo.fate.zookeeper.ZooCache$2.run(ZooCache.java:295)
    at org.apache.accumulo.fate.zookeeper.ZooCache$ZooRunnable.retry(ZooCache.java:190)
    at org.apache.accumulo.fate.zookeeper.ZooCache.get(ZooCache.java:347)
    at org.apache.accumulo.fate.zookeeper.ZooCache.get(ZooCache.java:282)
    at org.apache.accumulo.core.client.ZooKeeperInstance.getInstanceID(ZooKeeperInstance.java:169)
    at org.apache.accumulo.core.client.ZooKeeperInstance.<init>(ZooKeeperInstance.java:159)
    at org.apache.accumulo.core.client.ZooKeeperInstance.<init>(ZooKeeperInstance.java:140)
    at org.locationtech.geomesa.accumulo.data.AccumuloDataStoreFactory$.buildAccumuloConnector(AccumuloDataStoreFactory.scala:109)
    at org.locationtech.geomesa.accumulo.data.AccumuloDataStoreFactory$$anonfun$1.apply(AccumuloDataStoreFactory.scala:43)
    at org.locationtech.geomesa.accumulo.data.AccumuloDataStoreFactory$$anonfun$1.apply(AccumuloDataStoreFactory.scala:43)
    at scala.Option.getOrElse(Option.scala:121)
    at org.locationtech.geomesa.accumulo.data.AccumuloDataStoreFactory.createDataStore(AccumuloDataStoreFactory.scala:42)
    at org.locationtech.geomesa.accumulo.data.AccumuloDataStoreFactory.createDataStore(AccumuloDataStoreFactory.scala:31)
    at org.geotools.data.DataAccessFinder.getDataStore(DataAccessFinder.java:130)
    at org.geotools.data.DataStoreFinder.getDataStore(DataStoreFinder.java:89)
    at com.hps.GeomesaClient.<init>(GeomesaClient.java:50)
    at com.hps.GeomesaTest.setup(GeomesaTest.java:71)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:498)
    at org.junit.internal.runners.ClassRoadie.runBefores(ClassRoadie.java:49)
    at org.junit.internal.runners.ClassRoadie.runProtected(ClassRoadie.java:36)
    at org.junit.internal.runners.JUnit4ClassRunner.run(JUnit4ClassRunner.java:42)
    at org.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:252)
    at org.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:141)
    at org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:112)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:498)
    at org.apache.maven.surefire.util.ReflectionUtils.invokeMethodWithArray(ReflectionUtils.java:189)
    at org.apache.maven.surefire.booter.ProviderFactory$ProviderProxy.invoke(ProviderFactory.java:165)
    at org.apache.maven.surefire.booter.ProviderFactory.invokeProvider(ProviderFactory.java:85)
    at org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:115)
    at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:75)

여기 우둔입니다. 나는 그것을 해결하기 위해 어떻게 해야할지 모르겠어요. 이 아래에있는 내 CFG 파일입니다 :

tickTime=2000
initLimit=10
syncLimit=5
dataDir=/var/zookeeper
clientPort=2181

업데이트

이것은 JPS의 출력 -ml

    Picked up _JAVA_OPTIONS: -Djava.net.preferIPv4Stack=true
4334 org.apache.accumulo.start.Main master --address localhost
5644 org.apache.hadoop.hdfs.server.namenode.NameNode
24363 sun.tools.jps.Jps -ml
5944 org.apache.hadoop.hdfs.server.namenode.SecondaryNameNode
5778 org.apache.hadoop.hdfs.server.datanode.DataNode
4192 org.apache.accumulo.start.Main tserver --address localhost
24253 org.apache.zookeeper.server.quorum.QuorumPeerMain /opt/zookeeper/bin/../conf/zoo.cfg

|이 NETSTAT -tlnp의 JAVA_OPTIONS를 적용한 후 업데이트 된 출력 그렙 자바

tcp        0      0 127.0.0.1:9997          0.0.0.0:*               LISTEN      4192/java
tcp        0      0 127.0.0.1:9999          0.0.0.0:*               LISTEN      4334/java
tcp        0      0 127.0.0.1:10001         0.0.0.0:*               LISTEN      4334/java
tcp        0      0 127.0.0.1:10002         0.0.0.0:*               LISTEN      4192/java
tcp        0      0 0.0.0.0:50070           0.0.0.0:*               LISTEN      5644/java
tcp        0      0 0.0.0.0:50010           0.0.0.0:*               LISTEN      5778/java
tcp        0      0 0.0.0.0:50075           0.0.0.0:*               LISTEN      5778/java
tcp        0      0 0.0.0.0:39233           0.0.0.0:*               LISTEN      24253/java
tcp        0      0 0.0.0.0:50020           0.0.0.0:*               LISTEN      5778/java
tcp        0      0 0.0.0.0:2181            0.0.0.0:*               LISTEN      24253/java
tcp        0      0 0.0.0.0:9000            0.0.0.0:*               LISTEN      5644/java
tcp        0      0 0.0.0.0:50090           0.0.0.0:*               LISTEN      5944/java

사람이 문제가 무엇인지 알고 있다면 도와주세요. 감사 :)

해결법

    from https://stackoverflow.com/questions/47746720/failed-to-connect-to-zookeeper-within-2x-zookeeper-timeout-period-30000 by cc-by-sa and MIT license