mirror of
https://git.proxmox.com/git/mirror_corosync
synced 2025-08-13 12:52:31 +00:00
Add debug log messages to corosync for join/leave
This is needed by cts. Signed-off-by: Angus Salkeld <asalkeld@redhat.com> Reviewed-by: Steven Dake <sdake@redhat.com>
This commit is contained in:
parent
3698b78de9
commit
14fd1c927a
@ -203,8 +203,6 @@ static void config_change_callback (
|
||||
/* group_name,ip,pid,join|leave */
|
||||
|
||||
for (i = 0; i < left_list_entries; i++) {
|
||||
qb_log(LOG_INFO, "Member left: %s", left_list[i].nodeid);
|
||||
|
||||
if (record_config_events_g > 0) {
|
||||
log_pt = malloc (sizeof(log_entry_t));
|
||||
list_init (&log_pt->list);
|
||||
@ -214,8 +212,6 @@ static void config_change_callback (
|
||||
}
|
||||
}
|
||||
for (i = 0; i < joined_list_entries; i++) {
|
||||
qb_log(LOG_INFO, "Member joined: %s", joined_list[i].nodeid);
|
||||
|
||||
if (record_config_events_g > 0) {
|
||||
log_pt = malloc (sizeof(log_entry_t));
|
||||
list_init (&log_pt->list);
|
||||
|
@ -49,6 +49,8 @@ class CoroTest(CTSTest):
|
||||
self.start = StartTest(cm)
|
||||
self.stop = StopTest(cm)
|
||||
self.config = {}
|
||||
self.config['logging/logger_subsys[1]/subsys'] = 'MAIN'
|
||||
self.config['logging/logger_subsys[1]/debug'] = 'on'
|
||||
self.need_all_up = True
|
||||
self.CM.start_cpg = True
|
||||
|
||||
@ -960,9 +962,8 @@ class GenStopAllBeekhof(CoroTest):
|
||||
CoroTest.__init__(self,cm)
|
||||
self.name="GenStopAllBeekhof"
|
||||
self.need_all_up = True
|
||||
self.config['logging/logger_subsys[1]/subsys'] = 'CFG'
|
||||
self.config['logging/logger_subsys[1]/debug'] = 'on'
|
||||
self.config['logging/logger_subsys[1]/tags'] = 'trace1|enter|leave'
|
||||
self.config['logging/logger_subsys[2]/subsys'] = 'CFG'
|
||||
self.config['logging/logger_subsys[2]/debug'] = 'on'
|
||||
|
||||
def __call__(self, node):
|
||||
'''Perform the 'GenStopAllBeekhof' test. '''
|
||||
@ -1100,8 +1101,8 @@ confirm watchdog action
|
||||
CoroTest.__init__(self,cm)
|
||||
self.name="WDOnForkBomb"
|
||||
self.need_all_up = False
|
||||
self.config['logging/logger_subsys[1]/subsys'] = 'WD'
|
||||
self.config['logging/logger_subsys[1]/debug'] = 'on'
|
||||
self.config['logging/logger_subsys[2]/subsys'] = 'WD'
|
||||
self.config['logging/logger_subsys[2]/debug'] = 'on'
|
||||
self.config['resources/system/memory_used/recovery'] = 'watchdog'
|
||||
self.config['resources/system/memory_used/max'] = '80'
|
||||
self.config['resources/system/memory_used/poll_period'] = '800'
|
||||
@ -1152,8 +1153,8 @@ confirm action
|
||||
CoroTest.__init__(self,cm)
|
||||
self.name="SamWdIntegration1"
|
||||
self.need_all_up = True
|
||||
self.config['logging/logger_subsys[1]/subsys'] = 'WD'
|
||||
self.config['logging/logger_subsys[1]/debug'] = 'on'
|
||||
self.config['logging/logger_subsys[2]/subsys'] = 'WD'
|
||||
self.config['logging/logger_subsys[2]/debug'] = 'on'
|
||||
|
||||
def __call__(self, node):
|
||||
'''Perform the test. '''
|
||||
@ -1186,8 +1187,8 @@ confirm resource "stopped" and no watchdog action.
|
||||
CoroTest.__init__(self,cm)
|
||||
self.name="SamWdIntegration2"
|
||||
self.need_all_up = True
|
||||
self.config['logging/logger_subsys[1]/subsys'] = 'WD'
|
||||
self.config['logging/logger_subsys[1]/debug'] = 'on'
|
||||
self.config['logging/logger_subsys[2]/subsys'] = 'WD'
|
||||
self.config['logging/logger_subsys[2]/debug'] = 'on'
|
||||
|
||||
def __call__(self, node):
|
||||
'''Perform the test. '''
|
||||
@ -1230,10 +1231,10 @@ check that we do NOT get watchdog'ed
|
||||
CoroTest.__init__(self,cm)
|
||||
self.name="WdDeleteResource"
|
||||
self.need_all_up = True
|
||||
self.config['logging/logger_subsys[1]/subsys'] = 'WD'
|
||||
self.config['logging/logger_subsys[1]/debug'] = 'on'
|
||||
self.config['logging/logger_subsys[2]/subsys'] = 'MON'
|
||||
self.config['logging/logger_subsys[2]/debug'] = 'on'
|
||||
self.config['logging/logger_subsys[3]/subsys'] = 'WD'
|
||||
self.config['logging/logger_subsys[3]/debug'] = 'on'
|
||||
self.config['resources/system/memory_used/recovery'] = 'watchdog'
|
||||
self.config['resources/system/memory_used/max'] = '80'
|
||||
self.config['resources/system/memory_used/poll_period'] = '800'
|
||||
@ -1275,10 +1276,10 @@ check that we do NOT get watchdog'ed
|
||||
CoroTest.__init__(self,cm)
|
||||
self.name="ResourcePollAdjust"
|
||||
self.need_all_up = True
|
||||
self.config['logging/logger_subsys[1]/subsys'] = 'WD'
|
||||
self.config['logging/logger_subsys[1]/debug'] = 'on'
|
||||
self.config['logging/logger_subsys[2]/subsys'] = 'MON'
|
||||
self.config['logging/logger_subsys[2]/debug'] = 'on'
|
||||
self.config['logging/logger_subsys[3]/subsys'] = 'WD'
|
||||
self.config['logging/logger_subsys[3]/debug'] = 'on'
|
||||
self.config['resources/system/memory_used/recovery'] = 'none'
|
||||
self.config['resources/system/memory_used/max'] = '80'
|
||||
self.config['resources/system/memory_used/poll_period'] = '800'
|
||||
@ -1322,8 +1323,8 @@ confirm reboot action
|
||||
CoroTest.__init__(self,cm)
|
||||
self.name="RebootOnHighMem"
|
||||
self.need_all_up = True
|
||||
self.config['logging/logger_subsys[1]/subsys'] = 'WD'
|
||||
self.config['logging/logger_subsys[1]/debug'] = 'on'
|
||||
self.config['logging/logger_subsys[2]/subsys'] = 'WD'
|
||||
self.config['logging/logger_subsys[2]/debug'] = 'on'
|
||||
self.config['resources/system/memory_used/recovery'] = 'reboot'
|
||||
self.config['resources/system/memory_used/max'] = '80'
|
||||
self.config['resources/system/memory_used/poll_period'] = '800'
|
||||
|
@ -353,6 +353,9 @@ static void member_object_joined (unsigned int nodeid)
|
||||
icmap_set_uint32(member_join_count, 1);
|
||||
icmap_set_string(member_status, "joined");
|
||||
}
|
||||
|
||||
log_printf (LOGSYS_LEVEL_DEBUG,
|
||||
"Member joined: %s", api->totem_ifaces_print (nodeid));
|
||||
}
|
||||
|
||||
static void member_object_left (unsigned int nodeid)
|
||||
@ -362,6 +365,9 @@ static void member_object_left (unsigned int nodeid)
|
||||
snprintf(member_status, ICMAP_KEYNAME_MAXLEN,
|
||||
"runtime.totem.pg.mrp.srp.members.%u.status", nodeid);
|
||||
icmap_set_string(member_status, "left");
|
||||
|
||||
log_printf (LOGSYS_LEVEL_DEBUG,
|
||||
"Member left: %s", api->totem_ifaces_print (nodeid));
|
||||
}
|
||||
|
||||
static void confchg_fn (
|
||||
|
Loading…
Reference in New Issue
Block a user