What address should i use for listen_address in cassandra.yaml ? -
i trying set multinode cassandra database on 2 different machines. how supposed configure cassandra.yaml file? datastax documentation says
listen_address¶ (default: localhost ) ip address or hostname other cassandra nodes use connect node. if left unset, hostname must resolve ip address of node using /etc/hostname, /etc/hosts , or dns. not specify 0.0.0.0.
when use 'localhost' value of listen_address, runs fine on local machine , , when use ip address, fails connect. why so?
configuring nodes , seed nodes simple in cassandra steps must followed. procedure setting multi node cluster documented , quote linked document.
i think easier illustrate set of nodes 4 instead of 2 since 2 nodes make little sense running cassandra instance. if had 4 nodes split between 2 machines , 1 seed node on each machine conceptual configuration appear follows:
node1 86.82.155.1 (seed 1) node2 86.82.155.2 node3 192.82.156.1 (seed 2) node4 192.82.156.2
if each of these machines same in terms of layout can use same cassandra.yaml file across nodes.
if nodes in cluster identical in terms of disk layout, shared libraries, , on, can use same copy of cassandra.yaml file on of them
you need set ip address under -seeds
configuration in cassandra.yaml.
-seeds: internal ip address of each seed node
parameters: - seeds: "86.82.155.1,192.82.156.1"
understanding difference between node , seed node important. if these ip addresses crossed may experience issues similar describing , comment appears have corrected configuration.
seed nodes not bootstrap, process of new node joining existing cluster. new clusters, bootstrap process on seed nodes skipped.
if having trouble grasping node based architecture read achitecture in brief document or watch understanding core concepts class.
Comments
Post a Comment