cqlsh does not work for Cassandra 3.11X and Python 2.7.X

When i Install Cassandra 3.11X and Python 2.7.X in Debian 8.8, the Cqlsh does not start. I get the following error.

debian@vm-184:/opt/apache-cassandra-3.10/bin$ ./cqlsh

Python Cassandra driver not installed, or not on PYTHONPATH. You might try "pip install cassandra-driver".

Python: /usr/local/bin/python
Module load path: ['/opt/apache-cassandra-3.10/bin/../lib/six-1.7.3-py2.py3-none-any.zip', '/opt/apache-cassandra-3.10/bin/../lib/futures-2.1.6-py2.py3-none-any.zip', '/opt/apache-cassandra-3.10/bin/../lib/cassandra-driver-internal-only-3.7.0.post0-2481531.zip/cassandra-driver-3.7.0.post0-2481531', '/opt/apache-cassandra-3.10/bin', '/usr/local/lib/python27.zip', '/usr/local/lib/python2.7', '/usr/local/lib/python2.7/plat-linux2', '/usr/local/lib/python2.7/lib-tk', '/usr/local/lib/python2.7/lib-old', '/usr/local/lib/python2.7/lib-dynload', '/usr/local/lib/python2.7/site-packages']

Error: can't decompress data; zlib not available

How do we resolve this

On RedHat 7x - Install the following packages:

# yum install zlib-devel bzip2-devel openssl-devel ncurses-devel sqlite-devel

Then...

# vi .../Python-2.7.13/Modules/Setup

uncomment the line: ...

zlib zlibmodule.c -I$(prefix)/include -L$(exec_prefix)/lib -lz

AND (re-)compile python source:

# cd .../Python-2.7.13/Modules/

# ./configure

# make

# make install

Installing Apache 3.x on any Linux-based platform, DataStax LunaEnterprise Support for Apache Cassandra — Start a Free 30-Day Trial Now. You can use this install for Mac OS X and other platforms without package support, or if you do not have Python 2.7 if using cqlsh. Teams. Q&A for Work. Stack Overflow for Teams is a private, secure spot for you and your coworkers to find and share information.

Error: can't decompress data; zlib not available

Is the zlib library install? please install zlib first.

Installing Apache Cassandra 3.x on Debian-based systems , The latest version of Cassandra 3.x is 3.11.5. Python 2.7 if using cqlsh. because the public key is not available: NO_PUBKEY A278B781FE4B2BDA sudo apt-get install cassandra-tools=3.11.x. x ## Optional utilities. 0 cqlsh does not work for Cassandra 3.11X and Python 2.7.X Aug 1 '17. 0 TextFile Sink setting for Boost configuration file Jan 16 '18.

This issue generally comes when your machine has Python 2.6 or below. Check the answer over here cassandra 2.2 CQl Shell supports python 2.7 on how to start cqlsh using python 2.7

Quoting - "Depending on your distribution and its version you cannot change the default python version of the system without breaking the system." I would recommend you to choose Debian version that uses Python2.7x natively.

How to Install Apache Cassandra 3.11.x on Ubuntu 16.04 LTS, If you operate Apache Cassandra in a Python 3 environment, you may have the cqlsh shell of Apache Cassandra. need to install Python 2.7 by yourself: Stack Overflow | The World’s Largest Online Community for Developers

How to install Apache Cassandra 3.11.x on CentOS 7 – Hostry Help , It is Python version 2.7 that is needed since in Python 3 (for example), you may have problems launching the Apache Cassandra cqlsh shell.

Issue with cassandra 3.1X and Python 2.7.13 in Debian 8.8, Hi, When I Install Cassandra 3.11X and Python 2.7.X in Debian 8.8, the Cqlsh does not start. You might try "pip install cassandra-driver". data; zlib not available Have to do some workaround like this to get it working.

Download - Apache Cassandra, Apache Cassandra 3.0 is supported until 6 months after 4.0 release (date TBD). series> specify the major version number, without dot, and with an appended x . because the public key is not available: NO_PUBKEY A278B781FE4B2BDA and ask you to post details on any issues in the corresponding Jira ticket.