Cannot start 3 nodes cluster


#1

Hi,
I am trying to start a 3-node cluster.
I followed this guides:https://www.cockroachlabs.com/docs/stable/performance-benchmarking-with-tpc-c.html#step-3-load-data-for-the-benchmark

And when I started my 3 nodes and then init on one of my nodes, I found that only the node I initialized had prints and the other two nodes still waited for connection.

Here is the command I ran on my 3 nodes:
cockroach start --insecure --advertise-addr=v09 --join=v09,v06,v07 --cache=.25 --max-sql-memory=.25

By the way, I found I could initialize v09 and then initialize v06. They showed different cluster ID. And node numbers are both 1.

Thanks for your help.


(Ron Arévalo) #2

Hey @lemon,

Your command is correct, the only thing I would want to point out is that when you use the start command on the 2 subsequent nodes the --advertise-addr should be the internal IP of that node.

So you should be running 3 start commands, one on each node:

cockroach start --insecure --advertise-addr=v09 --join=v09,v06,v07 --cache=.25 --max-sql-memory=.25

cockroach start --insecure --advertise-addr=v06 --join=v09,v06,v07 --cache=.25 --max-sql-memory=.25

cockroach start --insecure --advertise-addr=v07 --join=v09,v06,v07 --cache=.25 --max-sql-memory=.25

Regarding the initializing v09 and v06 and having different cluster ID’s—that is to be expected. If you ssh into each machine and run the init command, you will initialize a 1 node cluster which is why you are seeing different cluster ID’s.

If you have followed the steps above and are still having trouble, can you provide me with the logs. You can email them to me at ron@cockroachlabs.com.

You can get the logs by using the cockroach debug command, we have more info on that here,

Thanks,

Ron


#3

Hey @ronarev ,
Thanks a lot! Your answer does help me solve the problem!
Maybe you could modify this part
–advertise-addr=< node1 internal address >


(Ron Arévalo) #4

Hey @lemon,

We already did! We added in a more explicit step to make sure everyone knows you need to change the --advertise-addr to the IP of the node you’re on.

Thanks!