mirror_corosync/exec
Fabio M. Di Nitto b05477859f votequorum: fix expected_votes propagation
it is not correct to randomly accept expected_votes from any node in
the cluster. We can only allow expected_votes from quorate nodes.

A quorate cluster is "always" right and have the correct expected_votes.

One of the different bug triggers:

quorum {
  expected_votes: 8
  auto_tie_breaker: 1
  last_man_standing: 1
}

start all 8 nodes.
clean shut down 2 nodes.
wait for lms to kick in.
kill 3 nodes with highest nodeid
(we want to retain a quorate partition of 3 nodes)
start one node again -> cluster will be unquorate

This happens because the node rebooting/rejoining with
non current cluster status will propagate an expected_votes of 8,
while in reality the cluster is down to expected_votes: 3.

4 nodes are still < 5 (quorum for 8 nodes/votes).

In order to avoid this condition, we need to exchange expected_votes
information among nodes but we cannot randomly trust everybody.

1) Allow expected_votes to be changed cluster-wide only if the
   information is coming from a quorate node.
2) Fix node->expected_votes based on quorate status
3) allow a joining node to decrease quorum and expected_votes
   if the node is not yet quorate, but it's joining a quorate
   cluster

Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Reviewed-by: Christine Caulfield <ccaulfie@redhat.com>
2012-01-26 14:32:54 +01:00
..
.gitignore Add .gitignore files. 2010-10-21 07:43:46 -07:00
apidef.c Remove lcr directory, files, and references since it is no longer needed 2012-01-16 09:30:40 -07:00
apidef.h Move coroapi out of external headers 2012-01-07 17:47:45 -07:00
cfg.c Remove all unneccessary "\n" from log messages 2012-01-23 13:08:23 +11:00
cmap.c Remove all unneccessary "\n" from log messages 2012-01-23 13:08:23 +11:00
coroparse.c Remove all unneccessary "\n" from log messages 2012-01-23 13:08:23 +11:00
cpg.c Remove all unneccessary "\n" from log messages 2012-01-23 13:08:23 +11:00
crypto.c Fix some compiler warnings 2011-08-09 10:37:16 +10:00
crypto.h remove all trailing blanks 2009-04-22 08:03:55 +00:00
cs_queue.h Add totempg_threaded_mode_enable() api 2011-08-22 19:31:52 -07:00
evil.c Remove lcr directory, files, and references since it is no longer needed 2012-01-16 09:30:40 -07:00
evil.h Follow synchronization model of event service so corosync without openais 2009-06-28 04:50:18 +00:00
evs.c Remove all unneccessary "\n" from log messages 2012-01-23 13:08:23 +11:00
fsm.h Remove all unneccessary "\n" from log messages 2012-01-23 13:08:23 +11:00
icmap.c icmap: Add fast version of inc and dec operation 2012-01-13 11:13:38 +01:00
ipc_glue.c Remove all unneccessary "\n" from log messages 2012-01-23 13:08:23 +11:00
logsys.c LOG: make sure that debug works to syslog 2012-01-25 11:33:09 +11:00
main.c Add debug log messages to corosync for join/leave 2012-01-25 11:33:09 +11:00
main.h Get rid of external config loader in include/engine/config.h 2012-01-16 09:30:50 -07:00
mainconfig.c Silent a coverity warning about a variable being uninit when it actually is 2012-01-16 17:21:39 -07:00
mainconfig.h Change all ais references to corosync 2012-01-12 07:29:15 -07:00
Makefile.am build: fix distcheck regression introduced from ykd binding 2012-01-17 12:40:42 +01:00
mon.c Remove all unneccessary "\n" from log messages 2012-01-23 13:08:23 +11:00
pload.c Remove all unneccessary "\n" from log messages 2012-01-23 13:08:23 +11:00
quorum.c Initial removal of plugins 2012-01-16 09:30:26 -07:00
quorum.h quorum.h (quorum_set_quorate_fn_t): make first param const 2009-04-08 06:43:03 +00:00
schedwrk.c Add schedwrk_create_nolock function 2010-01-22 09:45:29 +00:00
schedwrk.h Add schedwrk_create_nolock function 2010-01-22 09:45:29 +00:00
service.c Remove all unneccessary "\n" from log messages 2012-01-23 13:08:23 +11:00
service.h quorum: fix votequorum service initialization 2012-01-17 14:49:55 +01:00
sync.c Remove all unneccessary "\n" from log messages 2012-01-23 13:08:23 +11:00
sync.h pass transitional members into the sync_init() callbacks. 2010-02-04 00:18:51 +00:00
syncv2.c Remove all unneccessary "\n" from log messages 2012-01-23 13:08:23 +11:00
syncv2.h pass transitional members into the sync_init() callbacks. 2010-02-04 00:18:51 +00:00
testquorum.c Initial removal of plugins 2012-01-16 09:30:26 -07:00
timer.c libqb: make timer api a wrapper around qb_loop timers. 2011-08-09 10:37:14 +10:00
timer.h Allow compile master on RHEL 6 2011-08-09 11:29:48 +02:00
totemconfig.c Make local_node ring0 address read-only 2012-01-20 11:09:37 +01:00
totemconfig.h Use nodeid provided in nodelist 2012-01-20 11:08:35 +01:00
totemiba.c totemiba: Remove unused wthread.h include 2012-01-24 16:28:55 +01:00
totemiba.h libqb: convert coropoll calls to qb_loop calls. 2011-08-09 10:37:14 +10:00
totemip.c Free mem allocated by getaddrinfo 2011-11-11 08:11:17 +11:00
totemmrp.c totemmrp: Allow compilation without warnings 2011-10-24 17:43:32 +02:00
totemmrp.h Add totempg_threaded_mode_enable() api 2011-08-22 19:31:52 -07:00
totemnet.c Remove all unneccessary "\n" from log messages 2012-01-23 13:08:23 +11:00
totemnet.h libqb: convert coropoll calls to qb_loop calls. 2011-08-09 10:37:14 +10:00
totempg.c Move logsys.c into corosync binary instead of a shared object 2012-01-06 18:19:59 -07:00
totemrrp.c Remove all unneccessary "\n" from log messages 2012-01-23 13:08:23 +11:00
totemrrp.h Store rrp faulty status of ring in cmap 2012-01-11 14:12:06 +01:00
totemsrp.c Remove all unneccessary "\n" from log messages 2012-01-23 13:08:23 +11:00
totemsrp.h Add totempg_threaded_mode_enable() api 2011-08-22 19:31:52 -07:00
totemudp.c Remove all unneccessary "\n" from log messages 2012-01-23 13:08:23 +11:00
totemudp.h Remove hdb.h header includes from unnecessary files 2011-08-23 22:28:40 -07:00
totemudpu.c Remove all unneccessary "\n" from log messages 2012-01-23 13:08:23 +11:00
totemudpu.h Remove hdb.h header includes from unnecessary files 2011-08-23 22:28:40 -07:00
util.c Remove all unneccessary "\n" from log messages 2012-01-23 13:08:23 +11:00
util.h Change all ais references to corosync 2012-01-12 07:29:15 -07:00
votequorum.c votequorum: fix expected_votes propagation 2012-01-26 14:32:54 +01:00
votequorum.h votequorum: fix include to match definition name (cosmetic) 2012-01-17 12:40:42 +01:00
vsf_quorum.c votequorum: add support for nodelist config bits 2012-01-23 11:46:34 +01:00
vsf_ykd.c Remove all unneccessary "\n" from log messages 2012-01-23 13:08:23 +11:00
vsf_ykd.h quorum: link ykd back into quorum and fix build warning 2012-01-17 12:40:42 +01:00
vsf.h Convert existing documentation to doxygen format. 2011-03-12 15:03:16 +11:00
wd.c Remove all unneccessary "\n" from log messages 2012-01-23 13:08:23 +11:00