Cassandra

cassandra 無法創建節儉套接字

  • January 4, 2017

我不知道為什麼我無法在 cassandra 上啟用節儉協議。

cassandra.yaml rpc_start=true port=9160.

7美分

iptables 沒有執行

防火牆沒有執行

cassandra ver 3.7(datastax repo)啟動並執行。

java version "1.8.0_51"
Java(TM) SE Runtime Environment (build 1.8.0_51-b16)
Java HotSpot(TM) 64-Bit Server VM (build 25.51-b03, mixed mode)

一月安裝

啟用 JMX

ETC..

cassandra 配置中的一切都很好,除了由於缺少 RAM 而需要交換文件。

selinux 無關緊要,但允許。

我可以從遠端連接,但這是來自nodetools enablethrift

error: Could not create ServerSocket on address /10.10.30.11:9160.
-- StackTrace --
org.apache.thrift.transport.TTransportException: Could not create ServerSocket on address /10.10.30.11:9160.
   at org.apache.thrift.transport.TNonblockingServerSocket.<init>(TNonblockingServerSocket.java:96)
   at org.apache.thrift.transport.TNonblockingServerSocket.<init>(TNonblockingServerSocket.java:79)
   at org.apache.thrift.transport.TNonblockingServerSocket.<init>(TNonblockingServerSocket.java:75)
   at org.apache.cassandra.thrift.TCustomNonblockingServerSocket.<init>(TCustomNonblockingServerSocket.java:39)
   at org.apache.cassandra.thrift.THsHaDisruptorServer$Factory.buildTServer(THsHaDisruptorServer.java:80)
   at org.apache.cassandra.thrift.TServerCustomFactory.buildTServer(TServerCustomFactory.java:55)
   at org.apache.cassandra.thrift.ThriftServer$ThriftServerThread.<init>(ThriftServer.java:131)
   at org.apache.cassandra.thrift.ThriftServer.start(ThriftServer.java:58)
   at org.apache.cassandra.service.StorageService.startRPCServer(StorageService.java:408)
   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:497)
   at sun.reflect.misc.Trampoline.invoke(MethodUtil.java:71)
   at sun.reflect.GeneratedMethodAccessor5.invoke(Unknown Source)
   at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
   at java.lang.reflect.Method.invoke(Method.java:497)
   at sun.reflect.misc.MethodUtil.invoke(MethodUtil.java:275)
   at com.sun.jmx.mbeanserver.StandardMBeanIntrospector.invokeM2(StandardMBeanIntrospector.java:112)
   at com.sun.jmx.mbeanserver.StandardMBeanIntrospector.invokeM2(StandardMBeanIntrospector.java:46)
   at com.sun.jmx.mbeanserver.MBeanIntrospector.invokeM(MBeanIntrospector.java:237)
   at com.sun.jmx.mbeanserver.PerInterface.invoke(PerInterface.java:138)
   at com.sun.jmx.mbeanserver.MBeanSupport.invoke(MBeanSupport.java:252)
   at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:819)
   at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:801)
   at com.sun.jmx.remote.security.MBeanServerAccessController.invoke(MBeanServerAccessController.java:468)
   at javax.management.remote.rmi.RMIConnectionImpl.doOperation(RMIConnectionImpl.java:1470)
   at javax.management.remote.rmi.RMIConnectionImpl.access$300(RMIConnectionImpl.java:76)
   at javax.management.remote.rmi.RMIConnectionImpl$PrivilegedOperation.run(RMIConnectionImpl.java:1311)
   at java.security.AccessController.doPrivileged(Native Method)
   at javax.management.remote.rmi.RMIConnectionImpl.doPrivilegedOperation(RMIConnectionImpl.java:1410)
   at javax.management.remote.rmi.RMIConnectionImpl.invoke(RMIConnectionImpl.java:832)
   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:497)
   at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:323)
   at sun.rmi.transport.Transport$1.run(Transport.java:200)
   at sun.rmi.transport.Transport$1.run(Transport.java:197)
   at java.security.AccessController.doPrivileged(Native Method)
   at sun.rmi.transport.Transport.serviceCall(Transport.java:196)
   at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:568)
   at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run0(TCPTransport.java:826)
   at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.lambda$run$79(TCPTransport.java:683)
   at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler$$Lambda$98/201325936.run(Unknown Source)
   at java.security.AccessController.doPrivileged(Native Method)
   at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:682)
   at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
   at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
   at java.lang.Thread.run(Thread.java:745)

任何的想法?

我也可以通過 telnet “連接”到埠 9160。

netstat輸出:

tcp        0      0 10.10.30.11:9160        0.0.0.0:*               LISTEN      4395/java 

nodetool statusthrift=> 沒有執行。

好像有衝突 rpc_server_type: hsha

當切換到sync我首先得到一個空點異常,然後在幾秒鐘後重試它開始節儉。

我遇到了同樣的問題。在切換到 之前sync,請嘗試增加rpc_max_threadshsha用作rpc_server_type

引用自:https://serverfault.com/questions/804100