<div style="font-family: Helvetica; font-size: 13px; "><span style="color: rgb(160, 160, 168); ">On Saturday, 29. December 2012 at 14:51, Francesco Mazzoli wrote:</span></div>
                <blockquote type="cite" style="border-left-style:solid;border-width:1px;margin-left:0px;padding-left:10px;">
                    <span><div><div><div>I’m not sure what you mean here.  What does “RabbitMQ package” refers to?  Can</div><div>you be more clear on why “they converge into the same issue”?</div><div><br></div></div></div></span></blockquote><div>The package I mention refers to the package available on the RabbitMQ website. In this case I'm installing a Ubuntu package, which generates all its configuration files when installed and starts the service too.</div><div><br></div><div>The problems outlined converge into the same issue because of this last bit. It might seem like a useful feature of the package, but given that a node that should enter the cluster needs to be fresh and untouched, this is practically impossible to achieve with the cluster_nodes section in the configuration, at least when trying to avoid hacks that generate the configuration beforehand, where users and directories don't yet exist.</div><div><br></div><div>After the package installation, the node that was just freshly installed needs to be reset for these things to fully work.</div><blockquote type="cite" style="border-left-style:solid;border-width:1px;margin-left:0px;padding-left:10px;"><span><div><div><div></div><div>Well, here to change clustering behavior you would probably have to force</div><div>things a bit, either with “dangerous” commands or by `eval'ing Erlang</div><div>expressions - so you’d be delving into clustering internals that, as</div><div>implementation details, are not documented.</div><div><br></div><div>Note that you can also deploy some gentler measures like “check that the node</div><div>has clustered, try again in 5 minutes if it didn’t”, but those would be ad-hoc</div><div>measures that we can’t generalize as default behaviour.</div><div><br></div></div></div></span></blockquote><div>Sure, but I'm still interested in these, as odd as they may seem. My intent is to have an automated cluster setup, and for that to fully work, I need to know the oddities and ways to work around them. A lot of the documentation is aimed at setting up a cluster manually, which to me is a practice to be avoided in production.</div><blockquote type="cite" style="border-left-style:solid;border-width:1px;margin-left:0px;padding-left:10px;"><span><div><div><div></div><div>Netsplits are tolerated to a certain extent, but currently we don’t precisely</div><div>specify the semantics of the recovery mechanisms.  What’s surely the case is</div><div>that to use `join_cluster' both nodes have to be online - this is not that much</div><div>about netsplits but about `join_cluster' being an operation that requires</div><div>agreement from 2 parties.</div><div><br></div></div></div></span></blockquote><div>That's understandable behaviour, though I'd suggest considering some sort of retry in either scenario. Which might reduce the issues with the overall setup I've described here so far significantly.&nbsp;</div><blockquote type="cite" style="border-left-style:solid;border-width:1px;margin-left:0px;padding-left:10px;"><span><div><div><div></div><div>I’m still not sure what your problem is exactly.  If the above makes sense,</div><div>`join_cluster' should serve your needs.  For what concerns the hostname</div><div>problems, I’m waiting for more details.</div><div><br></div></div></div></span></blockquote><div>join_cluster does fit my needs, but in an automated environment, e.g. with Chef, that command would be triggered every 30 minutes. Would you consider that a good practice to do?</div><div><br></div><div>Hence me asking about experiences of automating a cluster setup in production. How people work to make it work, how people make sure a node joins the cluster, how to make sure resources aren't overused where not necessary, e.g. by triggering commands that don't need to be triggered, et.c</div><div><br>
                </div><div>Cheers, Mathias</div>