The copy-cluster-topology-info.sh
script helps to collect token and topology information
of a Cassandra/DSE cluster. It generates output to stdout containing the information ip,
dc, rack, and token information for each node in the cluster. Tokens are provided in an
easy copy paste format to allow east transfer into a cassandra.yaml file.
Usage:
-h Display this help message.
-f <nodetool_ring_path> Use an already existing output file instead of running nodetool
-n <nodetool_options> Options to pass to nodetool to connect to the cluster
This script can either connect directly to a cluster to gather the topology information via
nodetool ring
, or the script can be passed an existing nodetool ring
output via -f
.
For direct connections to the cluster, additional options can be passed via -n
.
Tokens originating from node 127.0.0.1
Datacenter: DC1
Rack: rack1
initial_token: -8326373729452684600, -7009881189318773365, -6883711675282157593, -5976786311557324131, -4114811140028499523, -4036962345757685935, -3386491670658818725, -3309514457584953813, -2543135351299640834, -2091674090045776529, -1039554621406842058, -989081193206046680, -776059406489677984, -670140744064951340, -264556491405382134, 94151398450452454, 275158214645708928, 791448281960703983, 863710194797690017, 2319107027043734592, 3119909257055389540, 3548265033124357367, 3839068021502480491, 4608452790324717293, 5052863957076903839, 5089115876476621819, 7053791745765487935, 7232300681592895739, 8023141398708194852, 8639825857670028628, 8726107672669131631, 8832922882596217127
Tokens originating from node 127.0.0.2
Datacenter: DC1
Rack: rack2
initial_token: -7519875965734991370, -7402427434218943976, -7094883070389599211, -7089885656954440826, -6697876810934770165, -6102654457849578656, -5270490495679576494, -2756469173701262080, -2659944927185262687, -2193157108662693173, -1727261675851423011, -1342678649962563829, -845709168759390844, -179627670807257596, 522911912395693296, 903078073194341458, 1388513990173527790, 1397168569362938010, 2195493925343702849, 3268717371151135976, 3365619242235394323, 4344758884554769099, 4510227052021607874, 5585557017162436937, 5848655203345059309, 6128939909341808753, 6953530468936647940, 7144963507986154961, 7656177531313469792, 8260758765723262359, 9082405773429332147, 9222656968755891553
Tokens originating from node 127.0.0.3
Datacenter: DC1
Rack: rack3
initial_token: -9142095938795267251, -9004748674349485682, -7915417717645622190, -7032003175519971464, -6783638711993285485, -6080482391422296052, -5911760099898037063, -5696097161040824627, -5644090599596856996, -5157581831883989124, -3918283433834526985, -2040851516766993665, -604993389899652898, 1652003969824422004, 1652996451140313446, 1715499723781690417, 2195572429177018697, 2599051478607276483, 2612448882163570523, 3812045437940670933, 4075486016887897385, 5421888648229894955, 5928699938566545721, 6168816855556760199, 6196816164916654175, 6325767658354963406, 6594141465463094965, 7554359443318574261, 7874289374821793687, 8286031499710540007, 8450907071888065223, 8507462487370440719
Tokens originating from node 10.0.0.1
Datacenter: DC2
Rack: rack1b
initial_token: -8540210650852117916, -8259818776939698731, -7525088408651155539, -7485352344600098806, -6993423405247554509, -6964259387770172276, -6034941868782523934, -5794435291046729622, -5557217654203187383, -4872178333854947103, -4598101648227109752, -4101915135666522245, -3087535950262186535, -2107120048382829793, -1000364055590822877, -492212038227404033, -317936713219349942, -296580135645387296, 423326274710351020, 1408899811414075114, 2554874397154359787, 2832273745951066812, 3013715343723120396, 3263252054296647502, 3406904771232252461, 6990033699989802741, 7420679318932581215, 7447584134736495110, 7453319345604124132, 7541483659086036654, 7768263106031614109, 8094884559655792330
Tokens originating from node 10.13.90.26
Datacenter: DC2
Rack: rack1b
initial_token: -7740716690856118620, -7015167496967762544, -6086184674771768297, -5714678184535578785, -5440290095415195875, -5438556245893737974, -5255464970796247380, -4322098372544494616, -4153945168319902287, -3834478064385214484, -3665747187546052394, -3299780374098526675, -2376645802871039637, -2066893825091798482, -781622731919247888, -358989174290406656, 178835584232310910, 328319380153710003, 1369502571843939100, 3137214274217280692, 4371302129299141955, 4408348052150494415, 5077783225378054450, 5335869650803207164, 6609348543198087413, 6912526328798734052, 7017093692332323619, 7303678001938749518, 7432140632563903663, 8115491723560378170, 8375339832118088442, 8479669559866133235
Tokens originating from node 10.13.88.29
Datacenter: rack1b
Rack: DC2
initial_token: -8940731702786748758, -8190680797948599874, -7885423613837613259, -7101472744994011981, -5661045194471225484, -5652682538234704002, -5534302871704390109, -5481514168105237057, -3729857823972655474, -3267795326254957682, -2631649343188406515, -2120079247395870011, -1992726308367323034, -1722779799382546239, -1527108492804334586, -746874194033904167, -316978300581703660, 971312629113550111, 1530348376461488660, 2100060728091377089, 3360473389126463766, 3624596337986477283, 5273146303233253933, 5451817630001971444, 5575787327776191270, 6640308093133606423, 6906817382767304597, 7220624540228324787, 7583594668649165193, 8220967745454095770, 8404529424460886752, 8428707699410172845