From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jan Friesse Date: Thu, 01 Dec 2011 08:51:00 +0100 Subject: [Cluster-devel] [PATCH] config: drastically improve cman RRP configuration handling In-Reply-To: <1322657478-19020-1-git-send-email-fdinitto@redhat.com> References: <1322657478-19020-1-git-send-email-fdinitto@redhat.com> Message-ID: <4ED731E4.2030303@redhat.com> List-Id: To: cluster-devel.redhat.com MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Patch looks good with one question. Fabio M. Di Nitto wrote: > From: "Fabio M. Di Nitto" > > - don't allow configuration of more than 2 rings > - allow overrided of alternate mcast address and port via > envars > - when using broadcast, set different ports on second ring. > this also required a substantial change in transport handling > ... > + if (!strcmp(altmcast_name, mcast_name) && > + ((altportnum == portnum) || (altportnum == portnum - 1) || (portnum == altportnum - 1))) { > + sprintf(error_reason, "Alternate communication channel (mcast: %s ports: %d,%d) cannot use\n" > + "same address and ports of primary channel (mcast: %s ports: %d,%d)", > + altmcast_name, altportnum, altportnum - 1, > + mcast_name, portnum, portnum - 1); (altportnum == portnum - 1) || (portnum == altportnum - 1)) -> (altportnum == portnum - 1) || (altportnum == portnum + 1)), but corosync uses only port and port -1, so second condition seems to be useless (on the other hand, it doesn't hurt anything). > + write_cman_pipe(error_reason); > + return -1;