Commit Graph

4 Commits

Author SHA1 Message Date
Russell Bryant
a609f79f1f Ensure that strings are null terminated after strncpy().
From the strcpy(3) man page, the following warning is given:
  The strncpy() function is similar, except that at most n bytes of src
  are  copied.  Warning: If there is no null byte among the first n bytes
  of src, the string placed in dest will not be null-terminated.

The current corosync code base does not take this warning into account
when using strncpy, potentially resulting in non-null terminated strings.

Signed-off-by: Russell Bryant <russell@russellbryant.net>
Reviewed-by: Steven Dake <sdake@redhat.com>
2011-03-07 08:30:03 -06:00
Angus Salkeld
f2a961d155 Make node state a string (not an integer)
Ryan noticed this inconsistency, all other status's
are string so this should be too.

Signed-off-by: Angus Salkeld <asalkeld@redhat.com>
Reviewed-by: Seven Dake <sdake@redhat.com>
Reviewed-by: Ryan O'Hara <rohara@redhat.com>
2011-02-08 08:10:30 +11:00
Lon Hohberger
cca89e0a06 Match up MIB to notifyd & add SNMP quorum events
Signed-off-by: Lon Hohberger <lhh@redhat.com>
Reviewed-by: Angus Salkeld <asalkeld@redhat.com>
2011-02-04 09:48:16 -07:00
Angus Salkeld
2a568d6e79 Add dbus and snmp notifier
This is to send dbus events on major cluster events:
 - membership changes
 - application connect/dissconnet from corosync
 - quorum changes

dbus events can then be converted into snmp traps by foghorn or
corosync-notifyd can be run to directly send snmp traps.

Signed-off-by: Angus Salkeld <asalkeld@redhat.com>
Signed-off-by: Lon Hohberger <lhh@redhat.com>
Reviewed-by: Steven Dake <sdake@redhat.com>
Reviewed-by: Russell Bryant <russell@russellbryant.net>
Reviewed-by: Fabio M. Di Nitto <fdinitto@redhat.com>
2011-02-04 09:47:35 -07:00