can't add third node when following steps for creating cluster in Book Ch. 6

32 views
Skip to first unread message

Matthew Dennis

unread,
Jan 16, 2018, 10:48:28 PM1/16/18
to RavenDB - 2nd generation document database
After I add the second node, both nodes are Voting and adding a third node fails due to lack of Leader.  Neither node is marked as Leader.

In fact it appears that all cluster related functionality fails due to lack of leader.

Build 40025, Version 4.0, SemVer 4.0.0-rc-40025, Commit ad047bc

Matthew Dennis

unread,
Jan 16, 2018, 11:25:56 PM1/16/18
to RavenDB - 2nd generation document database
I found the issue.  The Book says to start the second node with
./Server/Raven.Server.exe --ServerUrl=http://127.0.0.2:8080 --Logs.Path=Logs/B --DataDir=Data/B
but it should be
./Server/Raven.Server.exe  --ServerUrl=http://127.0.0.2:8080 --ServerUrl.Tcp=tcp://127.0.0.2:38888 --Logs.Path=Logs/B --DataDir=Data/B
Otherwise it listens on 127.0.0.1:38888 

Matthew Dennis

unread,
Jan 16, 2018, 11:33:04 PM1/16/18
to RavenDB - 2nd generation document database
Also, the online documentation says
TcpServerUrl=tcp://0.0.0.0:38888
not ServerUrl.Tcp=tcp://0.0.0.0:38888

Matthew Dennis

unread,
Jan 16, 2018, 11:37:48 PM1/16/18
to RavenDB - 2nd generation document database
According to the documentation, this should not be required as the TCP url should be built from the Http url if the TCP url is not provided, however it is not working correctly.

Oren Eini (Ayende Rahien)

unread,
Jan 17, 2018, 2:24:30 AM1/17/18
to ravendb

Hibernating Rhinos Ltd  

Oren Eini l CEO Mobile: + 972-52-548-6969

Office: +972-4-622-7811 l Fax: +972-153-4-622-7811

 


--
You received this message because you are subscribed to the Google Groups "RavenDB - 2nd generation document database" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ravendb+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Oren Eini (Ayende Rahien)

unread,
Jan 17, 2018, 2:24:47 AM1/17/18
to ravendb
Yes, it should be automatically retrieved, we'll check this

Hibernating Rhinos Ltd  

Oren Eini l CEO Mobile: + 972-52-548-6969

Office: +972-4-622-7811 l Fax: +972-153-4-622-7811

 


Matthew Dennis

unread,
Jan 17, 2018, 11:53:59 AM1/17/18
to RavenDB - 2nd generation document database


On Tuesday, January 16, 2018 at 10:48:28 PM UTC-5, Matthew Dennis wrote:

Oren Eini (Ayende Rahien)

unread,
Jan 17, 2018, 2:23:50 PM1/17/18
to ravendb
Can you try this with the latest nightly?

Hibernating Rhinos Ltd  

Oren Eini l CEO Mobile: + 972-52-548-6969

Office: +972-4-622-7811 l Fax: +972-153-4-622-7811

 


Matthew Dennis

unread,
Jan 17, 2018, 2:30:59 PM1/17/18
to RavenDB - 2nd generation document database
I did.  
  • without the --ServerUrl.Tcp=..., when the second node is added a Leader can't be found.
  • with the --ServerUrl.Tcp=..., when the second node is added a Leader is chosen and I can now add the third node.
I thought it might be that the Uri.DnsSafeHost property, used to create the TCP endpoint if the ServerUrl.Tcp is not specified, was returning the same value for 127.0.0.X, but a simple test showed this was not the case, so the bug for creating the default ServerUrl.Tcp lies elsewhere.
To unsubscribe from this group and stop receiving emails from it, send an email to ravendb+u...@googlegroups.com.

Matthew Dennis

unread,
Jan 18, 2018, 12:22:03 PM1/18/18
to RavenDB - 2nd generation document database
I double checked with the RC and even with the corrected tcp url, the cluster failed to agree on a Leader after the second node was added.  Going to the nightly build resolved the issue, as it did yesterday.
To unsubscribe from this group and stop receiving emails from it, send an email to ravendb+u...@googlegroups.com.

Matthew Dennis

unread,
Jan 18, 2018, 12:22:37 PM1/18/18
to RavenDB - 2nd generation document database
I double checked with the RC and even with the corrected tcp url, the cluster failed to agree on a Leader after the second node was added.  Going to the nightly build resolved the issue, as it did yesterday.

On Wednesday, January 17, 2018 at 2:24:30 AM UTC-5, Oren Eini wrote:
To unsubscribe from this group and stop receiving emails from it, send an email to ravendb+u...@googlegroups.com.

Oren Eini (Ayende Rahien)

unread,
May 24, 2018, 8:06:24 AM5/24/18
to ravendb
Hi,
Just to let you know, I just verified that this works without ServerUrl.Tcp in the current release.

To unsubscribe from this group and stop receiving emails from it, send an email to ravendb+unsubscribe@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages