Hi All. I re-established my server from scratch, and installed the 21x server. Now, cqlsh works right out of the box.
When I had last setup the server, I had (accidentally) installed the 20x server on first attempt, removed it, and then installed the 21x series server. Seems that caused some hidden problem. I am heartfully grateful to everyone for bearing with me. Thanks and Regards, Ajay On Tue, Sep 15, 2015 at 10:16 AM, Ajay Garg <[email protected]> wrote: > Hi Jared. > > Thanks for your help. > > I made the config-changes. > Also, I changed the seed (right now, we are just trying to get one > instance up and running) :: > > ################################################################ > seed_provider: > # Addresses of hosts that are deemed contact points. > # Cassandra nodes use this list of hosts to find each other and learn > # the topology of the ring. You must change this if you are running > # multiple nodes! > - class_name: org.apache.cassandra.locator.SimpleSeedProvider > parameters: > # seeds is actually a comma-delimited list of addresses. > # Ex: "<ip1>,<ip2>,<ip3>" > - seeds: "our.ip.address.here" > ################################################################ > > > > > Following is the netstat output :: > > ################################################################ > ajay@comp:~$ sudo netstat -apn | grep 9042 > tcp6 0 0 0.0.0.0:9042 :::* > LISTEN 22469/java > ################################################################ > > > > Still, when I try, we get :: > > ################################################################ > ajay@comp:~$ cqlsh our.ip.address.here > Connection error: ('Unable to connect to any servers', > {'our.ip.address.here': error(None, "Tried connecting to > [('our.ip.address.here', 9042)]. Last error: None")}) > ################################################################ > > > :( :( > > On Mon, Sep 14, 2015 at 11:00 PM, Jared Biel > <[email protected]> wrote: >> Is there a reason that you're setting listen_address and rpc_address to >> localhost? >> >> listen_address doc: "the Right Thing is to use the address associated with >> the hostname". So, set the IP address of this to eth0 for example. I believe >> if it is set to localhost then you won't be able to form a cluster with >> other nodes. >> >> rpc_address: this is the address to which clients will connect. I recommend >> 0.0.0.0 here so clients can connect to IP address of the server as well as >> localhost if they happen to reside on the same instance. >> >> >> Here are all of the address settings from our config file. 192.168.1.10 is >> the IP address of eth0 and broadcast_address is commented out. >> >> listen_address: 192.168.1.10 >> # broadcast_address: 1.2.3.4 >> rpc_address: 0.0.0.0 >> broadcast_rpc_address: 192.168.1.10 >> >> Follow these directions to get up and running with the first node >> (destructive process): >> >> 1. Stop cassandra >> 2. Remove data from cassandra var directory (rm -rf /var/lib/cassandra/*) >> 3. Make above changes to config file. Also set seeds to the eth0 IP address >> 4. Start cassandra >> 5. Set seeds in config file back to "" after cassandra is up and running. >> >> After following that process, you'll be able to connect to the node from any >> host that can reach Cassandra's ports on that node ("cqlsh" command will >> work.) To join more nodes to the cluster, follow the steps same steps as >> above, except the seeds value to the IP address of an already running node. >> >> Regarding the empty "seeds" config entry: our configs are automated with >> configuration management. During the node bootstrap process a script >> performs the above. The reason that we set seeds back to empty is that we >> don't want nodes coming up/down to cause the config file to change and thus >> cassandra to restart needlessly. So far we haven't had any issues with seeds >> being set to empty after a node has joined the cluster, but this may not be >> the recommended way of doing things. >> >> -Jared >> >> On 14 September 2015 at 16:46, Ajay Garg <[email protected]> wrote: >>> >>> Hi All. >>> >>> Thanks for your replies. >>> >>> a) >>> cqlsh <IP-Address of server> does not work either :( >>> >>> >>> b) >>> Following are the parameters as asked :: >>> >>> listen_address: localhost >>> rpc_address: localhost >>> >>> broadcast_rpc_address is not set. >>> According to the yaml file :: >>> >>> # RPC address to broadcast to drivers and other Cassandra nodes. This >>> cannot >>> # be set to 0.0.0.0. If left blank, this will be set to the value of >>> # rpc_address. If rpc_address is set to 0.0.0.0, broadcast_rpc_address >>> must >>> # be set. >>> # broadcast_rpc_address: 1.2.3.4 >>> >>> >>> c) >>> Following is the netstat-output, with process information :: >>> >>> >>> ####################################################################################################### >>> ajay@comp:~$ sudo netstat -apn | grep 9042 >>> [sudo] password for admin: >>> tcp6 0 0 127.0.0.1:9042 :::* >>> LISTEN 10169/java >>> >>> ####################################################################################################### >>> >>> >>> Kindly let me know what else we can try .. it is really driving us nuttsss >>> :( >>> >>> On Mon, Sep 14, 2015 at 9:40 PM, Jared Biel >>> <[email protected]> wrote: >>> > Whoops, I accidentally pressed a hotkey and sent my message prematurely. >>> > Here's what netstat should look like with those settings: >>> > >>> > sudo netstat -apn | grep 9042 >>> > tcp6 0 0 0.0.0.0:9042 :::* >>> > LISTEN >>> > 21248/java >>> > >>> > -Jared >>> > >>> > On 14 September 2015 at 16:09, Jared Biel >>> > <[email protected]> >>> > wrote: >>> >> >>> >> I assume "@ Of node" is ethX's IP address? Has cassandra been restarted >>> >> since changes were made to cassandra.yaml? The netstat output that you >>> >> posted doesn't look right; we use settings similar to what you've >>> >> posted. >>> >> Here's what it looks like on one of our nodes. >>> >> >>> >> >>> >> -Jared >>> >> >>> >> On 14 September 2015 at 10:34, Ahmed Eljami <[email protected]> >>> >> wrote: >>> >>> >>> >>> In cassanrda.yaml: >>> >>> listen_address:@ Of node >>> >>> rpc_address:0.0.0.0 >>> >>> >>> >>> brodcast_rpc_address:@ Of node >>> >>> >>> >>> 2015-09-14 11:31 GMT+01:00 Neha Dave <[email protected]>: >>> >>>> >>> >>>> Try >>> >>>> >cqlsh <IP Address of you Server> >>> >>>> >>> >>>> regards >>> >>>> Neha >>> >>>> >>> >>>> On Mon, Sep 14, 2015 at 3:53 PM, Ajay Garg <[email protected]> >>> >>>> wrote: >>> >>>>> >>> >>>>> Hi All. >>> >>>>> >>> >>>>> We have setup a Ubuntu-14.04 server, and followed the steps exactly >>> >>>>> as >>> >>>>> per http://wiki.apache.org/cassandra/DebianPackaging >>> >>>>> >>> >>>>> Installation completes fine, Cassandra starts fine, however cqlsh >>> >>>>> does >>> >>>>> not work. >>> >>>>> We get the error :: >>> >>>>> >>> >>>>> >>> >>>>> >>> >>>>> ####################################################################################################### >>> >>>>> ajay@comp:~$ cqlsh >>> >>>>> Connection error: ('Unable to connect to any servers', {'127.0.0.1': >>> >>>>> error(None, "Tried connecting to [('127.0.0.1', 9042)]. Last error: >>> >>>>> None")}) >>> >>>>> >>> >>>>> >>> >>>>> ####################################################################################################### >>> >>>>> >>> >>>>> >>> >>>>> >>> >>>>> Version-Info :: >>> >>>>> >>> >>>>> >>> >>>>> >>> >>>>> ####################################################################################################### >>> >>>>> ajay@comp:~$ dpkg -l | grep cassandra >>> >>>>> ii cassandra 2.1.9 >>> >>>>> all distributed storage system for structured data >>> >>>>> >>> >>>>> >>> >>>>> ####################################################################################################### >>> >>>>> >>> >>>>> >>> >>>>> >>> >>>>> The port "seems" to be opened fine. >>> >>>>> >>> >>>>> >>> >>>>> >>> >>>>> ####################################################################################################### >>> >>>>> ajay@comp:~$ netstat -an | grep 9042 >>> >>>>> tcp6 0 0 127.0.0.1:9042 :::* >>> >>>>> LISTEN >>> >>>>> >>> >>>>> >>> >>>>> ####################################################################################################### >>> >>>>> >>> >>>>> >>> >>>>> >>> >>>>> Firewall-filters :: >>> >>>>> >>> >>>>> >>> >>>>> >>> >>>>> ####################################################################################################### >>> >>>>> ajay@comp:~$ sudo iptables -L >>> >>>>> [sudo] password for ajay: >>> >>>>> Chain INPUT (policy ACCEPT) >>> >>>>> target prot opt source destination >>> >>>>> ACCEPT all -- anywhere anywhere state >>> >>>>> RELATED,ESTABLISHED >>> >>>>> ACCEPT tcp -- anywhere anywhere tcp >>> >>>>> dpt:ssh >>> >>>>> DROP all -- anywhere anywhere >>> >>>>> >>> >>>>> Chain FORWARD (policy ACCEPT) >>> >>>>> target prot opt source destination >>> >>>>> >>> >>>>> Chain OUTPUT (policy ACCEPT) >>> >>>>> target prot opt source destination >>> >>>>> >>> >>>>> >>> >>>>> ####################################################################################################### >>> >>>>> >>> >>>>> >>> >>>>> >>> >>>>> Even telnet fails :( >>> >>>>> >>> >>>>> >>> >>>>> >>> >>>>> ####################################################################################################### >>> >>>>> ajay@comp:~$ telnet localhost 9042 >>> >>>>> Trying 127.0.0.1... >>> >>>>> >>> >>>>> >>> >>>>> ####################################################################################################### >>> >>>>> >>> >>>>> >>> >>>>> >>> >>>>> Any ideas please?? We have been stuck on this for a good 3 hours now >>> >>>>> :( >>> >>>>> >>> >>>>> >>> >>>>> >>> >>>>> Thanks and Regards, >>> >>>>> Ajay >>> >>>> >>> >>>> >>> >>> >>> >>> >>> >>> >>> >>> -- >>> >>> Cordialement; >>> >>> >>> >>> Ahmed ELJAMI >>> >> >>> >> >>> > >>> >>> >>> >>> -- >>> Regards, >>> Ajay >> >> > > > > -- > Regards, > Ajay -- Regards, Ajay
