Storm本地模式環境問題
阿新 • • 發佈:2019-01-10
執行從github上把 storm-starter的程式碼 fork下來 https://github.com/nathanmarz/storm-starter 將m2-pom.xml重新命名為pom.xml,編譯一下,匯入eclipse裡 執行第一個例子ExclamationTopology 問題1 java.net.SocketException: Address family not supported by protocol family: connect 查了下 http://stackoverflow.com/questions/16373906/address-family-not-supported-by-protocol-family-socketexception-on-a-specific stackoverflow上說是因為Java7會自動使用IPv6進行連線,修改方法是 新增jvm引數 -Djava.net.preferIPv4Stack=true,該引數會強制jvm走IPv4 問題2
org.apache.storm.zookeeper.server.ServerCnxn$EndOfStreamException: Unable to read additional data from client sessionid 0x152f5667669000a, likely client has closed socket
at org.apache.storm.zookeeper.server.NIOServerCnxn.doIO(NIOServerCnxn.java:228) ~[storm-core-0.9.6.jar:0.9.6]
at org.apache.storm.zookeeper.server.NIOServerCnxnFactory.run(NIOServerCnxnFactory.java:208) [storm-core-0.9.6.jar:0.9.6]
at java.lang.Thread.run(Thread.java:662) [na:1.6.0_43]
注意,這裡只是出現警告,不影響程式正常執行。 是第一次嘗試連線zookeeper失敗出現的警告。 問題解決,本地執行ok