Can't connect from CQL to Cassandra 2.0.10

In the server config, I disabled lean ( start_rpc: false

) because presumably this is now deprecated. The server starts normally:

INFO 12:23:09,658 Starting listening for CQL clients on localhost/127.0.0.1:9042... INFO 12:23:09,668 Not starting RPC server as requested. Use JMX (StorageService->startRPCServer()) or nodetool (enablethrift) to start it

If I try to run CQL I get this error:

C:\Program Files\DataStax Community\apache-cassandra\bin> .\cqlsh.bat Connection error: Could not connect to localhost:9160

Port 9160 is a lean port. I was under the assumption that CQL had to work in its own format.

If I try to force the port:

C:\Program Files\DataStax Community\apache-cassandra\bin> .\cqlsh.bat localhost 9042

I get this:

Traceback (most recent call last): File "C:\Program Files\DataStax Community\apache-cassandra\bin\..\..\apache-cassandra\bin\cqlsh", line 2092, in <module> main(*read_options(sys.argv[1:], os.environ)) File "C:\Program Files\DataStax Community\apache-cassandra\bin\..\..\apache-cassandra\bin\cqlsh", line 2075, in main single_statement=options.execute) File "C:\Program Files\DataStax Community\apache-cassandra\bin\..\..\apache-cassandra\bin\cqlsh", line 490, in __init__ password=password, cql_version=cqlver, transport=transport) File "C:\Program Files\DataStax Community\apache-cassandra\bin\..\lib\cql-internal-only-1.4.1.zip\cql-1.4.1\cql\connection.py", line 143, in connect File "C:\Program Files\DataStax Community\apache-cassandra\bin\..\lib\cql-internal-only-1.4.1.zip\cql-1.4.1\cql\connection.py", line 59, in __init__ File "C:\Program Files\DataStax Community\apache-cassandra\bin\..\lib\cql-internal-only-1.4.1.zip\cql-1.4.1\cql\thrifteries.py", line 159, in establish_connection File "C:\Program Files\DataStax Community\apache-cassandra\bin\..\lib\cql-internal-only-1.4.1.zip\cql-1.4.1\cql\cassandra\Cassandra.py", line 1265, in describe_version File "C:\Program Files\DataStax Community\apache-cassandra\bin\..\lib\cql-internal-only-1.4.1.zip\cql-1.4.1\cql\cassandra\Cassandra.py", line 1275, in recv_describe_version File "C:\Program Files\DataStax Community\apache-cassandra\bin\..\lib\thrift-python-internal-only-0.9.1.zip\thrift\protocol\TBinaryProtocol.py", line 126, in readMessageBegin File "C:\Program Files\DataStax Community\apache-cassandra\bin\..\lib\thrift-python-internal-only-0.9.1.zip\thrift\protocol\TBinaryProtocol.py", line 206, in readI32 File "C:\Program Files\DataStax Community\apache-cassandra\bin\..\lib\thrift-python-internal-only-0.9.1.zip\thrift\transport\TTransport.py", line 63, in readAll EOFError

+3


source to share


1 answer


cqlsh for Cassandra 2.0.x uses Thrift to communicate with the server.



https://issues.apache.org/jira/browse/CASSANDRA-6307

+2


source







All Articles