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/ 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-1.4.1\cql\", line 143, in connect File "C:\Program Files\DataStax Community\apache-cassandra\bin\..\lib\\cql-1.4.1\cql\", line 59, in __init__ File "C:\Program Files\DataStax Community\apache-cassandra\bin\..\lib\\cql-1.4.1\cql\", line 159, in establish_connection File "C:\Program Files\DataStax Community\apache-cassandra\bin\..\lib\\cql-1.4.1\cql\cassandra\", line 1265, in describe_version File "C:\Program Files\DataStax Community\apache-cassandra\bin\..\lib\\cql-1.4.1\cql\cassandra\", line 1275, in recv_describe_version File "C:\Program Files\DataStax Community\apache-cassandra\bin\..\lib\\thrift\protocol\", line 126, in readMessageBegin File "C:\Program Files\DataStax Community\apache-cassandra\bin\..\lib\\thrift\protocol\", line 206, in readI32 File "C:\Program Files\DataStax Community\apache-cassandra\bin\..\lib\\thrift\transport\", line 63, in readAll EOFError


source to share

1 answer

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



All Articles