 |
pacemaker
2.0.1-9e909a5bdd
Scalable High-Availability cluster resource manager
|
Go to the documentation of this file.
10 #include <sys/param.h>
36 if (data_set != NULL) {
50 if (data_set != NULL) {
82 if (data_set->
input == NULL) {
86 if (data_set->
now == NULL) {
90 if (data_set->
dc_uuid == NULL) {
108 crm_warn(
"Fencing and resource management disabled due to lack of quorum");
140 pe_free_resources(
GListPtr resources)
145 while (iterator != NULL) {
147 iterator = iterator->next;
150 if (resources != NULL) {
151 g_list_free(resources);
160 while (iterator != NULL) {
162 iterator = iterator->next;
164 if (actions != NULL) {
165 g_list_free(actions);
172 for (GList *iterator = nodes; iterator != NULL; iterator = iterator->next) {
210 pe__free_ordering(
GListPtr constraints)
214 while (iterator != NULL) {
217 iterator = iterator->next;
223 if (constraints != NULL) {
224 g_list_free(constraints);
229 pe__free_location(
GListPtr constraints)
233 while (iterator != NULL) {
236 iterator = iterator->next;
242 if (constraints != NULL) {
243 g_list_free(constraints);
258 if (data_set == NULL) {
272 g_hash_table_destroy(data_set->
tickets);
279 if (data_set->
tags) {
280 g_hash_table_destroy(data_set->
tags);
289 pe_free_actions(data_set->
actions);
292 pe_free_nodes(data_set->
nodes);
317 if (data_set == NULL) {
321 crm_trace(
"Deleting %d ordering constraints",
326 crm_trace(
"Deleting %d location constraints",
331 crm_trace(
"Deleting %d colocation constraints",
336 crm_trace(
"Deleting %d ticket constraints",
353 data_set->
flags = 0x0ULL;
370 for (rIter = rsc_list;
id && rIter; rIter = rIter->next) {
400 for (; gIter != NULL; gIter = gIter->next) {
416 for (; gIter != NULL; gIter = gIter->next) {
#define pe_flag_symmetric_cluster
node_t * pe_find_node_any(GListPtr nodes, const char *id, const char *uname)
#define pe_flag_quick_location
#define pe_flag_have_quorum
gboolean unpack_remote_nodes(xmlNode *xml_resources, pe_working_set_t *data_set)
gboolean unpack_tags(xmlNode *xml_tags, pe_working_set_t *data_set)
xmlNode * create_xml_node(xmlNode *parent, const char *name)
xmlNode * get_xpath_object(const char *xpath, xmlNode *xml_obj, int error_level)
#define XML_CIB_TAG_OPCONFIG
#define CRM_CHECK(expr, failure_action)
#define clear_bit(word, bit)
GHashTable * digest_cache
cache of calculated resource digests
struct pe_node_shared_s * details
void pe_free_working_set(pe_working_set_t *data_set)
Free a working set.
node_t * pe_find_node_id(GListPtr nodes, const char *id)
#define crm_trace(fmt, args...)
#define safe_str_eq(a, b)
#define XML_CIB_TAG_RESOURCES
#define crm_warn(fmt, args...)
void free_xml(xmlNode *child)
#define XML_CIB_TAG_RSCCONFIG
Wrappers for and extensions to libxml2.
node_t * pe_find_node(GListPtr nodes, const char *uname)
resource_t * pe_find_resource(GListPtr rsc_list, const char *id)
gboolean crm_is_true(const char *s)
#define XML_CIB_TAG_STATUS
#define set_bit(word, bit)
void(* free)(pe_resource_t *)
gboolean is_remote_node(node_t *node)
#define XML_CIB_TAG_NODES
@ pe_find_renamed
match resource ID or LRM history ID
gboolean cluster_status(pe_working_set_t *data_set)
void set_working_set_defaults(pe_working_set_t *data_set)
GListPtr colocation_constraints
gboolean unpack_nodes(xmlNode *xml_nodes, pe_working_set_t *data_set)
#define pe_flag_stop_rsc_orphans
GListPtr ordering_constraints
const char * crm_element_value(const xmlNode *data, const char *name)
Retrieve the value of an XML attribute.
void pe_reset_working_set(pe_working_set_t *data_set)
Reset a working set to default state without freeing it.
gboolean unpack_config(xmlNode *config, pe_working_set_t *data_set)
GHashTable * template_rsc_sets
pe_working_set_t * pe_new_working_set()
Create a new working set.
GListPtr placement_constraints
#define XML_CIB_TAG_CRMCONFIG
gboolean unpack_status(xmlNode *status, pe_working_set_t *data_set)
#define pe_flag_stop_action_orphans
gboolean unpack_resources(xmlNode *xml_resources, pe_working_set_t *data_set)
void pe__free_param_checks(pe_working_set_t *data_set)
pe_find
Determine behavior of pe_find_resource_with_flags()
char * crm_element_value_copy(const xmlNode *data, const char *name)
Retrieve a copy of the value of an XML attribute.
GListPtr ticket_constraints
resource_t * pe_find_resource_with_flags(GListPtr rsc_list, const char *id, enum pe_find flags)
crm_time_t * crm_time_new(const char *string)
void crm_time_free(crm_time_t *dt)
enum pe_quorum_policy no_quorum_policy
void pe_free_action(action_t *action)
pe_resource_t *(* find_rsc)(pe_resource_t *parent, const char *search, const pe_node_t *node, int flags)
#define pe_flag_have_status
resource_object_functions_t * fns
void cleanup_calculations(pe_working_set_t *data_set)
Reset working set to default state without freeing it or constraints.
#define XML_ATTR_HAVE_QUORUM