4
0
Эх сурвалжийг харах

CTS: log cfg results

Reviewed-by: Steven Dake <sdake@redhat.com>
Signed-off-by: Angus Salkeld <asalkeld@redhat.com>
Angus Salkeld 15 жил өмнө
parent
commit
e50353b8f6

+ 8 - 3
cts/agents/cpg_test_agent.c

@@ -713,7 +713,9 @@ static void do_command (int sock, char* func, char*args[], int num_args)
 
 
 	} else if (strcmp ("cfg_shutdown", func) == 0) {
 	} else if (strcmp ("cfg_shutdown", func) == 0) {
 
 
-		corosync_cfg_try_shutdown (cfg_handle, COROSYNC_CFG_SHUTDOWN_FLAG_REQUEST);
+		syslog (LOG_INFO,"%s calling %s() called!", __func__, func);
+		result = corosync_cfg_try_shutdown (cfg_handle, COROSYNC_CFG_SHUTDOWN_FLAG_REQUEST);
+		syslog (LOG_INFO,"%s() returned %d!", func, result);
 
 
 	} else if (strcmp ("cfg_initialize",func) == 0) {
 	} else if (strcmp ("cfg_initialize",func) == 0) {
 		int retry_count = 0;
 		int retry_count = 0;
@@ -731,10 +733,13 @@ static void do_command (int sock, char* func, char*args[], int num_args)
 			retry_count++;
 			retry_count++;
 			result = corosync_cfg_initialize (&cfg_handle, &cfg_callbacks);
 			result = corosync_cfg_initialize (&cfg_handle, &cfg_callbacks);
 		}
 		}
+		syslog (LOG_INFO,"corosync_cfg_initialize() == %d", result);
 
 
-		corosync_cfg_fd_get (cfg_handle, &cfg_fd);
+		result = corosync_cfg_fd_get (cfg_handle, &cfg_fd);
+		syslog (LOG_INFO,"corosync_cfg_fd_get() == %d", result);
 
 
-		corosync_cfg_state_track (cfg_handle, 0, &notification_buffer);
+		result = corosync_cfg_state_track (cfg_handle, 0, &notification_buffer);
+		syslog (LOG_INFO,"corosync_cfg_state_track() == %d", result);
 
 
 		qb_loop_poll_add (ta_poll_handle_get(),
 		qb_loop_poll_add (ta_poll_handle_get(),
 				  QB_LOOP_MED,
 				  QB_LOOP_MED,

+ 7 - 0
cts/corotests.py

@@ -1110,6 +1110,9 @@ class GenStopAllBeekhof(CoroTest):
         CoroTest.__init__(self,cm)
         CoroTest.__init__(self,cm)
         self.name="GenStopAllBeekhof"
         self.name="GenStopAllBeekhof"
         self.need_all_up = True
         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'
 
 
     def __call__(self, node):
     def __call__(self, node):
         '''Perform the 'GenStopAllBeekhof' test. '''
         '''Perform the 'GenStopAllBeekhof' test. '''
@@ -1118,7 +1121,11 @@ class GenStopAllBeekhof(CoroTest):
         stopping = int(time.time())
         stopping = int(time.time())
         for n in self.CM.Env["nodes"]:
         for n in self.CM.Env["nodes"]:
             self.CM.cpg_agent[n].pcmk_test()
             self.CM.cpg_agent[n].pcmk_test()
+
+        for n in self.CM.Env["nodes"]:
             self.CM.cpg_agent[n].msg_blaster(10000)
             self.CM.cpg_agent[n].msg_blaster(10000)
+
+        for n in self.CM.Env["nodes"]:
             self.CM.cpg_agent[n].cfg_shutdown()
             self.CM.cpg_agent[n].cfg_shutdown()
             self.CM.ShouldBeStatus[n] = "down"
             self.CM.ShouldBeStatus[n] = "down"