CRM_DEBUG("CIB Erase op in progress");
CRM_NOTE("CIB Erase op in progress");
do_work(ll_cluster_t * hb_cluster){	/* construct the request */	xmlNodePtr msg_data = NULL;	const char *dest_node = NULL;	gboolean all_is_good = TRUE;	char *obj_type_parent = NULL;	const char *ping_type = NULL;		msg_options = create_xml_node(NULL, XML_TAG_OPTIONS);	set_xml_property_copy(msg_options, XML_ATTR_VERBOSE, verbose);	set_xml_property_copy(msg_options, XML_ATTR_TIMEOUT, "0");	if (DO_DAEMON == TRUE && cib_action != NULL) {		if(strcmp(CRM_OP_QUERY, cib_action) == 0) {			cl_log(LOG_DEBUG, "Querying the CIB");			obj_type_parent = pluralSection(obj_type);						CRM_DEBUG("Querying the CIB for section: %s",				   obj_type_parent);						set_xml_property_copy(msg_options, XML_ATTR_OP, CRM_OP_QUERY);			set_xml_property_copy(msg_options, XML_ATTR_FILTER_ID,					      obj_type_parent);						dest_node = status;			CRM_DEBUG("CIB query creation %s",				   msg_data == NULL ? "failed." : "passed.");						sys_to = CRM_SYSTEM_DCIB;					} else if (strcmp(CRM_OP_ERASE, cib_action) == 0) {			set_xml_property_copy(msg_options,					      XML_ATTR_OP,					      CRM_OP_ERASE);						dest_node = status;			CRM_DEBUG("CIB Erase op in progress");						sys_to = CRM_SYSTEM_DCIB;		} else {			cl_log(LOG_ERR, "Unknown daemon options");			all_is_good = FALSE;		}			} else if(cib_action != NULL) {			msg_data = handleCibMod();			sys_to = CRM_SYSTEM_DCIB;			if(msg_data == NULL)				all_is_good = FALSE;			} else if (DO_DAEMON == TRUE && DO_HEALTH == TRUE) {		CRM_DEBUG("Querying the system");		sys_to = CRM_SYSTEM_DC;		if (status != NULL) {			sys_to = CRM_SYSTEM_CRMD;			ping_type = CRM_OP_PING;			if (BE_VERBOSE) {				ping_type = "ping_deep";				if (status != NULL)					expected_responses = 2;	// 5; // CRM/DC, LRMD, CIB, PENGINE, TENGINE				else					expected_responses = -1;// wait until timeout instead			}			set_xml_property_copy(msg_options,					      XML_ATTR_OP,					      ping_type);						set_xml_property_copy(msg_options,					      XML_ATTR_TIMEOUT,					      "0");			dest_node = status;		} else {			cl_log(LOG_INFO, "Cluster-wide health not available yet");			all_is_good = FALSE;		}	} else {		cl_log(LOG_ERR, "Unknown options");		all_is_good = FALSE;	}		if(all_is_good == FALSE) {		cl_log(LOG_ERR, "Creation of request failed.  No message to send");		return -1;	}/* send it */	if (crmd_channel == NULL) {		cl_log(LOG_ERR,		       "The IPC connection is not valid, cannot send anything");		return -1;	}	if(sys_to == NULL) {		if (dest_node != NULL)			sys_to = CRM_SYSTEM_CRMD;		else			sys_to = CRM_SYSTEM_DC;					}			send_ipc_request(crmd_channel,			 msg_options,			 msg_data,			 dest_node, sys_to,			 crm_system_name,			 admin_uuid,			 this_msg_reference);	return 1;}