rsc 434 daemons/attrd/attrd_corosync.c const char *rsc = crm_element_value(xml, PCMK__XA_ATTR_RESOURCE); rsc 449 daemons/attrd/attrd_corosync.c if (attrd_failure_regex(®ex, rsc, op, interval_ms) != pcmk_ok) { rsc 451 daemons/attrd/attrd_corosync.c pcmk__s(rsc, "all resources")); rsc 464 daemons/attrd/attrd_corosync.c attr, pcmk__s(rsc, "all resources")); rsc 91 daemons/attrd/attrd_ipc.c const char *rsc, *op, *interval_spec; rsc 102 daemons/attrd/attrd_ipc.c rsc = crm_element_value(xml, PCMK__XA_ATTR_RESOURCE); rsc 111 daemons/attrd/attrd_ipc.c if (rsc) { rsc 115 daemons/attrd/attrd_ipc.c pattern = crm_strdup_printf(ATTRD_RE_CLEAR_ONE, rsc); rsc 122 daemons/attrd/attrd_ipc.c rsc, op, interval_ms); rsc 199 daemons/attrd/attrd_utils.c attrd_failure_regex(regex_t *regex, const char *rsc, const char *op, rsc 207 daemons/attrd/attrd_utils.c if (rsc == NULL) { rsc 210 daemons/attrd/attrd_utils.c pattern = crm_strdup_printf(ATTRD_RE_CLEAR_ONE, rsc); rsc 212 daemons/attrd/attrd_utils.c pattern = crm_strdup_printf(ATTRD_RE_CLEAR_OP, rsc, op, interval_ms); rsc 94 daemons/attrd/pacemaker-attrd.h int attrd_failure_regex(regex_t *regex, const char *rsc, const char *op, rsc 130 daemons/controld/controld_attrd.c update_attrd_clear_failures(const char *host, const char *rsc, const char *op, rsc 144 daemons/controld/controld_attrd.c rc = pcmk__attrd_api_clear_failures(attrd_api, host, rsc, op, rsc 155 daemons/controld/controld_attrd.c pcmk__s(rsc, "all resources"), node_type(is_remote_node), host, rsc 658 daemons/controld/controld_cib.c const lrmd_rsc_info_t *rsc, rsc 683 daemons/controld/controld_cib.c if ((rsc == NULL) || (op->params == NULL) rsc 684 daemons/controld/controld_cib.c || !crm_op_needs_metadata(rsc->standard, op->op_type)) { rsc 687 daemons/controld/controld_cib.c op->op_type, op->rsc_id, op->params, rsc); rsc 704 daemons/controld/controld_cib.c metadata = controld_get_rsc_metadata(lrm_state, rsc, rsc 712 daemons/controld/controld_cib.c rsc->standard, rsc->provider, rsc->type); rsc 730 daemons/controld/controld_cib.c controld_record_pending_op(const char *node_name, const lrmd_rsc_info_t *rsc, rsc 735 daemons/controld/controld_cib.c CRM_CHECK((node_name != NULL) && (rsc != NULL) && (op != NULL), rsc 760 daemons/controld/controld_cib.c controld_update_resource_history(node_name, rsc, op, 0); rsc 875 daemons/controld/controld_cib.c const lrmd_rsc_info_t *rsc, rsc 886 daemons/controld/controld_cib.c if (rsc == NULL) { rsc 888 daemons/controld/controld_cib.c controld_ack_event_directly(NULL, NULL, rsc, op, op->rsc_id); rsc 918 daemons/controld/controld_cib.c crm_xml_add(xml, PCMK_XA_CLASS, rsc->standard); rsc 919 daemons/controld/controld_cib.c crm_xml_add(xml, PCMK_XA_PROVIDER, rsc->provider); rsc 920 daemons/controld/controld_cib.c crm_xml_add(xml, PCMK_XA_TYPE, rsc->type); rsc 941 daemons/controld/controld_cib.c controld_add_resource_history_xml(xml, rsc, op, node_name); rsc 80 daemons/controld/controld_cib.h const lrmd_rsc_info_t *rsc, rsc 84 daemons/controld/controld_cib.h #define controld_add_resource_history_xml(parent, rsc, op, node_name) \ rsc 85 daemons/controld/controld_cib.h controld_add_resource_history_xml_as(__func__, (parent), (rsc), \ rsc 89 daemons/controld/controld_cib.h const lrmd_rsc_info_t *rsc, rsc 93 daemons/controld/controld_cib.h const lrmd_rsc_info_t *rsc, rsc 32 daemons/controld/controld_execd.c const char *rsc; rsc 44 daemons/controld/controld_execd.c static void do_lrm_rsc_op(lrm_state_t *lrm_state, lrmd_rsc_info_t *rsc, rsc 61 daemons/controld/controld_execd.c make_stop_id(const char *rsc, int call_id) rsc 63 daemons/controld/controld_execd.c return crm_strdup_printf("%s:%d", rsc, call_id); rsc 145 daemons/controld/controld_execd.c free(history->rsc.type); rsc 146 daemons/controld/controld_execd.c free(history->rsc.standard); rsc 147 daemons/controld/controld_execd.c free(history->rsc.provider); rsc 157 daemons/controld/controld_execd.c update_history_cache(lrm_state_t * lrm_state, lrmd_rsc_info_t * rsc, lrmd_event_data_t * op) rsc 176 daemons/controld/controld_execd.c if (entry == NULL && rsc) { rsc 181 daemons/controld/controld_execd.c entry->rsc.id = entry->id; rsc 182 daemons/controld/controld_execd.c entry->rsc.type = pcmk__str_copy(rsc->type); rsc 183 daemons/controld/controld_execd.c entry->rsc.standard = pcmk__str_copy(rsc->standard); rsc 184 daemons/controld/controld_execd.c entry->rsc.provider = pcmk__str_copy(rsc->provider); rsc 265 daemons/controld/controld_execd.c const char *rsc_id, const lrmd_rsc_info_t *rsc, rsc 271 daemons/controld/controld_execd.c controld_ack_event_directly(ack_host, ack_sys, rsc, op, rsc_id); rsc 544 daemons/controld/controld_execd.c crm_xml_add(xml_rsc, PCMK_XA_TYPE, entry->rsc.type); rsc 545 daemons/controld/controld_execd.c crm_xml_add(xml_rsc, PCMK_XA_CLASS, entry->rsc.standard); rsc 546 daemons/controld/controld_execd.c crm_xml_add(xml_rsc, PCMK_XA_PROVIDER, entry->rsc.provider); rsc 558 daemons/controld/controld_execd.c controld_add_resource_history_xml(xml_rsc, &(entry->rsc), entry->failed, rsc 560 daemons/controld/controld_execd.c controld_add_resource_history_xml(xml_rsc, &(entry->rsc), entry->last, rsc 563 daemons/controld/controld_execd.c controld_add_resource_history_xml(xml_rsc, &(entry->rsc), gIter->data, rsc 685 daemons/controld/controld_execd.c if (pcmk__str_eq(event->rsc, op->rsc, pcmk__str_none)) { rsc 686 daemons/controld/controld_execd.c notify_deleted(event->lrm_state, op->input, event->rsc, event->rc); rsc 695 daemons/controld/controld_execd.c const char *rsc = user_data; rsc 698 daemons/controld/controld_execd.c if (pcmk__str_eq(rsc, pending->rsc_id, pcmk__str_none)) { rsc 700 daemons/controld/controld_execd.c pending->op_key, pending->call_id, rsc); rsc 738 daemons/controld/controld_execd.c event.rsc = rsc_id; rsc 851 daemons/controld/controld_execd.c lrmd_rsc_info_t *rsc; rsc 864 daemons/controld/controld_execd.c remove = !cancel_op(data->lrm_state, data->rsc->id, key, op->call_id, data->remove); rsc 870 daemons/controld/controld_execd.c cancel_op_key(lrm_state_t * lrm_state, lrmd_rsc_info_t * rsc, const char *key, gboolean remove) rsc 875 daemons/controld/controld_execd.c CRM_CHECK(rsc != NULL, return FALSE); rsc 879 daemons/controld/controld_execd.c data.rsc = rsc; rsc 965 daemons/controld/controld_execd.c delete_resource(lrm_state_t *lrm_state, const char *id, lrmd_rsc_info_t *rsc, rsc 974 daemons/controld/controld_execd.c if (rsc && unregister) { rsc 987 daemons/controld/controld_execd.c op->rsc = pcmk__str_copy(rsc->id); rsc 1070 daemons/controld/controld_execd.c delete_resource(lrm_state, entry->id, &entry->rsc, &gIter, from_sys, rsc 1166 daemons/controld/controld_execd.c lrmd_rsc_info_t *rsc = NULL; rsc 1198 daemons/controld/controld_execd.c if (get_lrm_resource(lrm_state, xml_rsc, TRUE, &rsc) == pcmk_ok) { rsc 1199 daemons/controld/controld_execd.c crm_info("Failing resource %s...", rsc->id); rsc 1204 daemons/controld/controld_execd.c lrmd_free_rsc_info(rsc); rsc 1243 daemons/controld/controld_execd.c lrmd_rsc_info_t *rsc, const char *from_host, const char *from_sys) rsc 1269 daemons/controld/controld_execd.c op_key = pcmk__op_key(rsc->id, op_task, interval_ms); rsc 1280 daemons/controld/controld_execd.c in_progress = cancel_op_key(lrm_state, rsc, op_key, TRUE); rsc 1284 daemons/controld/controld_execd.c in_progress = cancel_op(lrm_state, rsc->id, NULL, call, TRUE); rsc 1288 daemons/controld/controld_execd.c if (!in_progress || is_remote_lrmd_ra(NULL, NULL, rsc->id)) { rsc 1289 daemons/controld/controld_execd.c char *op_id = make_stop_id(rsc->id, call); rsc 1291 daemons/controld/controld_execd.c if (is_remote_lrmd_ra(NULL, NULL, rsc->id) == FALSE) { rsc 1294 daemons/controld/controld_execd.c controld_delete_action_history_by_key(rsc->id, lrm_state->node_name, rsc 1296 daemons/controld/controld_execd.c send_task_ok_ack(lrm_state, input, rsc->id, rsc, op_task, rsc 1319 daemons/controld/controld_execd.c send_task_ok_ack(lrm_state, input, rsc->id, rsc, op_task, rsc 1330 daemons/controld/controld_execd.c lrmd_rsc_info_t *rsc, const char *from_sys, const char *from_host, rsc 1334 daemons/controld/controld_execd.c int cib_rc = controld_delete_resource_history(rsc->id, lrm_state->node_name, rsc 1341 daemons/controld/controld_execd.c op = construct_op(lrm_state, input->xml, rsc->id, PCMK_ACTION_DELETE); rsc 1347 daemons/controld/controld_execd.c controld_ack_event_directly(from_host, from_sys, NULL, op, rsc->id); rsc 1352 daemons/controld/controld_execd.c if (crm_rsc_delete && is_remote_lrmd_ra(NULL, NULL, rsc->id)) { rsc 1356 daemons/controld/controld_execd.c delete_resource(lrm_state, rsc->id, rsc, NULL, from_sys, rsc 1362 daemons/controld/controld_execd.c lrmd_rsc_info_t *rsc; // Copy of resource information rsc 1367 daemons/controld/controld_execd.c new_metadata_cb_data(lrmd_rsc_info_t *rsc, xmlNode *input_xml) rsc 1373 daemons/controld/controld_execd.c data->rsc = lrmd_copy_rsc_info(rsc); rsc 1380 daemons/controld/controld_execd.c lrmd_free_rsc_info(data->rsc); rsc 1402 daemons/controld/controld_execd.c md = controld_cache_metadata(lrm_state->metadata_cache, data->rsc, rsc 1406 daemons/controld/controld_execd.c do_lrm_rsc_op(lrm_state, data->rsc, data->input_xml, md); rsc 1497 daemons/controld/controld_execd.c lrmd_rsc_info_t *rsc = NULL; rsc 1507 daemons/controld/controld_execd.c rc = get_lrm_resource(lrm_state, xml_rsc, create_rsc, &rsc); rsc 1549 daemons/controld/controld_execd.c if (!do_lrm_cancel(input, lrm_state, rsc, from_host, from_sys)) { rsc 1555 daemons/controld/controld_execd.c do_lrm_delete(input, lrm_state, rsc, from_sys, from_host, rsc 1570 daemons/controld/controld_execd.c md = controld_get_rsc_metadata(lrm_state, rsc, rsc 1574 daemons/controld/controld_execd.c if ((md == NULL) && crm_op_needs_metadata(rsc->standard, rsc 1589 daemons/controld/controld_execd.c data = new_metadata_cb_data(rsc, input->xml); rsc 1591 daemons/controld/controld_execd.c rsc->id, rsc->standard, rsc 1592 daemons/controld/controld_execd.c ((rsc->provider == NULL)? "" : ":"), rsc 1593 daemons/controld/controld_execd.c ((rsc->provider == NULL)? "" : rsc->provider), rsc 1594 daemons/controld/controld_execd.c rsc->type); rsc 1595 daemons/controld/controld_execd.c (void) lrmd__metadata_async(rsc, metadata_complete, rsc 1598 daemons/controld/controld_execd.c do_lrm_rsc_op(lrm_state, rsc, input->xml, md); rsc 1602 daemons/controld/controld_execd.c lrmd_free_rsc_info(rsc); rsc 1750 daemons/controld/controld_execd.c const lrmd_rsc_info_t *rsc, lrmd_event_data_t *op, rsc 1779 daemons/controld/controld_execd.c controld_add_resource_history_xml(iter, rsc, op, rsc 1819 daemons/controld/controld_execd.c lrmd_rsc_info_t *rsc; rsc 1831 daemons/controld/controld_execd.c && pcmk__str_eq(op->rsc_id, event->rsc->id, pcmk__str_none)) { rsc 1834 daemons/controld/controld_execd.c remove = !cancel_op(event->lrm_state, event->rsc->id, key, op->call_id, FALSE); rsc 1918 daemons/controld/controld_execd.c do_lrm_rsc_op(lrm_state_t *lrm_state, lrmd_rsc_info_t *rsc, xmlNode *msg, rsc 1930 daemons/controld/controld_execd.c CRM_CHECK((rsc != NULL) && (msg != NULL), return); rsc 1944 daemons/controld/controld_execd.c operation, rsc->id, pcmk__s(transition, "")); rsc 1966 daemons/controld/controld_execd.c op = construct_op(lrm_state, msg, rsc->id, operation); rsc 1969 daemons/controld/controld_execd.c if (should_cancel_recurring(rsc->id, operation, op->interval_ms)) { rsc 1973 daemons/controld/controld_execd.c data.rsc = rsc; rsc 1982 daemons/controld/controld_execd.c rsc->id, operation, op->interval_ms); rsc 1989 daemons/controld/controld_execd.c pcmk__readable_action(op->op_type, op->interval_ms), rsc->id, rsc 1990 daemons/controld/controld_execd.c lrm_state->node_name, pcmk__s(transition, ""), rsc->id, rsc 1996 daemons/controld/controld_execd.c "(shutdown=%s)", operation, rsc->id, rsc 2003 daemons/controld/controld_execd.c controld_ack_event_directly(NULL, NULL, rsc, op, rsc->id); rsc 2009 daemons/controld/controld_execd.c controld_record_pending_op(lrm_state->node_name, rsc, op); rsc 2011 daemons/controld/controld_execd.c op_id = pcmk__op_key(rsc->id, op->op_type, op->interval_ms); rsc 2015 daemons/controld/controld_execd.c cancel_op_key(lrm_state, rsc, op_id, FALSE); rsc 2018 daemons/controld/controld_execd.c rc = controld_execute_resource_agent(lrm_state, rsc->id, op->op_type, rsc 2026 daemons/controld/controld_execd.c char *call_id_s = make_stop_id(rsc->id, call_id); rsc 2036 daemons/controld/controld_execd.c pending->rsc_id = pcmk__str_copy(rsc->id); rsc 2052 daemons/controld/controld_execd.c controld_ack_event_directly(NULL, NULL, rsc, op, rsc->id); rsc 2060 daemons/controld/controld_execd.c CRM_XS " rc=%d", operation, rsc->id, pcmk_rc_str(rc), rc); rsc 2069 daemons/controld/controld_execd.c operation, rsc->id, lrm_state->node_name, pcmk_rc_str(rc), rc); rsc 2235 daemons/controld/controld_execd.c lrmd_rsc_info_t *rsc = NULL; rsc 2262 daemons/controld/controld_execd.c rsc = lrm_state_get_rsc_info(lrm_state, op->rsc_id, 0); rsc 2264 daemons/controld/controld_execd.c if ((rsc == NULL) && action_xml) { rsc 2276 daemons/controld/controld_execd.c rsc = lrmd_new_rsc_info(op->rsc_id, standard, provider, type); rsc 2320 daemons/controld/controld_execd.c if (node_name && rsc) { rsc 2324 daemons/controld/controld_execd.c controld_update_resource_history(node_name, rsc, op, lock_time); rsc 2428 daemons/controld/controld_execd.c } else if (rsc && (op->rc == PCMK_OCF_OK)) { rsc 2431 daemons/controld/controld_execd.c controld_cache_metadata(lrm_state->metadata_cache, rsc, metadata); rsc 2448 daemons/controld/controld_execd.c if (lrm_state && rsc) { rsc 2449 daemons/controld/controld_execd.c update_history_cache(lrm_state, rsc, op); rsc 2452 daemons/controld/controld_execd.c lrmd_free_rsc_info(rsc); rsc 42 daemons/controld/controld_execd_state.c free(op->rsc); rsc 692 daemons/controld/controld_execd_state.c lrmd_rsc_info_t *rsc = NULL; rsc 701 daemons/controld/controld_execd_state.c rsc = g_hash_table_lookup(lrm_state->rsc_info_cache, rsc_id); rsc 702 daemons/controld/controld_execd_state.c if (rsc == NULL) { rsc 704 daemons/controld/controld_execd_state.c rsc = ((lrmd_t *) lrm_state->conn)->cmds->get_rsc_info(lrm_state->conn, rsc_id, options); rsc 705 daemons/controld/controld_execd_state.c if (rsc == NULL) { rsc 709 daemons/controld/controld_execd_state.c g_hash_table_insert(lrm_state->rsc_info_cache, rsc->id, rsc); rsc 712 daemons/controld/controld_execd_state.c return lrmd_copy_rsc_info(rsc); rsc 23 daemons/controld/controld_lrm.h lrmd_rsc_info_t rsc; rsc 83 daemons/controld/controld_lrm.h char *rsc; rsc 178 daemons/controld/controld_lrm.h const lrmd_rsc_info_t *rsc, rsc 639 daemons/controld/controld_messages.c const char *rsc = NULL; rsc 657 daemons/controld/controld_messages.c rsc = pcmk__xe_id(xml_rsc); rsc 669 daemons/controld/controld_messages.c if ((rsc == NULL) || (uname == NULL)) { rsc 680 daemons/controld/controld_messages.c pcmk__readable_interval(interval_ms), rsc, uname); rsc 685 daemons/controld/controld_messages.c update_attrd_clear_failures(uname, rsc, op, interval_spec, is_remote_node); rsc 688 daemons/controld/controld_messages.c controld_cib_delete_last_failure(rsc, uname, op, interval_ms); rsc 690 daemons/controld/controld_messages.c lrm_clear_last_failure(rsc, uname, op, interval_ms); rsc 116 daemons/controld/controld_metadata.c controld_cache_metadata(GHashTable *mdc, const lrmd_rsc_info_t *rsc, rsc 127 daemons/controld/controld_metadata.c CRM_CHECK(mdc && rsc && metadata_str, return NULL); rsc 129 daemons/controld/controld_metadata.c key = crm_generate_ra_key(rsc->standard, rsc->provider, rsc->type); rsc 143 daemons/controld/controld_metadata.c if (strcmp(rsc->standard, PCMK_RESOURCE_CLASS_OCF) == 0) { rsc 190 daemons/controld/controld_metadata.c PCMK_XA_NAME, rsc->standard, rsc->provider, rsc->type); rsc 227 daemons/controld/controld_metadata.c rsc->id, rsc->standard, ((rsc->provider == NULL)? "" : ":"), rsc 228 daemons/controld/controld_metadata.c pcmk__s(rsc->provider, ""), rsc->type, reason); rsc 247 daemons/controld/controld_metadata.c controld_get_rsc_metadata(lrm_state_t *lrm_state, const lrmd_rsc_info_t *rsc, rsc 255 daemons/controld/controld_metadata.c CRM_CHECK((lrm_state != NULL) && (rsc != NULL), return NULL); rsc 258 daemons/controld/controld_metadata.c key = crm_generate_ra_key(rsc->standard, rsc->provider, rsc->type); rsc 265 daemons/controld/controld_metadata.c rsc->id, rsc->standard, rsc 266 daemons/controld/controld_metadata.c ((rsc->provider == NULL)? "" : ":"), rsc 267 daemons/controld/controld_metadata.c ((rsc->provider == NULL)? "" : rsc->provider), rsc 268 daemons/controld/controld_metadata.c rsc->type); rsc 292 daemons/controld/controld_metadata.c rsc->id, rsc->standard, rsc 293 daemons/controld/controld_metadata.c ((rsc->provider == NULL)? "" : ":"), rsc 294 daemons/controld/controld_metadata.c ((rsc->provider == NULL)? "" : rsc->provider), rsc 295 daemons/controld/controld_metadata.c rsc->type); rsc 296 daemons/controld/controld_metadata.c rc = lrm_state_get_metadata(lrm_state, rsc->standard, rsc->provider, rsc 297 daemons/controld/controld_metadata.c rsc->type, &metadata_str, 0); rsc 300 daemons/controld/controld_metadata.c rsc->id, rsc->standard, rsc 301 daemons/controld/controld_metadata.c ((rsc->provider == NULL)? "" : ":"), rsc 302 daemons/controld/controld_metadata.c ((rsc->provider == NULL)? "" : rsc->provider), rsc 303 daemons/controld/controld_metadata.c rsc->type, pcmk_strerror(rc)); rsc 307 daemons/controld/controld_metadata.c metadata = controld_cache_metadata(lrm_state->metadata_cache, rsc, rsc 75 daemons/controld/controld_metadata.h const lrmd_rsc_info_t *rsc, rsc 78 daemons/controld/controld_metadata.h const lrmd_rsc_info_t *rsc, rsc 256 daemons/controld/controld_te_actions.c xmlNode *rsc = NULL; rsc 294 daemons/controld/controld_te_actions.c rsc = pcmk__xe_create(state, PCMK__XE_LRM); rsc 295 daemons/controld/controld_te_actions.c crm_xml_add(rsc, PCMK_XA_ID, target_uuid); rsc 297 daemons/controld/controld_te_actions.c rsc = pcmk__xe_create(rsc, PCMK__XE_LRM_RESOURCES); rsc 298 daemons/controld/controld_te_actions.c rsc = pcmk__xe_create(rsc, PCMK__XE_LRM_RESOURCE); rsc 299 daemons/controld/controld_te_actions.c crm_xml_add(rsc, PCMK_XA_ID, rsc_id); rsc 302 daemons/controld/controld_te_actions.c crm_copy_xml_element(action_rsc, rsc, PCMK_XA_TYPE); rsc 303 daemons/controld/controld_te_actions.c crm_copy_xml_element(action_rsc, rsc, PCMK_XA_CLASS); rsc 304 daemons/controld/controld_te_actions.c crm_copy_xml_element(action_rsc, rsc, PCMK_XA_PROVIDER); rsc 306 daemons/controld/controld_te_actions.c pcmk__create_history_xml(rsc, op, CRM_FEATURE_SET, target_rc, target, rsc 230 daemons/controld/controld_te_callbacks.c xmlNode *rsc = NULL; rsc 264 daemons/controld/controld_te_callbacks.c for (rsc = pcmk__xe_first_child(xml, NULL, NULL, NULL); rsc != NULL; rsc 265 daemons/controld/controld_te_callbacks.c rsc = pcmk__xe_next(rsc)) { rsc 266 daemons/controld/controld_te_callbacks.c crm_trace("Processing %s", pcmk__xe_id(rsc)); rsc 267 daemons/controld/controld_te_callbacks.c process_lrm_resource_diff(rsc, node); rsc 48 daemons/controld/controld_utils.h void update_attrd_clear_failures(const char *host, const char *rsc, rsc 448 daemons/execd/cts-exec-helper.c pcmk_resource_t *rsc = NULL; rsc 482 daemons/execd/cts-exec-helper.c rsc = pe_find_resource_with_flags(scheduler->resources, options.rsc_id, rsc 485 daemons/execd/cts-exec-helper.c if (rsc == NULL) { rsc 492 daemons/execd/cts-exec-helper.c params = pe_rsc_params(rsc, NULL, scheduler); rsc 503 daemons/execd/cts-exec-helper.c get_meta_attributes(meta, rsc, NULL, scheduler); rsc 100 daemons/execd/execd_commands.c static void cmd_finalize(lrmd_cmd_t * cmd, lrmd_rsc_t * rsc); rsc 102 daemons/execd/execd_commands.c static void cancel_all_recurring(lrmd_rsc_t * rsc, const char *client_id); rsc 265 daemons/execd/execd_commands.c normalize_action_name(lrmd_rsc_t * rsc, const char *action) rsc 268 daemons/execd/execd_commands.c pcmk_is_set(pcmk_get_ra_caps(rsc->class), pcmk_ra_cap_status)) { rsc 278 daemons/execd/execd_commands.c lrmd_rsc_t *rsc = NULL; rsc 280 daemons/execd/execd_commands.c rsc = pcmk__assert_alloc(1, sizeof(lrmd_rsc_t)); rsc 282 daemons/execd/execd_commands.c crm_element_value_int(msg, PCMK__XA_LRMD_CALLOPT, &rsc->call_opts); rsc 284 daemons/execd/execd_commands.c rsc->rsc_id = crm_element_value_copy(rsc_xml, PCMK__XA_LRMD_RSC_ID); rsc 285 daemons/execd/execd_commands.c rsc->class = crm_element_value_copy(rsc_xml, PCMK__XA_LRMD_CLASS); rsc 286 daemons/execd/execd_commands.c rsc->provider = crm_element_value_copy(rsc_xml, PCMK__XA_LRMD_PROVIDER); rsc 287 daemons/execd/execd_commands.c rsc->type = crm_element_value_copy(rsc_xml, PCMK__XA_LRMD_TYPE); rsc 288 daemons/execd/execd_commands.c rsc->work = mainloop_add_trigger(G_PRIORITY_HIGH, execute_resource_action, rsc 289 daemons/execd/execd_commands.c rsc); rsc 292 daemons/execd/execd_commands.c pcmk__set_result(&rsc->fence_probe_result, CRM_EX_ERROR, rsc 294 daemons/execd/execd_commands.c return rsc; rsc 375 daemons/execd/execd_commands.c lrmd_rsc_t *rsc; rsc 383 daemons/execd/execd_commands.c rsc = g_hash_table_lookup(rsc_list, cmd->rsc_id); rsc 385 daemons/execd/execd_commands.c pcmk__assert(rsc != NULL); rsc 388 daemons/execd/execd_commands.c rsc->recurring_ops = g_list_remove(rsc->recurring_ops, cmd); rsc 389 daemons/execd/execd_commands.c rsc->pending_ops = g_list_append(rsc->pending_ops, cmd); rsc 393 daemons/execd/execd_commands.c mainloop_set_trigger(rsc->work); rsc 412 daemons/execd/execd_commands.c lrmd_rsc_t *rsc = NULL; rsc 415 daemons/execd/execd_commands.c rsc = cmd->rsc_id ? g_hash_table_lookup(rsc_list, cmd->rsc_id) : NULL; rsc 417 daemons/execd/execd_commands.c if (rsc) { rsc 418 daemons/execd/execd_commands.c mainloop_set_trigger(rsc->work); rsc 445 daemons/execd/execd_commands.c merge_recurring_duplicate(lrmd_rsc_t * rsc, lrmd_cmd_t * cmd) rsc 455 daemons/execd/execd_commands.c dup = find_duplicate_action(rsc->pending_ops, cmd); rsc 458 daemons/execd/execd_commands.c dup = find_duplicate_action(rsc->recurring_ops, cmd); rsc 467 daemons/execd/execd_commands.c if (pcmk__str_eq(rsc->class, PCMK_RESOURCE_CLASS_STONITH, rsc 478 daemons/execd/execd_commands.c rsc->rsc_id, normalize_action_name(rsc, dup->action), rsc 495 daemons/execd/execd_commands.c if (pcmk__str_eq(rsc->class, PCMK_RESOURCE_CLASS_STONITH, rsc 500 daemons/execd/execd_commands.c services_action_kick(rsc->rsc_id, rsc 501 daemons/execd/execd_commands.c normalize_action_name(rsc, dup->action), rsc 509 daemons/execd/execd_commands.c schedule_lrmd_cmd(lrmd_rsc_t * rsc, lrmd_cmd_t * cmd) rsc 512 daemons/execd/execd_commands.c CRM_CHECK(rsc != NULL, return); rsc 514 daemons/execd/execd_commands.c crm_trace("Scheduling %s on %s", cmd->action, rsc->rsc_id); rsc 516 daemons/execd/execd_commands.c if (merge_recurring_duplicate(rsc, cmd)) { rsc 525 daemons/execd/execd_commands.c cancel_all_recurring(rsc, NULL); rsc 528 daemons/execd/execd_commands.c rsc->pending_ops = g_list_append(rsc->pending_ops, cmd); rsc 532 daemons/execd/execd_commands.c mainloop_set_trigger(rsc->work); rsc 729 daemons/execd/execd_commands.c cmd_finalize(lrmd_cmd_t * cmd, lrmd_rsc_t * rsc) rsc 732 daemons/execd/execd_commands.c rsc ? rsc->active : NULL, cmd); rsc 734 daemons/execd/execd_commands.c if (rsc && (rsc->active == cmd)) { rsc 735 daemons/execd/execd_commands.c rsc->active = NULL; rsc 736 daemons/execd/execd_commands.c mainloop_set_trigger(rsc->work); rsc 739 daemons/execd/execd_commands.c if (!rsc) { rsc 751 daemons/execd/execd_commands.c if (rsc) { rsc 752 daemons/execd/execd_commands.c rsc->recurring_ops = g_list_remove(rsc->recurring_ops, cmd); rsc 753 daemons/execd/execd_commands.c rsc->pending_ops = g_list_remove(rsc->pending_ops, cmd); rsc 757 daemons/execd/execd_commands.c if (rsc) { rsc 758 daemons/execd/execd_commands.c rsc->pending_ops = g_list_remove(rsc->pending_ops, cmd); rsc 800 daemons/execd/execd_commands.c lrmd_rsc_t *rsc = NULL; rsc 804 daemons/execd/execd_commands.c while (g_hash_table_iter_next(&iter, (gpointer *) & key, (gpointer *) & rsc)) { rsc 805 daemons/execd/execd_commands.c if (pcmk_all_flags_set(rsc->call_opts, lrmd_opt_drop_recurring)) { rsc 808 daemons/execd/execd_commands.c cancel_all_recurring(rsc, client_id); rsc 816 daemons/execd/execd_commands.c lrmd_rsc_t *rsc; rsc 844 daemons/execd/execd_commands.c rsc = cmd->rsc_id ? g_hash_table_lookup(rsc_list, cmd->rsc_id) : NULL; rsc 847 daemons/execd/execd_commands.c if (rsc != NULL) { rsc 848 daemons/execd/execd_commands.c rclass = rsc->class; rsc 852 daemons/execd/execd_commands.c rclass = resources_find_service_class(rsc->type); rsc 909 daemons/execd/execd_commands.c if (rsc && pcmk__str_eq(rsc->class, PCMK_RESOURCE_CLASS_NAGIOS, pcmk__str_casei)) { rsc 956 daemons/execd/execd_commands.c if(rsc) { rsc 957 daemons/execd/execd_commands.c rsc->active = NULL; rsc 959 daemons/execd/execd_commands.c schedule_lrmd_cmd(rsc, cmd); rsc 980 daemons/execd/execd_commands.c cmd_finalize(cmd, rsc); rsc 998 daemons/execd/execd_commands.c lrmd_rsc_t *rsc = g_hash_table_lookup(rsc_list, cmd->rsc_id); rsc 1052 daemons/execd/execd_commands.c if ((rsc != NULL) && pcmk__result_ok(&(cmd->result))) { rsc 1055 daemons/execd/execd_commands.c pcmk__set_result(&rsc->fence_probe_result, CRM_EX_OK, rsc 1060 daemons/execd/execd_commands.c pcmk__set_result(&rsc->fence_probe_result, CRM_EX_ERROR, rsc 1074 daemons/execd/execd_commands.c if (rsc && (cmd->interval_ms > 0) rsc 1079 daemons/execd/execd_commands.c cmd_finalize(cmd, rsc); rsc 1100 daemons/execd/execd_commands.c lrmd_rsc_t *rsc = NULL; rsc 1106 daemons/execd/execd_commands.c while (g_hash_table_iter_next(&iter, NULL, (gpointer *) &rsc)) { rsc 1107 daemons/execd/execd_commands.c if (!pcmk__str_eq(rsc->class, PCMK_RESOURCE_CLASS_STONITH, rsc 1119 daemons/execd/execd_commands.c if (rsc->fence_probe_result.execution_status == PCMK_EXEC_DONE) { rsc 1120 daemons/execd/execd_commands.c pcmk__set_result(&rsc->fence_probe_result, CRM_EX_ERROR, rsc 1127 daemons/execd/execd_commands.c for (GList *op = rsc->recurring_ops; op != NULL; op = op->next) { rsc 1139 daemons/execd/execd_commands.c if (rsc->active != NULL) { rsc 1140 daemons/execd/execd_commands.c rsc->pending_ops = g_list_prepend(rsc->pending_ops, rsc->active); rsc 1142 daemons/execd/execd_commands.c while (rsc->pending_ops != NULL) { rsc 1144 daemons/execd/execd_commands.c stonith_action_complete((lrmd_cmd_t *) rsc->pending_ops->data, rsc 1165 daemons/execd/execd_commands.c execd_stonith_start(stonith_t *stonith_api, const lrmd_rsc_t *rsc, rsc 1190 daemons/execd/execd_commands.c cmd->rsc_id, rsc->provider, rsc 1191 daemons/execd/execd_commands.c rsc->type, device_params); rsc 1210 daemons/execd/execd_commands.c execd_stonith_stop(stonith_t *stonith_api, const lrmd_rsc_t *rsc) rsc 1216 daemons/execd/execd_commands.c rsc->rsc_id); rsc 1230 daemons/execd/execd_commands.c execd_stonith_monitor(stonith_t *stonith_api, lrmd_rsc_t *rsc, lrmd_cmd_t *cmd) rsc 1239 daemons/execd/execd_commands.c rsc->active = cmd; rsc 1248 daemons/execd/execd_commands.c execute_stonith_action(lrmd_rsc_t *rsc, lrmd_cmd_t *cmd) rsc 1258 daemons/execd/execd_commands.c stonith_action_complete(cmd, rsc->fence_probe_result.exit_status, rsc 1259 daemons/execd/execd_commands.c rsc->fence_probe_result.execution_status, rsc 1260 daemons/execd/execd_commands.c rsc->fence_probe_result.exit_reason); rsc 1270 daemons/execd/execd_commands.c rc = execd_stonith_start(stonith_api, rsc, cmd); rsc 1276 daemons/execd/execd_commands.c rc = execd_stonith_stop(stonith_api, rsc); rsc 1290 daemons/execd/execd_commands.c rc = execd_stonith_monitor(stonith_api, rsc, cmd); rsc 1304 daemons/execd/execd_commands.c execute_nonstonith_action(lrmd_rsc_t *rsc, lrmd_cmd_t *cmd) rsc 1309 daemons/execd/execd_commands.c pcmk__assert((rsc != NULL) && (cmd != NULL)); rsc 1312 daemons/execd/execd_commands.c rsc->rsc_id, cmd->action, rsc->class, rsc->provider, rsc->type); rsc 1316 daemons/execd/execd_commands.c if (pcmk__str_eq(rsc->class, PCMK_RESOURCE_CLASS_NAGIOS, pcmk__str_casei) rsc 1320 daemons/execd/execd_commands.c cmd_finalize(cmd, rsc); rsc 1327 daemons/execd/execd_commands.c action = services__create_resource_action(rsc->rsc_id, rsc->class, rsc->provider, rsc 1328 daemons/execd/execd_commands.c rsc->type, rsc 1329 daemons/execd/execd_commands.c normalize_action_name(rsc, cmd->action), rsc 1336 daemons/execd/execd_commands.c cmd_finalize(cmd, rsc); rsc 1344 daemons/execd/execd_commands.c cmd_finalize(cmd, rsc); rsc 1377 daemons/execd/execd_commands.c lrmd_rsc_t *rsc = (lrmd_rsc_t *) user_data; rsc 1380 daemons/execd/execd_commands.c CRM_CHECK(rsc != NULL, return FALSE); rsc 1382 daemons/execd/execd_commands.c if (rsc->active) { rsc 1383 daemons/execd/execd_commands.c crm_trace("%s is still active", rsc->rsc_id); rsc 1387 daemons/execd/execd_commands.c if (rsc->pending_ops) { rsc 1388 daemons/execd/execd_commands.c GList *first = rsc->pending_ops; rsc 1397 daemons/execd/execd_commands.c rsc->pending_ops = g_list_remove_link(rsc->pending_ops, first); rsc 1407 daemons/execd/execd_commands.c crm_trace("Nothing further to do for %s", rsc->rsc_id); rsc 1411 daemons/execd/execd_commands.c rsc->active = cmd; /* only one op at a time for a rsc */ rsc 1413 daemons/execd/execd_commands.c rsc->recurring_ops = g_list_append(rsc->recurring_ops, cmd); rsc 1418 daemons/execd/execd_commands.c if (pcmk__str_eq(rsc->class, PCMK_RESOURCE_CLASS_STONITH, pcmk__str_casei)) { rsc 1419 daemons/execd/execd_commands.c execute_stonith_action(rsc, cmd); rsc 1421 daemons/execd/execd_commands.c execute_nonstonith_action(rsc, cmd); rsc 1431 daemons/execd/execd_commands.c lrmd_rsc_t *rsc = data; rsc 1432 daemons/execd/execd_commands.c int is_stonith = pcmk__str_eq(rsc->class, PCMK_RESOURCE_CLASS_STONITH, rsc 1435 daemons/execd/execd_commands.c gIter = rsc->pending_ops; rsc 1447 daemons/execd/execd_commands.c g_list_free(rsc->pending_ops); rsc 1449 daemons/execd/execd_commands.c gIter = rsc->recurring_ops; rsc 1460 daemons/execd/execd_commands.c if (rsc->active != cmd) { rsc 1468 daemons/execd/execd_commands.c services_action_cancel(rsc->rsc_id, rsc 1469 daemons/execd/execd_commands.c normalize_action_name(rsc, cmd->action), rsc 1476 daemons/execd/execd_commands.c g_list_free(rsc->recurring_ops); rsc 1478 daemons/execd/execd_commands.c free(rsc->rsc_id); rsc 1479 daemons/execd/execd_commands.c free(rsc->class); rsc 1480 daemons/execd/execd_commands.c free(rsc->provider); rsc 1481 daemons/execd/execd_commands.c free(rsc->type); rsc 1482 daemons/execd/execd_commands.c mainloop_destroy_trigger(rsc->work); rsc 1484 daemons/execd/execd_commands.c free(rsc); rsc 1545 daemons/execd/execd_commands.c lrmd_rsc_t *rsc = build_rsc_from_xml(request); rsc 1546 daemons/execd/execd_commands.c lrmd_rsc_t *dup = g_hash_table_lookup(rsc_list, rsc->rsc_id); rsc 1549 daemons/execd/execd_commands.c pcmk__str_eq(rsc->class, dup->class, pcmk__str_casei) && rsc 1550 daemons/execd/execd_commands.c pcmk__str_eq(rsc->provider, dup->provider, pcmk__str_casei) && pcmk__str_eq(rsc->type, dup->type, pcmk__str_casei)) { rsc 1552 daemons/execd/execd_commands.c crm_notice("Ignoring duplicate registration of '%s'", rsc->rsc_id); rsc 1553 daemons/execd/execd_commands.c free_rsc(rsc); rsc 1557 daemons/execd/execd_commands.c g_hash_table_replace(rsc_list, rsc->rsc_id, rsc); rsc 1558 daemons/execd/execd_commands.c crm_info("Cached agent information for '%s'", rsc->rsc_id); rsc 1570 daemons/execd/execd_commands.c lrmd_rsc_t *rsc = NULL; rsc 1575 daemons/execd/execd_commands.c rsc = g_hash_table_lookup(rsc_list, rsc_id); rsc 1576 daemons/execd/execd_commands.c if (rsc == NULL) { rsc 1583 daemons/execd/execd_commands.c if (rsc) { rsc 1584 daemons/execd/execd_commands.c crm_xml_add(reply, PCMK__XA_LRMD_RSC_ID, rsc->rsc_id); rsc 1585 daemons/execd/execd_commands.c crm_xml_add(reply, PCMK__XA_LRMD_CLASS, rsc->class); rsc 1586 daemons/execd/execd_commands.c crm_xml_add(reply, PCMK__XA_LRMD_PROVIDER, rsc->provider); rsc 1587 daemons/execd/execd_commands.c crm_xml_add(reply, PCMK__XA_LRMD_TYPE, rsc->type); rsc 1597 daemons/execd/execd_commands.c lrmd_rsc_t *rsc = NULL; rsc 1606 daemons/execd/execd_commands.c rsc = g_hash_table_lookup(rsc_list, rsc_id); rsc 1607 daemons/execd/execd_commands.c if (rsc == NULL) { rsc 1613 daemons/execd/execd_commands.c if (rsc->active) { rsc 1616 daemons/execd/execd_commands.c rsc->active, rsc_id); rsc 1628 daemons/execd/execd_commands.c lrmd_rsc_t *rsc = NULL; rsc 1638 daemons/execd/execd_commands.c if (!(rsc = g_hash_table_lookup(rsc_list, rsc_id))) { rsc 1649 daemons/execd/execd_commands.c schedule_lrmd_cmd(rsc, cmd); rsc 1658 daemons/execd/execd_commands.c lrmd_rsc_t *rsc = g_hash_table_lookup(rsc_list, rsc_id); rsc 1671 daemons/execd/execd_commands.c if (!rsc) { rsc 1675 daemons/execd/execd_commands.c for (gIter = rsc->pending_ops; gIter != NULL; gIter = gIter->next) { rsc 1680 daemons/execd/execd_commands.c cmd_finalize(cmd, rsc); rsc 1685 daemons/execd/execd_commands.c if (pcmk__str_eq(rsc->class, PCMK_RESOURCE_CLASS_STONITH, pcmk__str_casei)) { rsc 1688 daemons/execd/execd_commands.c for (gIter = rsc->recurring_ops; gIter != NULL; gIter = gIter->next) { rsc 1693 daemons/execd/execd_commands.c if (rsc->active != cmd) { rsc 1694 daemons/execd/execd_commands.c cmd_finalize(cmd, rsc); rsc 1700 daemons/execd/execd_commands.c normalize_action_name(rsc, action), rsc 1713 daemons/execd/execd_commands.c cancel_all_recurring(lrmd_rsc_t * rsc, const char *client_id) rsc 1724 daemons/execd/execd_commands.c if (rsc->recurring_ops) { rsc 1725 daemons/execd/execd_commands.c cmd_list = g_list_concat(cmd_list, g_list_copy(rsc->recurring_ops)); rsc 1727 daemons/execd/execd_commands.c if (rsc->pending_ops) { rsc 1728 daemons/execd/execd_commands.c cmd_list = g_list_concat(cmd_list, g_list_copy(rsc->pending_ops)); rsc 1745 daemons/execd/execd_commands.c cancel_op(rsc->rsc_id, cmd->action, cmd->interval_ms); rsc 1770 daemons/execd/execd_commands.c add_recurring_op_xml(xmlNode *reply, lrmd_rsc_t *rsc) rsc 1774 daemons/execd/execd_commands.c crm_xml_add(rsc_xml, PCMK__XA_LRMD_RSC_ID, rsc->rsc_id); rsc 1775 daemons/execd/execd_commands.c for (GList *item = rsc->recurring_ops; item != NULL; item = item->next) { rsc 1791 daemons/execd/execd_commands.c lrmd_rsc_t *rsc = NULL; rsc 1806 daemons/execd/execd_commands.c rsc = g_hash_table_lookup(rsc_list, rsc_id); rsc 1807 daemons/execd/execd_commands.c if (rsc == NULL) { rsc 1823 daemons/execd/execd_commands.c (gpointer *) &rsc)) { rsc 1824 daemons/execd/execd_commands.c add_recurring_op_xml(reply, rsc); rsc 1826 daemons/execd/execd_commands.c } else if (rsc) { rsc 1827 daemons/execd/execd_commands.c add_recurring_op_xml(reply, rsc); rsc 83 daemons/fenced/fenced_scheduler.c local_node_allowed_for(const pcmk_resource_t *rsc) rsc 85 daemons/fenced/fenced_scheduler.c if ((rsc != NULL) && (stonith_our_uname != NULL)) { rsc 89 daemons/fenced/fenced_scheduler.c g_hash_table_iter_init(&iter, rsc->allowed_nodes); rsc 111 daemons/fenced/fenced_scheduler.c pcmk_resource_t *rsc = data; rsc 123 daemons/fenced/fenced_scheduler.c if (rsc->children != NULL) { rsc 124 daemons/fenced/fenced_scheduler.c for (GList *iter = rsc->children; iter != NULL; iter = iter->next) { rsc 126 daemons/fenced/fenced_scheduler.c if (pcmk__is_clone(rsc)) { rsc 133 daemons/fenced/fenced_scheduler.c if (!pcmk_is_set(rsc->flags, pcmk_rsc_fence_device)) { rsc 137 daemons/fenced/fenced_scheduler.c if (pe__resource_is_disabled(rsc)) { rsc 138 daemons/fenced/fenced_scheduler.c crm_info("Ignoring fencing device %s because it is disabled", rsc->id); rsc 143 daemons/fenced/fenced_scheduler.c pcmk__str_eq(rsc->id, STONITH_WATCHDOG_ID, pcmk__str_none)) { rsc 145 daemons/fenced/fenced_scheduler.c "because watchdog fencing is disabled", rsc->id); rsc 150 daemons/fenced/fenced_scheduler.c node = local_node_allowed_for(rsc); rsc 153 daemons/fenced/fenced_scheduler.c "because local node is not allowed to run it", rsc->id); rsc 159 daemons/fenced/fenced_scheduler.c rsc->id, pcmk_readable_score(node->weight)); rsc 164 daemons/fenced/fenced_scheduler.c if (pcmk__is_group(rsc->parent)) { rsc 165 daemons/fenced/fenced_scheduler.c pcmk_node_t *group_node = local_node_allowed_for(rsc->parent); rsc 170 daemons/fenced/fenced_scheduler.c rsc->id, pcmk_readable_score(group_node->weight)); rsc 175 daemons/fenced/fenced_scheduler.c crm_debug("Reloading configuration of fencing device %s", rsc->id); rsc 177 daemons/fenced/fenced_scheduler.c agent = crm_element_value(rsc->xml, PCMK_XA_TYPE); rsc 183 daemons/fenced/fenced_scheduler.c get_meta_attributes(rsc->meta, rsc, node, scheduler); rsc 184 daemons/fenced/fenced_scheduler.c rsc_provides = g_hash_table_lookup(rsc->meta, PCMK_STONITH_PROVIDES); rsc 186 daemons/fenced/fenced_scheduler.c g_hash_table_iter_init(&hash_iter, pe_rsc_params(rsc, node, scheduler)); rsc 195 daemons/fenced/fenced_scheduler.c xml = create_device_registration_xml(pcmk__s(rsc->clone_name, rsc->id), rsc 340 include/crm/common/actions.h pcmk_resource_t *rsc; // Resource to apply action to, if any rsc 45 include/crm/common/bundles_internal.h pcmk__is_bundle(const pcmk_resource_t *rsc) rsc 47 include/crm/common/bundles_internal.h return (rsc != NULL) && (rsc->variant == pcmk_rsc_variant_bundle); rsc 59 include/crm/common/bundles_internal.h pcmk__is_bundled(const pcmk_resource_t *rsc) rsc 61 include/crm/common/bundles_internal.h if (rsc == NULL) { rsc 64 include/crm/common/bundles_internal.h while (rsc->parent != NULL) { rsc 65 include/crm/common/bundles_internal.h rsc = rsc->parent; rsc 67 include/crm/common/bundles_internal.h return rsc->variant == pcmk_rsc_variant_bundle; rsc 44 include/crm/common/clone_internal.h pcmk__is_clone(const pcmk_resource_t *rsc) rsc 46 include/crm/common/clone_internal.h return (rsc != NULL) && (rsc->variant == pcmk_rsc_variant_clone); rsc 58 include/crm/common/clone_internal.h pcmk__is_unique_clone(const pcmk_resource_t *rsc) rsc 60 include/crm/common/clone_internal.h return pcmk__is_clone(rsc) && pcmk_is_set(rsc->flags, pcmk_rsc_unique); rsc 72 include/crm/common/clone_internal.h pcmk__is_anonymous_clone(const pcmk_resource_t *rsc) rsc 74 include/crm/common/clone_internal.h return pcmk__is_clone(rsc) && !pcmk_is_set(rsc->flags, pcmk_rsc_unique); rsc 38 include/crm/common/group_internal.h pcmk__is_group(const pcmk_resource_t *rsc) rsc 40 include/crm/common/group_internal.h return (rsc != NULL) && (rsc->variant == pcmk_rsc_variant_group); rsc 26 include/crm/common/location_internal.h pcmk_resource_t *rsc; // Resource with location preference rsc 30 include/crm/common/primitive_internal.h pcmk__is_primitive(const pcmk_resource_t *rsc) rsc 32 include/crm/common/primitive_internal.h return (rsc != NULL) && (rsc->variant == pcmk_rsc_variant_primitive); rsc 264 include/crm/common/resources.h gboolean (*unpack)(pcmk_resource_t *rsc, pcmk_scheduler_t *scheduler); rsc 276 include/crm/common/resources.h pcmk_resource_t *(*find_rsc)(pcmk_resource_t *rsc, const char *search, rsc 291 include/crm/common/resources.h char *(*parameter)(pcmk_resource_t *rsc, pcmk_node_t *node, gboolean create, rsc 295 include/crm/common/resources.h void (*print)(pcmk_resource_t *rsc, const char *pre_text, long options, rsc 306 include/crm/common/resources.h gboolean (*active)(pcmk_resource_t *rsc, gboolean all); rsc 316 include/crm/common/resources.h enum rsc_role_e (*state)(const pcmk_resource_t *rsc, gboolean current); rsc 328 include/crm/common/resources.h pcmk_node_t *(*location)(const pcmk_resource_t *rsc, GList **list, rsc 336 include/crm/common/resources.h void (*free)(pcmk_resource_t *rsc); rsc 346 include/crm/common/resources.h void (*count)(pcmk_resource_t *rsc); rsc 358 include/crm/common/resources.h gboolean (*is_filtered)(const pcmk_resource_t *rsc, GList *only_rsc, rsc 373 include/crm/common/resources.h pcmk_node_t *(*active_node)(const pcmk_resource_t *rsc, rsc 384 include/crm/common/resources.h unsigned int (*max_per_node)(const pcmk_resource_t *rsc); rsc 495 include/crm/common/resources.h const char *pcmk_resource_id(const pcmk_resource_t *rsc); rsc 496 include/crm/common/resources.h bool pcmk_resource_is_managed(const pcmk_resource_t *rsc); rsc 57 include/crm/common/roles_internal.h pcmk__current_node(const pcmk_resource_t *rsc) rsc 59 include/crm/common/roles_internal.h return (rsc == NULL)? NULL : rsc->fns->active_node(rsc, NULL, NULL); rsc 56 include/crm/common/scheduler_internal.h #define pcmk__rsc_info(rsc, fmt, args...) \ rsc 57 include/crm/common/scheduler_internal.h crm_log_tag(LOG_INFO, ((rsc) == NULL)? "<NULL>" : (rsc)->id, (fmt), ##args) rsc 66 include/crm/common/scheduler_internal.h #define pcmk__rsc_debug(rsc, fmt, args...) \ rsc 67 include/crm/common/scheduler_internal.h crm_log_tag(LOG_DEBUG, ((rsc) == NULL)? "<NULL>" : (rsc)->id, (fmt), ##args) rsc 76 include/crm/common/scheduler_internal.h #define pcmk__rsc_trace(rsc, fmt, args...) \ rsc 77 include/crm/common/scheduler_internal.h crm_log_tag(LOG_TRACE, ((rsc) == NULL)? "<NULL>" : (rsc)->id, (fmt), ##args) rsc 38 include/crm/lrmd_internal.h int lrmd__metadata_async(const lrmd_rsc_info_t *rsc, rsc 25 include/crm/pengine/complex.h GHashTable *pe_rsc_params(pcmk_resource_t *rsc, const pcmk_node_t *node, rsc 27 include/crm/pengine/complex.h void get_meta_attributes(GHashTable * meta_hash, pcmk_resource_t *rsc, rsc 29 include/crm/pengine/complex.h void get_rsc_attributes(GHashTable *meta_hash, const pcmk_resource_t *rsc, rsc 32 include/crm/pengine/complex.h gboolean is_parent(pcmk_resource_t *child, pcmk_resource_t *rsc); rsc 33 include/crm/pengine/complex.h pcmk_resource_t *uber_parent(pcmk_resource_t *rsc); rsc 24 include/crm/pengine/internal.h const char *pe__resource_description(const pcmk_resource_t *rsc, rsc 34 include/crm/pengine/internal.h const pcmk_resource_t *pe__const_top_resource(const pcmk_resource_t *rsc, rsc 49 include/crm/pengine/internal.h pcmk_action_t *pe__new_rsc_pseudo_action(pcmk_resource_t *rsc, const char *task, rsc 57 include/crm/pengine/internal.h char *native_parameter(pcmk_resource_t *rsc, pcmk_node_t *node, gboolean create, rsc 59 include/crm/pengine/internal.h pcmk_node_t *native_location(const pcmk_resource_t *rsc, GList **list, rsc 61 include/crm/pengine/internal.h void native_add_running(pcmk_resource_t *rsc, pcmk_node_t *node, rsc 64 include/crm/pengine/internal.h gboolean native_unpack(pcmk_resource_t *rsc, pcmk_scheduler_t *scheduler); rsc 65 include/crm/pengine/internal.h gboolean group_unpack(pcmk_resource_t *rsc, pcmk_scheduler_t *scheduler); rsc 66 include/crm/pengine/internal.h gboolean clone_unpack(pcmk_resource_t *rsc, pcmk_scheduler_t *scheduler); rsc 67 include/crm/pengine/internal.h gboolean pe__unpack_bundle(pcmk_resource_t *rsc, pcmk_scheduler_t *scheduler); rsc 69 include/crm/pengine/internal.h pcmk_resource_t *native_find_rsc(pcmk_resource_t *rsc, const char *id, rsc 72 include/crm/pengine/internal.h gboolean native_active(pcmk_resource_t *rsc, gboolean all); rsc 73 include/crm/pengine/internal.h gboolean group_active(pcmk_resource_t *rsc, gboolean all); rsc 74 include/crm/pengine/internal.h gboolean clone_active(pcmk_resource_t *rsc, gboolean all); rsc 75 include/crm/pengine/internal.h gboolean pe__bundle_active(pcmk_resource_t *rsc, gboolean all); rsc 78 include/crm/pengine/internal.h void native_print(pcmk_resource_t *rsc, const char *pre_text, long options, rsc 82 include/crm/pengine/internal.h void group_print(pcmk_resource_t *rsc, const char *pre_text, long options, rsc 86 include/crm/pengine/internal.h void clone_print(pcmk_resource_t *rsc, const char *pre_text, long options, rsc 90 include/crm/pengine/internal.h void pe__print_bundle(pcmk_resource_t *rsc, const char *pre_text, long options, rsc 93 include/crm/pengine/internal.h gchar *pcmk__native_output_string(const pcmk_resource_t *rsc, const char *name, rsc 104 include/crm/pengine/internal.h pcmk_resource_t *rsc, rsc 123 include/crm/pengine/internal.h void native_free(pcmk_resource_t *rsc); rsc 124 include/crm/pengine/internal.h void group_free(pcmk_resource_t *rsc); rsc 125 include/crm/pengine/internal.h void clone_free(pcmk_resource_t *rsc); rsc 126 include/crm/pengine/internal.h void pe__free_bundle(pcmk_resource_t *rsc); rsc 128 include/crm/pengine/internal.h enum rsc_role_e native_resource_state(const pcmk_resource_t *rsc, rsc 130 include/crm/pengine/internal.h enum rsc_role_e group_resource_state(const pcmk_resource_t *rsc, rsc 132 include/crm/pengine/internal.h enum rsc_role_e clone_resource_state(const pcmk_resource_t *rsc, rsc 134 include/crm/pengine/internal.h enum rsc_role_e pe__bundle_resource_state(const pcmk_resource_t *rsc, rsc 137 include/crm/pengine/internal.h void pe__count_common(pcmk_resource_t *rsc); rsc 138 include/crm/pengine/internal.h void pe__count_bundle(pcmk_resource_t *rsc); rsc 140 include/crm/pengine/internal.h void common_free(pcmk_resource_t *rsc); rsc 147 include/crm/pengine/internal.h int pe_get_failcount(const pcmk_node_t *node, pcmk_resource_t *rsc, rsc 151 include/crm/pengine/internal.h pcmk_action_t *pe__clear_failcount(pcmk_resource_t *rsc, rsc 157 include/crm/pengine/internal.h bool pe__count_active_node(const pcmk_resource_t *rsc, pcmk_node_t *node, rsc 161 include/crm/pengine/internal.h pcmk_node_t *pe__find_active_requires(const pcmk_resource_t *rsc, rsc 172 include/crm/pengine/internal.h int line, bool to_log, const pcmk_resource_t *rsc, rsc 176 include/crm/pengine/internal.h #define pe__show_node_scores(level, rsc, text, nodes, scheduler) \ rsc 178 include/crm/pengine/internal.h (level), (rsc), (text), (nodes), (scheduler)) rsc 180 include/crm/pengine/internal.h GHashTable *pcmk__unpack_action_meta(pcmk_resource_t *rsc, rsc 187 include/crm/pengine/internal.h xmlNode *pcmk__find_action_config(const pcmk_resource_t *rsc, rsc 191 include/crm/pengine/internal.h enum rsc_start_requirement pcmk__action_requires(const pcmk_resource_t *rsc, rsc 194 include/crm/pengine/internal.h enum action_fail_response pcmk__parse_on_fail(const pcmk_resource_t *rsc, rsc 199 include/crm/pengine/internal.h enum rsc_role_e pcmk__role_after_failure(const pcmk_resource_t *rsc, rsc 204 include/crm/pengine/internal.h pcmk_action_t *custom_action(pcmk_resource_t *rsc, char *key, const char *task, rsc 208 include/crm/pengine/internal.h # define delete_key(rsc) pcmk__op_key(rsc->id, PCMK_ACTION_DELETE, 0) rsc 209 include/crm/pengine/internal.h # define delete_action(rsc, node, optional) custom_action( \ rsc 210 include/crm/pengine/internal.h rsc, delete_key(rsc), PCMK_ACTION_DELETE, node, \ rsc 211 include/crm/pengine/internal.h optional, rsc->cluster); rsc 213 include/crm/pengine/internal.h # define stop_key(rsc) pcmk__op_key(rsc->id, PCMK_ACTION_STOP, 0) rsc 214 include/crm/pengine/internal.h # define stop_action(rsc, node, optional) custom_action( \ rsc 215 include/crm/pengine/internal.h rsc, stop_key(rsc), PCMK_ACTION_STOP, node, \ rsc 216 include/crm/pengine/internal.h optional, rsc->cluster); rsc 218 include/crm/pengine/internal.h # define reload_key(rsc) pcmk__op_key(rsc->id, PCMK_ACTION_RELOAD_AGENT, 0) rsc 219 include/crm/pengine/internal.h # define start_key(rsc) pcmk__op_key(rsc->id, PCMK_ACTION_START, 0) rsc 220 include/crm/pengine/internal.h # define start_action(rsc, node, optional) custom_action( \ rsc 221 include/crm/pengine/internal.h rsc, start_key(rsc), PCMK_ACTION_START, node, \ rsc 222 include/crm/pengine/internal.h optional, rsc->cluster) rsc 224 include/crm/pengine/internal.h # define promote_key(rsc) pcmk__op_key(rsc->id, PCMK_ACTION_PROMOTE, 0) rsc 225 include/crm/pengine/internal.h # define promote_action(rsc, node, optional) custom_action( \ rsc 226 include/crm/pengine/internal.h rsc, promote_key(rsc), PCMK_ACTION_PROMOTE, node, \ rsc 227 include/crm/pengine/internal.h optional, rsc->cluster) rsc 229 include/crm/pengine/internal.h # define demote_key(rsc) pcmk__op_key(rsc->id, PCMK_ACTION_DEMOTE, 0) rsc 230 include/crm/pengine/internal.h # define demote_action(rsc, node, optional) custom_action( \ rsc 231 include/crm/pengine/internal.h rsc, demote_key(rsc), PCMK_ACTION_DEMOTE, node, \ rsc 232 include/crm/pengine/internal.h optional, rsc->cluster) rsc 237 include/crm/pengine/internal.h enum action_tasks get_complex_task(const pcmk_resource_t *rsc, rsc 243 include/crm/pengine/internal.h GList *pe__resource_actions(const pcmk_resource_t *rsc, const pcmk_node_t *node, rsc 248 include/crm/pengine/internal.h void resource_location(pcmk_resource_t *rsc, const pcmk_node_t *node, int score, rsc 254 include/crm/pengine/internal.h gboolean get_target_role(const pcmk_resource_t *rsc, enum rsc_role_e *role); rsc 255 include/crm/pengine/internal.h void pe__set_next_role(pcmk_resource_t *rsc, enum rsc_role_e role, rsc 258 include/crm/pengine/internal.h pcmk_resource_t *find_clone_instance(const pcmk_resource_t *rsc, rsc 270 include/crm/pengine/internal.h pe_base_name_eq(const pcmk_resource_t *rsc, const char *id) rsc 272 include/crm/pengine/internal.h if (id && rsc && rsc->id) { rsc 274 include/crm/pengine/internal.h size_t base_len = pe_base_name_end(rsc->id) - rsc->id + 1; rsc 276 include/crm/pengine/internal.h return (strlen(id) == base_len) && !strncmp(id, rsc->id, base_len); rsc 284 include/crm/pengine/internal.h bool is_set_recursive(const pcmk_resource_t *rsc, long long flag, bool any); rsc 286 include/crm/pengine/internal.h pcmk__op_digest_t *pe__calculate_digests(pcmk_resource_t *rsc, const char *task, rsc 296 include/crm/pengine/internal.h pcmk__op_digest_t *rsc_action_digest_cmp(pcmk_resource_t *rsc, rsc 304 include/crm/pengine/internal.h void trigger_unfencing(pcmk_resource_t *rsc, pcmk_node_t *node, rsc 313 include/crm/pengine/internal.h void pe__set_resource_flags_recursive(pcmk_resource_t *rsc, uint64_t flags); rsc 314 include/crm/pengine/internal.h void pe__clear_resource_flags_recursive(pcmk_resource_t *rsc, uint64_t flags); rsc 331 include/crm/pengine/internal.h void common_print(pcmk_resource_t *rsc, const char *pre_text, const char *name, rsc 333 include/crm/pengine/internal.h int pe__common_output_text(pcmk__output_t *out, const pcmk_resource_t *rsc, rsc 336 include/crm/pengine/internal.h int pe__common_output_html(pcmk__output_t *out, const pcmk_resource_t *rsc, rsc 342 include/crm/pengine/internal.h int pe__bundle_max(const pcmk_resource_t *rsc); rsc 345 include/crm/pengine/internal.h pcmk_resource_t *pe__bundled_resource(const pcmk_resource_t *rsc); rsc 357 include/crm/pengine/internal.h bool pe__bundle_needs_remote_name(pcmk_resource_t *rsc); rsc 358 include/crm/pengine/internal.h const char *pe__add_bundle_remote_name(pcmk_resource_t *rsc, xmlNode *xml, rsc 360 include/crm/pengine/internal.h bool pe__is_universal_clone(const pcmk_resource_t *rsc, rsc 362 include/crm/pengine/internal.h void pe__add_param_check(const xmlNode *rsc_op, pcmk_resource_t *rsc, rsc 389 include/crm/pengine/internal.h bool pe__resource_is_disabled(const pcmk_resource_t *rsc); rsc 390 include/crm/pengine/internal.h void pe__clear_resource_history(pcmk_resource_t *rsc, const pcmk_node_t *node); rsc 394 include/crm/pengine/internal.h bool pe__rsc_has_tag(pcmk_scheduler_t *scheduler, const char *rsc, rsc 399 include/crm/pengine/internal.h bool pe__rsc_running_on_only(const pcmk_resource_t *rsc, rsc 401 include/crm/pengine/internal.h bool pe__rsc_running_on_any(pcmk_resource_t *rsc, GList *node_list); rsc 406 include/crm/pengine/internal.h bool pcmk__rsc_filtered_by_node(pcmk_resource_t *rsc, GList *only_node); rsc 408 include/crm/pengine/internal.h gboolean pe__bundle_is_filtered(const pcmk_resource_t *rsc, GList *only_rsc, rsc 410 include/crm/pengine/internal.h gboolean pe__clone_is_filtered(const pcmk_resource_t *rsc, GList *only_rsc, rsc 412 include/crm/pengine/internal.h gboolean pe__group_is_filtered(const pcmk_resource_t *rsc, GList *only_rsc, rsc 414 include/crm/pengine/internal.h gboolean pe__native_is_filtered(const pcmk_resource_t *rsc, GList *only_rsc, rsc 417 include/crm/pengine/internal.h xmlNode *pe__failed_probe_for_rsc(const pcmk_resource_t *rsc, const char *name); rsc 419 include/crm/pengine/internal.h const char *pe__clone_child_id(const pcmk_resource_t *rsc); rsc 23 include/crm/pengine/remote_internal.h const pcmk_resource_t *rsc); rsc 31 include/crm/pengine/status.h const char *rsc_printable_id(const pcmk_resource_t *rsc); rsc 54 include/crm/pengine/status.h GList *find_operations(const char *rsc, const char *node, gboolean active_filter, rsc 58 include/crm/pengine/status.h int pe_bundle_replicas(const pcmk_resource_t *rsc); rsc 36 include/crm/pengine/status_compat.h pe_rsc_is_clone(const pcmk_resource_t *rsc) rsc 38 include/crm/pengine/status_compat.h return (rsc != NULL) && (rsc->variant == pcmk_rsc_variant_clone); rsc 43 include/crm/pengine/status_compat.h pe_rsc_is_unique_clone(const pcmk_resource_t *rsc) rsc 45 include/crm/pengine/status_compat.h return pe_rsc_is_clone(rsc) && pcmk_is_set(rsc->flags, pcmk_rsc_unique); rsc 50 include/crm/pengine/status_compat.h pe_rsc_is_anon_clone(const pcmk_resource_t *rsc) rsc 52 include/crm/pengine/status_compat.h return pe_rsc_is_clone(rsc) && !pcmk_is_set(rsc->flags, pcmk_rsc_unique); rsc 57 include/crm/pengine/status_compat.h pe_rsc_is_bundled(const pcmk_resource_t *rsc) rsc 59 include/crm/pengine/status_compat.h if (rsc == NULL) { rsc 62 include/crm/pengine/status_compat.h while (rsc->parent != NULL) { rsc 63 include/crm/pengine/status_compat.h rsc = rsc->parent; rsc 65 include/crm/pengine/status_compat.h return rsc->variant == pcmk_rsc_variant_bundle; rsc 129 include/crm/services.h char *rsc; rsc 222 include/pacemaker.h int pcmk_resource_digests(xmlNodePtr *xml, pcmk_resource_t *rsc, rsc 21 include/pcmki/pcmki_resource.h int pcmk__resource_digests(pcmk__output_t *out, pcmk_resource_t *rsc, rsc 144 include/pcmki/pcmki_transition.h int (*rsc) (pcmk__graph_t *graph, pcmk__graph_action_t *action); rsc 27 lib/common/resources.c pcmk_resource_id(const pcmk_resource_t *rsc) rsc 29 lib/common/resources.c return (rsc == NULL)? NULL : rsc->id; rsc 41 lib/common/resources.c pcmk_resource_is_managed(const pcmk_resource_t *rsc) rsc 43 lib/common/resources.c return (rsc == NULL)? false : pcmk_is_set(rsc->flags, pcmk_rsc_managed); rsc 19 lib/common/tests/actions/parse_op_key_test.c char *rsc = NULL; rsc 23 lib/common/tests/actions/parse_op_key_test.c assert_true(parse_op_key("Fencing_monitor_60000", &rsc, &ty, &ms)); rsc 24 lib/common/tests/actions/parse_op_key_test.c assert_string_equal(rsc, "Fencing"); rsc 27 lib/common/tests/actions/parse_op_key_test.c free(rsc); rsc 31 lib/common/tests/actions/parse_op_key_test.c assert_true(parse_op_key("R_monitor_100000", &rsc, &ty, &ms)); rsc 32 lib/common/tests/actions/parse_op_key_test.c assert_string_equal(rsc, "R"); rsc 35 lib/common/tests/actions/parse_op_key_test.c free(rsc); rsc 39 lib/common/tests/actions/parse_op_key_test.c assert_true(parse_op_key("R_A_0", &rsc, &ty, &ms)); rsc 40 lib/common/tests/actions/parse_op_key_test.c assert_string_equal(rsc, "R"); rsc 43 lib/common/tests/actions/parse_op_key_test.c free(rsc); rsc 50 lib/common/tests/actions/parse_op_key_test.c char *rsc = NULL; rsc 54 lib/common/tests/actions/parse_op_key_test.c assert_true(parse_op_key("__monitor_1000", &rsc, &ty, &ms)); rsc 55 lib/common/tests/actions/parse_op_key_test.c assert_string_equal(rsc, "_"); rsc 58 lib/common/tests/actions/parse_op_key_test.c free(rsc); rsc 61 lib/common/tests/actions/parse_op_key_test.c assert_true(parse_op_key("___migrate_from_0", &rsc, &ty, &ms)); rsc 62 lib/common/tests/actions/parse_op_key_test.c assert_string_equal(rsc, "__"); rsc 65 lib/common/tests/actions/parse_op_key_test.c free(rsc); rsc 68 lib/common/tests/actions/parse_op_key_test.c assert_true(parse_op_key("____pre_notify_stop_0", &rsc, &ty, &ms)); rsc 69 lib/common/tests/actions/parse_op_key_test.c assert_string_equal(rsc, "___"); rsc 72 lib/common/tests/actions/parse_op_key_test.c free(rsc); rsc 79 lib/common/tests/actions/parse_op_key_test.c char *rsc = NULL; rsc 83 lib/common/tests/actions/parse_op_key_test.c assert_true(parse_op_key("ClusterIP:0_start_0", &rsc, &ty, &ms)); rsc 84 lib/common/tests/actions/parse_op_key_test.c assert_string_equal(rsc, "ClusterIP:0"); rsc 87 lib/common/tests/actions/parse_op_key_test.c free(rsc); rsc 90 lib/common/tests/actions/parse_op_key_test.c assert_true(parse_op_key("imagestoreclone:1_post_notify_stop_0", &rsc, &ty, &ms)); rsc 91 lib/common/tests/actions/parse_op_key_test.c assert_string_equal(rsc, "imagestoreclone:1"); rsc 94 lib/common/tests/actions/parse_op_key_test.c free(rsc); rsc 101 lib/common/tests/actions/parse_op_key_test.c char *rsc = NULL; rsc 105 lib/common/tests/actions/parse_op_key_test.c assert_true(parse_op_key("httpd-bundle-0_monitor_30000", &rsc, &ty, &ms)); rsc 106 lib/common/tests/actions/parse_op_key_test.c assert_string_equal(rsc, "httpd-bundle-0"); rsc 109 lib/common/tests/actions/parse_op_key_test.c free(rsc); rsc 112 lib/common/tests/actions/parse_op_key_test.c assert_true(parse_op_key("httpd-bundle-ip-192.168.122.132_start_0", &rsc, &ty, &ms)); rsc 113 lib/common/tests/actions/parse_op_key_test.c assert_string_equal(rsc, "httpd-bundle-ip-192.168.122.132"); rsc 116 lib/common/tests/actions/parse_op_key_test.c free(rsc); rsc 123 lib/common/tests/actions/parse_op_key_test.c char *rsc = NULL; rsc 127 lib/common/tests/actions/parse_op_key_test.c assert_true(parse_op_key("vm_migrate_from_0", &rsc, &ty, &ms)); rsc 128 lib/common/tests/actions/parse_op_key_test.c assert_string_equal(rsc, "vm"); rsc 131 lib/common/tests/actions/parse_op_key_test.c free(rsc); rsc 134 lib/common/tests/actions/parse_op_key_test.c assert_true(parse_op_key("vm_migrate_to_0", &rsc, &ty, &ms)); rsc 135 lib/common/tests/actions/parse_op_key_test.c assert_string_equal(rsc, "vm"); rsc 138 lib/common/tests/actions/parse_op_key_test.c free(rsc); rsc 141 lib/common/tests/actions/parse_op_key_test.c assert_true(parse_op_key("vm_idcc_devel_migrate_to_0", &rsc, &ty, &ms)); rsc 142 lib/common/tests/actions/parse_op_key_test.c assert_string_equal(rsc, "vm_idcc_devel"); rsc 145 lib/common/tests/actions/parse_op_key_test.c free(rsc); rsc 152 lib/common/tests/actions/parse_op_key_test.c char *rsc = NULL; rsc 156 lib/common/tests/actions/parse_op_key_test.c assert_true(parse_op_key("rsc_drbd_7788:1_post_notify_start_0", &rsc, &ty, &ms)); rsc 157 lib/common/tests/actions/parse_op_key_test.c assert_string_equal(rsc, "rsc_drbd_7788:1"); rsc 160 lib/common/tests/actions/parse_op_key_test.c free(rsc); rsc 163 lib/common/tests/actions/parse_op_key_test.c assert_true(parse_op_key("rabbitmq-bundle-clone_pre_notify_stop_0", &rsc, &ty, &ms)); rsc 164 lib/common/tests/actions/parse_op_key_test.c assert_string_equal(rsc, "rabbitmq-bundle-clone"); rsc 167 lib/common/tests/actions/parse_op_key_test.c free(rsc); rsc 170 lib/common/tests/actions/parse_op_key_test.c assert_true(parse_op_key("post_notify_start_0", &rsc, &ty, &ms)); rsc 171 lib/common/tests/actions/parse_op_key_test.c assert_string_equal(rsc, "post_notify"); rsc 174 lib/common/tests/actions/parse_op_key_test.c free(rsc); rsc 178 lib/common/tests/actions/parse_op_key_test.c &rsc, &ty, &ms)); rsc 179 lib/common/tests/actions/parse_op_key_test.c assert_string_equal(rsc, "r"); rsc 182 lib/common/tests/actions/parse_op_key_test.c free(rsc); rsc 201 lib/common/tests/actions/parse_op_key_test.c char *rsc = NULL; rsc 204 lib/common/tests/actions/parse_op_key_test.c assert_true(parse_op_key("Fencing_monitor_60000", &rsc, NULL, &ms)); rsc 205 lib/common/tests/actions/parse_op_key_test.c assert_string_equal(rsc, "Fencing"); rsc 207 lib/common/tests/actions/parse_op_key_test.c free(rsc); rsc 213 lib/common/tests/actions/parse_op_key_test.c char *rsc = NULL; rsc 216 lib/common/tests/actions/parse_op_key_test.c assert_true(parse_op_key("Fencing_monitor_60000", &rsc, &ty, NULL)); rsc 217 lib/common/tests/actions/parse_op_key_test.c assert_string_equal(rsc, "Fencing"); rsc 219 lib/common/tests/actions/parse_op_key_test.c free(rsc); rsc 226 lib/common/tests/actions/parse_op_key_test.c char *rsc = NULL; rsc 230 lib/common/tests/actions/parse_op_key_test.c assert_false(parse_op_key("", &rsc, &ty, &ms)); rsc 231 lib/common/tests/actions/parse_op_key_test.c assert_null(rsc); rsc 235 lib/common/tests/actions/parse_op_key_test.c assert_false(parse_op_key(NULL, &rsc, &ty, &ms)); rsc 236 lib/common/tests/actions/parse_op_key_test.c assert_null(rsc); rsc 244 lib/common/tests/actions/parse_op_key_test.c char *rsc = NULL; rsc 248 lib/common/tests/actions/parse_op_key_test.c assert_false(parse_op_key("httpd-bundle-0", &rsc, &ty, &ms)); rsc 249 lib/common/tests/actions/parse_op_key_test.c assert_null(rsc); rsc 253 lib/common/tests/actions/parse_op_key_test.c assert_false(parse_op_key("httpd-bundle-0_monitor", &rsc, &ty, &ms)); rsc 254 lib/common/tests/actions/parse_op_key_test.c assert_null(rsc); rsc 258 lib/common/tests/actions/parse_op_key_test.c assert_false(parse_op_key("httpd-bundle-0_30000", &rsc, &ty, &ms)); rsc 259 lib/common/tests/actions/parse_op_key_test.c assert_null(rsc); rsc 37 lib/common/tests/nodes/pcmk_foreach_active_resource_test.c fn(pcmk_resource_t *rsc, void *user_data) rsc 41 lib/common/tests/nodes/pcmk_foreach_active_resource_test.c assert_string_equal(rsc->id, expected_id); rsc 2586 lib/lrmd/lrmd_client.c lrmd__metadata_async(const lrmd_rsc_info_t *rsc, rsc 2598 lib/lrmd/lrmd_client.c if ((rsc == NULL) || (rsc->standard == NULL) || (rsc->type == NULL)) { rsc 2607 lib/lrmd/lrmd_client.c if (strcmp(rsc->standard, PCMK_RESOURCE_CLASS_STONITH) == 0) { rsc 2608 lib/lrmd/lrmd_client.c return stonith__metadata_async(rsc->type, rsc 2613 lib/lrmd/lrmd_client.c action = services__create_resource_action(pcmk__s(rsc->id, rsc->type), rsc 2614 lib/lrmd/lrmd_client.c rsc->standard, rsc->provider, rsc 2615 lib/lrmd/lrmd_client.c rsc->type, rsc 90 lib/pacemaker/libpacemaker_private.h pcmk_node_t *(*assign)(pcmk_resource_t *rsc, const pcmk_node_t *prefer, rsc 99 lib/pacemaker/libpacemaker_private.h void (*create_actions)(pcmk_resource_t *rsc); rsc 110 lib/pacemaker/libpacemaker_private.h bool (*create_probe)(pcmk_resource_t *rsc, pcmk_node_t *node); rsc 118 lib/pacemaker/libpacemaker_private.h void (*internal_constraints)(pcmk_resource_t *rsc); rsc 157 lib/pacemaker/libpacemaker_private.h GList *(*colocated_resources)(const pcmk_resource_t *rsc, rsc 178 lib/pacemaker/libpacemaker_private.h void (*with_this_colocations)(const pcmk_resource_t *rsc, rsc 200 lib/pacemaker/libpacemaker_private.h void (*this_with_colocations)(const pcmk_resource_t *rsc, rsc 246 lib/pacemaker/libpacemaker_private.h void (*apply_location)(pcmk_resource_t *rsc, pcmk__location_t *location); rsc 297 lib/pacemaker/libpacemaker_private.h void (*output_actions)(pcmk_resource_t *rsc); rsc 305 lib/pacemaker/libpacemaker_private.h void (*add_actions_to_graph)(pcmk_resource_t *rsc); rsc 317 lib/pacemaker/libpacemaker_private.h void (*add_graph_meta)(const pcmk_resource_t *rsc, xmlNode *xml); rsc 334 lib/pacemaker/libpacemaker_private.h void (*add_utilization)(const pcmk_resource_t *rsc, rsc 344 lib/pacemaker/libpacemaker_private.h void (*shutdown_lock)(pcmk_resource_t *rsc); rsc 364 lib/pacemaker/libpacemaker_private.h pcmk_action_t *pcmk__new_cancel_action(pcmk_resource_t *rsc, const char *name, rsc 381 lib/pacemaker/libpacemaker_private.h bool pcmk__check_action_config(pcmk_resource_t *rsc, pcmk_node_t *node, rsc 391 lib/pacemaker/libpacemaker_private.h void pcmk__create_recurring_actions(pcmk_resource_t *rsc); rsc 394 lib/pacemaker/libpacemaker_private.h void pcmk__schedule_cancel(pcmk_resource_t *rsc, const char *call_id, rsc 399 lib/pacemaker/libpacemaker_private.h void pcmk__reschedule_recurring(pcmk_resource_t *rsc, const char *task, rsc 414 lib/pacemaker/libpacemaker_private.h void pcmk__add_rsc_actions_to_graph(pcmk_resource_t *rsc); rsc 427 lib/pacemaker/libpacemaker_private.h void pcmk__order_vs_unfence(const pcmk_resource_t *rsc, pcmk_node_t *node, rsc 459 lib/pacemaker/libpacemaker_private.h const char *id, pcmk_resource_t **rsc, rsc 476 lib/pacemaker/libpacemaker_private.h pcmk__location_t *pcmk__new_location(const char *id, pcmk_resource_t *rsc, rsc 484 lib/pacemaker/libpacemaker_private.h void pcmk__apply_location(pcmk_resource_t *rsc, pcmk__location_t *constraint); rsc 507 lib/pacemaker/libpacemaker_private.h const pcmk_resource_t *rsc) rsc 516 lib/pacemaker/libpacemaker_private.h if (pcmk__is_bundle_node(node) && pcmk__is_bundled(rsc) rsc 517 lib/pacemaker/libpacemaker_private.h && (pe__const_top_resource(rsc, false) == pe__bundled_resource(rsc))) { rsc 520 lib/pacemaker/libpacemaker_private.h } else if (rsc != NULL) { rsc 521 lib/pacemaker/libpacemaker_private.h target = g_hash_table_lookup(rsc->meta, rsc 569 lib/pacemaker/libpacemaker_private.h const pcmk_resource_t *rsc); rsc 573 lib/pacemaker/libpacemaker_private.h const pcmk_resource_t *rsc); rsc 577 lib/pacemaker/libpacemaker_private.h const pcmk_resource_t *rsc); rsc 581 lib/pacemaker/libpacemaker_private.h const pcmk_resource_t *rsc); rsc 584 lib/pacemaker/libpacemaker_private.h GList *pcmk__with_this_colocations(const pcmk_resource_t *rsc); rsc 587 lib/pacemaker/libpacemaker_private.h GList *pcmk__this_with_colocations(const pcmk_resource_t *rsc); rsc 600 lib/pacemaker/libpacemaker_private.h const pcmk_resource_t *rsc); rsc 665 lib/pacemaker/libpacemaker_private.h void pcmk__add_promotion_scores(pcmk_resource_t *rsc); rsc 668 lib/pacemaker/libpacemaker_private.h void pcmk__require_promotion_tickets(pcmk_resource_t *rsc); rsc 671 lib/pacemaker/libpacemaker_private.h void pcmk__set_instance_roles(pcmk_resource_t *rsc); rsc 677 lib/pacemaker/libpacemaker_private.h void pcmk__promotable_restart_ordering(pcmk_resource_t *rsc); rsc 704 lib/pacemaker/libpacemaker_private.h bool pcmk__rsc_corresponds_to_guest(const pcmk_resource_t *rsc, rsc 711 lib/pacemaker/libpacemaker_private.h void pcmk__substitute_remote_addr(pcmk_resource_t *rsc, GHashTable *params); rsc 721 lib/pacemaker/libpacemaker_private.h pcmk_node_t *pcmk__primitive_assign(pcmk_resource_t *rsc, rsc 726 lib/pacemaker/libpacemaker_private.h void pcmk__primitive_create_actions(pcmk_resource_t *rsc); rsc 729 lib/pacemaker/libpacemaker_private.h void pcmk__primitive_internal_constraints(pcmk_resource_t *rsc); rsc 742 lib/pacemaker/libpacemaker_private.h void pcmk__with_primitive_colocations(const pcmk_resource_t *rsc, rsc 747 lib/pacemaker/libpacemaker_private.h void pcmk__primitive_with_colocations(const pcmk_resource_t *rsc, rsc 752 lib/pacemaker/libpacemaker_private.h void pcmk__schedule_cleanup(pcmk_resource_t *rsc, const pcmk_node_t *node, rsc 756 lib/pacemaker/libpacemaker_private.h void pcmk__primitive_add_graph_meta(const pcmk_resource_t *rsc, xmlNode *xml); rsc 759 lib/pacemaker/libpacemaker_private.h void pcmk__primitive_add_utilization(const pcmk_resource_t *rsc, rsc 764 lib/pacemaker/libpacemaker_private.h void pcmk__primitive_shutdown_lock(pcmk_resource_t *rsc); rsc 770 lib/pacemaker/libpacemaker_private.h pcmk_node_t *pcmk__group_assign(pcmk_resource_t *rsc, const pcmk_node_t *prefer, rsc 774 lib/pacemaker/libpacemaker_private.h void pcmk__group_create_actions(pcmk_resource_t *rsc); rsc 777 lib/pacemaker/libpacemaker_private.h void pcmk__group_internal_constraints(pcmk_resource_t *rsc); rsc 786 lib/pacemaker/libpacemaker_private.h void pcmk__with_group_colocations(const pcmk_resource_t *rsc, rsc 791 lib/pacemaker/libpacemaker_private.h void pcmk__group_with_colocations(const pcmk_resource_t *rsc, rsc 804 lib/pacemaker/libpacemaker_private.h void pcmk__group_apply_location(pcmk_resource_t *rsc, rsc 820 lib/pacemaker/libpacemaker_private.h GList *pcmk__group_colocated_resources(const pcmk_resource_t *rsc, rsc 825 lib/pacemaker/libpacemaker_private.h void pcmk__group_add_utilization(const pcmk_resource_t *rsc, rsc 830 lib/pacemaker/libpacemaker_private.h void pcmk__group_shutdown_lock(pcmk_resource_t *rsc); rsc 836 lib/pacemaker/libpacemaker_private.h pcmk_node_t *pcmk__clone_assign(pcmk_resource_t *rsc, const pcmk_node_t *prefer, rsc 840 lib/pacemaker/libpacemaker_private.h void pcmk__clone_create_actions(pcmk_resource_t *rsc); rsc 843 lib/pacemaker/libpacemaker_private.h bool pcmk__clone_create_probe(pcmk_resource_t *rsc, pcmk_node_t *node); rsc 846 lib/pacemaker/libpacemaker_private.h void pcmk__clone_internal_constraints(pcmk_resource_t *rsc); rsc 855 lib/pacemaker/libpacemaker_private.h void pcmk__with_clone_colocations(const pcmk_resource_t *rsc, rsc 860 lib/pacemaker/libpacemaker_private.h void pcmk__clone_with_colocations(const pcmk_resource_t *rsc, rsc 865 lib/pacemaker/libpacemaker_private.h void pcmk__clone_apply_location(pcmk_resource_t *rsc, rsc 873 lib/pacemaker/libpacemaker_private.h void pcmk__clone_add_actions_to_graph(pcmk_resource_t *rsc); rsc 876 lib/pacemaker/libpacemaker_private.h void pcmk__clone_add_graph_meta(const pcmk_resource_t *rsc, xmlNode *xml); rsc 879 lib/pacemaker/libpacemaker_private.h void pcmk__clone_add_utilization(const pcmk_resource_t *rsc, rsc 884 lib/pacemaker/libpacemaker_private.h void pcmk__clone_shutdown_lock(pcmk_resource_t *rsc); rsc 889 lib/pacemaker/libpacemaker_private.h pcmk_node_t *pcmk__bundle_assign(pcmk_resource_t *rsc, rsc 893 lib/pacemaker/libpacemaker_private.h void pcmk__bundle_create_actions(pcmk_resource_t *rsc); rsc 896 lib/pacemaker/libpacemaker_private.h bool pcmk__bundle_create_probe(pcmk_resource_t *rsc, pcmk_node_t *node); rsc 899 lib/pacemaker/libpacemaker_private.h void pcmk__bundle_internal_constraints(pcmk_resource_t *rsc); rsc 908 lib/pacemaker/libpacemaker_private.h void pcmk__with_bundle_colocations(const pcmk_resource_t *rsc, rsc 913 lib/pacemaker/libpacemaker_private.h void pcmk__bundle_with_colocations(const pcmk_resource_t *rsc, rsc 918 lib/pacemaker/libpacemaker_private.h void pcmk__bundle_apply_location(pcmk_resource_t *rsc, rsc 926 lib/pacemaker/libpacemaker_private.h void pcmk__output_bundle_actions(pcmk_resource_t *rsc); rsc 929 lib/pacemaker/libpacemaker_private.h void pcmk__bundle_add_actions_to_graph(pcmk_resource_t *rsc); rsc 932 lib/pacemaker/libpacemaker_private.h void pcmk__bundle_add_utilization(const pcmk_resource_t *rsc, rsc 937 lib/pacemaker/libpacemaker_private.h void pcmk__bundle_shutdown_lock(pcmk_resource_t *rsc); rsc 947 lib/pacemaker/libpacemaker_private.h void pcmk__create_instance_actions(pcmk_resource_t *rsc, GList *instances); rsc 956 lib/pacemaker/libpacemaker_private.h const pcmk_resource_t *rsc, rsc 1014 lib/pacemaker/libpacemaker_private.h void pcmk__copy_node_tables(const pcmk_resource_t *rsc, GHashTable **copy); rsc 1017 lib/pacemaker/libpacemaker_private.h void pcmk__restore_node_tables(pcmk_resource_t *rsc, GHashTable *backup); rsc 1026 lib/pacemaker/libpacemaker_private.h pcmk_node_t *pcmk__top_allowed_node(const pcmk_resource_t *rsc, rsc 1036 lib/pacemaker/libpacemaker_private.h bool pcmk__rsc_agent_changed(pcmk_resource_t *rsc, pcmk_node_t *node, rsc 1044 lib/pacemaker/libpacemaker_private.h GList *pcmk__colocated_resources(const pcmk_resource_t *rsc, rsc 1049 lib/pacemaker/libpacemaker_private.h void pcmk__noop_add_graph_meta(const pcmk_resource_t *rsc, xmlNode *xml); rsc 1052 lib/pacemaker/libpacemaker_private.h void pcmk__output_resource_actions(pcmk_resource_t *rsc); rsc 1055 lib/pacemaker/libpacemaker_private.h bool pcmk__assign_resource(pcmk_resource_t *rsc, pcmk_node_t *node, bool force, rsc 1059 lib/pacemaker/libpacemaker_private.h void pcmk__unassign_resource(pcmk_resource_t *rsc); rsc 1062 lib/pacemaker/libpacemaker_private.h bool pcmk__threshold_reached(pcmk_resource_t *rsc, const pcmk_node_t *node, rsc 1078 lib/pacemaker/libpacemaker_private.h bool pcmk__probe_rsc_on_node(pcmk_resource_t *rsc, pcmk_node_t *node); rsc 1092 lib/pacemaker/libpacemaker_private.h void pcmk__create_migration_actions(pcmk_resource_t *rsc, rsc 1097 lib/pacemaker/libpacemaker_private.h bool pcmk__rsc_can_migrate(const pcmk_resource_t *rsc, rsc 1111 lib/pacemaker/libpacemaker_private.h const pcmk_resource_t *rsc); rsc 1115 lib/pacemaker/libpacemaker_private.h const pcmk_resource_t *rsc); rsc 1118 lib/pacemaker/libpacemaker_private.h const pcmk_node_t *pcmk__ban_insufficient_capacity(pcmk_resource_t *rsc); rsc 1121 lib/pacemaker/libpacemaker_private.h void pcmk__create_utilization_constraints(pcmk_resource_t *rsc, rsc 216 lib/pacemaker/pcmk_graph_consumer.c pcmk__assert((fns != NULL) && (fns->rsc != NULL) && (fns->cluster != NULL) rsc 309 lib/pacemaker/pcmk_graph_consumer.c return graph_fns->rsc(graph, action); rsc 162 lib/pacemaker/pcmk_graph_producer.c } else if (action->rsc && action->rsc->is_remote_node rsc 175 lib/pacemaker/pcmk_graph_producer.c if ((input->rsc != NULL) rsc 176 lib/pacemaker/pcmk_graph_producer.c && pcmk__str_eq(action->rsc->id, input->rsc->id, pcmk__str_none) rsc 185 lib/pacemaker/pcmk_graph_producer.c add_node_to_xml_by_id(action->rsc->id, downed); rsc 208 lib/pacemaker/pcmk_graph_producer.c return pcmk__notify_key(action->rsc->clone_name, n_type, n_task); rsc 211 lib/pacemaker/pcmk_graph_producer.c return pcmk__op_key(action->rsc->clone_name, action->cancel_task, rsc 214 lib/pacemaker/pcmk_graph_producer.c return pcmk__op_key(action->rsc->clone_name, action->task, interval_ms); rsc 260 lib/pacemaker/pcmk_graph_producer.c (long long) action->rsc->lock_time); rsc 266 lib/pacemaker/pcmk_graph_producer.c (const char *) action->rsc->xml->name); rsc 267 lib/pacemaker/pcmk_graph_producer.c if (pcmk_is_set(action->rsc->flags, pcmk_rsc_removed) rsc 268 lib/pacemaker/pcmk_graph_producer.c && (action->rsc->clone_name != NULL)) { rsc 278 lib/pacemaker/pcmk_graph_producer.c action->rsc->id, action->rsc->clone_name); rsc 279 lib/pacemaker/pcmk_graph_producer.c crm_xml_add(rsc_xml, PCMK_XA_ID, action->rsc->clone_name); rsc 280 lib/pacemaker/pcmk_graph_producer.c crm_xml_add(rsc_xml, PCMK__XA_LONG_ID, action->rsc->id); rsc 282 lib/pacemaker/pcmk_graph_producer.c } else if (!pcmk_is_set(action->rsc->flags, pcmk_rsc_unique)) { rsc 283 lib/pacemaker/pcmk_graph_producer.c const char *xml_id = pcmk__xe_id(action->rsc->xml); rsc 286 lib/pacemaker/pcmk_graph_producer.c xml_id, action->rsc->id, action->rsc->clone_name); rsc 302 lib/pacemaker/pcmk_graph_producer.c if ((action->rsc->clone_name != NULL) rsc 303 lib/pacemaker/pcmk_graph_producer.c && !pcmk__str_eq(xml_id, action->rsc->clone_name, rsc 305 lib/pacemaker/pcmk_graph_producer.c crm_xml_add(rsc_xml, PCMK__XA_LONG_ID, action->rsc->clone_name); rsc 307 lib/pacemaker/pcmk_graph_producer.c crm_xml_add(rsc_xml, PCMK__XA_LONG_ID, action->rsc->id); rsc 311 lib/pacemaker/pcmk_graph_producer.c pcmk__assert(action->rsc->clone_name == NULL); rsc 312 lib/pacemaker/pcmk_graph_producer.c crm_xml_add(rsc_xml, PCMK_XA_ID, action->rsc->id); rsc 317 lib/pacemaker/pcmk_graph_producer.c g_hash_table_lookup(action->rsc->meta, attr_list[lpc])); rsc 342 lib/pacemaker/pcmk_graph_producer.c if ((action->rsc != NULL) && (action->node != NULL)) { rsc 344 lib/pacemaker/pcmk_graph_producer.c GHashTable *params = pe_rsc_params(action->rsc, action->node, rsc 345 lib/pacemaker/pcmk_graph_producer.c action->rsc->cluster); rsc 347 lib/pacemaker/pcmk_graph_producer.c pcmk__substitute_remote_addr(action->rsc, params); rsc 351 lib/pacemaker/pcmk_graph_producer.c } else if ((action->rsc != NULL) rsc 352 lib/pacemaker/pcmk_graph_producer.c && (action->rsc->variant <= pcmk_rsc_variant_primitive)) { rsc 353 lib/pacemaker/pcmk_graph_producer.c GHashTable *params = pe_rsc_params(action->rsc, NULL, rsc 354 lib/pacemaker/pcmk_graph_producer.c action->rsc->cluster); rsc 360 lib/pacemaker/pcmk_graph_producer.c if (action->rsc != NULL) { rsc 361 lib/pacemaker/pcmk_graph_producer.c pcmk_resource_t *parent = action->rsc; rsc 443 lib/pacemaker/pcmk_graph_producer.c if ((action->rsc != NULL) && (action->rsc->clone_name != NULL)) { rsc 472 lib/pacemaker/pcmk_graph_producer.c if ((action->rsc != NULL) rsc 519 lib/pacemaker/pcmk_graph_producer.c if ((action->rsc != NULL) rsc 520 lib/pacemaker/pcmk_graph_producer.c && !pcmk_is_set(action->rsc->flags, pcmk_rsc_managed) rsc 533 lib/pacemaker/pcmk_graph_producer.c action->uuid, action->id, action->rsc->id); rsc 670 lib/pacemaker/pcmk_graph_producer.c if ((action->rsc != NULL) rsc 674 lib/pacemaker/pcmk_graph_producer.c pcmk_node_t *assigned = action->rsc->allocated_to; rsc 730 lib/pacemaker/pcmk_graph_producer.c } else if (input->action->rsc rsc 731 lib/pacemaker/pcmk_graph_producer.c && input->action->rsc != action->rsc rsc 732 lib/pacemaker/pcmk_graph_producer.c && pcmk_is_set(input->action->rsc->flags, pcmk_rsc_failed) rsc 733 lib/pacemaker/pcmk_graph_producer.c && !pcmk_is_set(input->action->rsc->flags, pcmk_rsc_managed) rsc 735 lib/pacemaker/pcmk_graph_producer.c && pcmk__is_clone(action->rsc)) { rsc 859 lib/pacemaker/pcmk_graph_producer.c if (action->rsc != NULL) { rsc 860 lib/pacemaker/pcmk_graph_producer.c synapse_priority = action->rsc->priority; rsc 977 lib/pacemaker/pcmk_graph_producer.c pcmk__add_rsc_actions_to_graph(pcmk_resource_t *rsc) rsc 981 lib/pacemaker/pcmk_graph_producer.c pcmk__assert(rsc != NULL); rsc 982 lib/pacemaker/pcmk_graph_producer.c pcmk__rsc_trace(rsc, "Adding actions for %s to graph", rsc->id); rsc 985 lib/pacemaker/pcmk_graph_producer.c g_list_foreach(rsc->actions, add_action_to_graph, rsc->cluster); rsc 988 lib/pacemaker/pcmk_graph_producer.c for (iter = rsc->children; iter != NULL; iter = iter->next) { rsc 1059 lib/pacemaker/pcmk_graph_producer.c pcmk_resource_t *rsc = (pcmk_resource_t *) iter->data; rsc 1061 lib/pacemaker/pcmk_graph_producer.c pcmk__rsc_trace(rsc, "Processing actions for %s", rsc->id); rsc 1062 lib/pacemaker/pcmk_graph_producer.c rsc->cmds->add_actions_to_graph(rsc); rsc 1072 lib/pacemaker/pcmk_graph_producer.c if ((action->rsc != NULL) rsc 1075 lib/pacemaker/pcmk_graph_producer.c && !pcmk_is_set(action->rsc->flags, pcmk_rsc_maintenance) rsc 1085 lib/pacemaker/pcmk_graph_producer.c const bool managed = pcmk_is_set(action->rsc->flags, rsc 1087 lib/pacemaker/pcmk_graph_producer.c const bool failed = pcmk_is_set(action->rsc->flags, rsc 1092 lib/pacemaker/pcmk_graph_producer.c pcmk__node_name(action->node), action->rsc->id, rsc 570 lib/pacemaker/pcmk_injections.c const pcmk_resource_t *rsc = NULL; rsc 586 lib/pacemaker/pcmk_injections.c rsc = pe_find_resource(scheduler->resources, resource); rsc 587 lib/pacemaker/pcmk_injections.c if (rsc == NULL) { rsc 592 lib/pacemaker/pcmk_injections.c rclass = crm_element_value(rsc->xml, PCMK_XA_CLASS); rsc 593 lib/pacemaker/pcmk_injections.c rtype = crm_element_value(rsc->xml, PCMK_XA_TYPE); rsc 594 lib/pacemaker/pcmk_injections.c rprovider = crm_element_value(rsc->xml, PCMK_XA_PROVIDER); rsc 24 lib/pacemaker/pcmk_output.c colocations_header(pcmk_resource_t *rsc, pcmk__colocation_t *cons, rsc 30 lib/pacemaker/pcmk_output.c rsc->id, pcmk_readable_score(cons->score), rsc 36 lib/pacemaker/pcmk_output.c rsc->id, pcmk_readable_score(cons->score), rsc 43 lib/pacemaker/pcmk_output.c colocations_xml_node(pcmk__output_t *out, pcmk_resource_t *rsc, rsc 68 lib/pacemaker/pcmk_output.c do_locations_list_xml(pcmk__output_t *out, pcmk_resource_t *rsc, rsc 72 lib/pacemaker/pcmk_output.c GList *list = rsc->rsc_location; rsc 89 lib/pacemaker/pcmk_output.c PCMK_XA_RSC, rsc->id, rsc 111 lib/pacemaker/pcmk_output.c pcmk_resource_t *rsc = va_arg(args, pcmk_resource_t *); rsc 134 lib/pacemaker/pcmk_output.c len = strlen(rsc->id); rsc 139 lib/pacemaker/pcmk_output.c if ((rsc->role > pcmk_role_started) rsc 140 lib/pacemaker/pcmk_output.c || (rsc->next_role > pcmk_role_unpromoted)) { rsc 148 lib/pacemaker/pcmk_output.c if (rsc->role == rsc->next_role) { rsc 154 lib/pacemaker/pcmk_output.c details = crm_strdup_printf("%s -> %s %s", pcmk_role_text(rsc->role), rsc 155 lib/pacemaker/pcmk_output.c pcmk_role_text(rsc->next_role), rsc 164 lib/pacemaker/pcmk_output.c details = crm_strdup_printf("%s %s", pcmk_role_text(rsc->role), rsc 173 lib/pacemaker/pcmk_output.c details = crm_strdup_printf("%s %s", pcmk_role_text(rsc->role), rsc 184 lib/pacemaker/pcmk_output.c pcmk_role_text(rsc->role)); rsc 193 lib/pacemaker/pcmk_output.c details = crm_strdup_printf("%s -> %s %s", pcmk_role_text(rsc->role), rsc 194 lib/pacemaker/pcmk_output.c pcmk_role_text(rsc->next_role), rsc 200 lib/pacemaker/pcmk_output.c pcmk_role_text(rsc->role), rsc 202 lib/pacemaker/pcmk_output.c pcmk_role_text(rsc->next_role), rsc 224 lib/pacemaker/pcmk_output.c change, rsc_width, rsc->id, detail_width, details, rsc 239 lib/pacemaker/pcmk_output.c pcmk_resource_t *rsc = va_arg(args, pcmk_resource_t *); rsc 259 lib/pacemaker/pcmk_output.c if ((rsc->role > pcmk_role_started) rsc 260 lib/pacemaker/pcmk_output.c || (rsc->next_role > pcmk_role_unpromoted)) { rsc 268 lib/pacemaker/pcmk_output.c if (rsc->role == rsc->next_role) { rsc 275 lib/pacemaker/pcmk_output.c PCMK_XA_RESOURCE, rsc->id, rsc 282 lib/pacemaker/pcmk_output.c PCMK_XA_ROLE, pcmk_role_text(rsc->role), rsc 283 lib/pacemaker/pcmk_output.c PCMK_XA_NEXT_ROLE, pcmk_role_text(rsc->next_role), rsc 294 lib/pacemaker/pcmk_output.c PCMK_XA_ROLE, pcmk_role_text(rsc->role), rsc 305 lib/pacemaker/pcmk_output.c PCMK_XA_ROLE, pcmk_role_text(rsc->role), rsc 318 lib/pacemaker/pcmk_output.c PCMK_XA_ROLE, pcmk_role_text(rsc->role), rsc 331 lib/pacemaker/pcmk_output.c PCMK_XA_ROLE, pcmk_role_text(rsc->role), rsc 332 lib/pacemaker/pcmk_output.c PCMK_XA_NEXT_ROLE, pcmk_role_text(rsc->next_role), rsc 339 lib/pacemaker/pcmk_output.c PCMK_XA_ROLE, pcmk_role_text(rsc->role), rsc 341 lib/pacemaker/pcmk_output.c PCMK_XA_NEXT_ROLE, pcmk_role_text(rsc->next_role), rsc 367 lib/pacemaker/pcmk_output.c pcmk_resource_t *rsc = va_arg(args, pcmk_resource_t *); rsc 372 lib/pacemaker/pcmk_output.c if (pcmk_is_set(rsc->flags, pcmk_rsc_detect_loop)) { rsc 379 lib/pacemaker/pcmk_output.c pcmk__set_rsc_flags(rsc, pcmk_rsc_detect_loop); rsc 380 lib/pacemaker/pcmk_output.c for (GList *lpc = rsc->rsc_cons; lpc != NULL; lpc = lpc->next) { rsc 385 lib/pacemaker/pcmk_output.c "Resources %s is colocated with", rsc->id); rsc 416 lib/pacemaker/pcmk_output.c pcmk_resource_t *rsc = va_arg(args, pcmk_resource_t *); rsc 421 lib/pacemaker/pcmk_output.c if (pcmk_is_set(rsc->flags, pcmk_rsc_detect_loop)) { rsc 428 lib/pacemaker/pcmk_output.c pcmk__set_rsc_flags(rsc, pcmk_rsc_detect_loop); rsc 429 lib/pacemaker/pcmk_output.c for (GList *lpc = rsc->rsc_cons; lpc != NULL; lpc = lpc->next) { rsc 452 lib/pacemaker/pcmk_output.c pcmk_resource_t *rsc = va_arg(args, pcmk_resource_t *); rsc 457 lib/pacemaker/pcmk_output.c if (pcmk_is_set(rsc->flags, pcmk_rsc_detect_loop)) { rsc 465 lib/pacemaker/pcmk_output.c pcmk__set_rsc_flags(rsc, pcmk_rsc_detect_loop); rsc 466 lib/pacemaker/pcmk_output.c for (GList *lpc = rsc->rsc_cons_lhs; lpc != NULL; lpc = lpc->next) { rsc 471 lib/pacemaker/pcmk_output.c rsc->id); rsc 502 lib/pacemaker/pcmk_output.c pcmk_resource_t *rsc = va_arg(args, pcmk_resource_t *); rsc 507 lib/pacemaker/pcmk_output.c if (pcmk_is_set(rsc->flags, pcmk_rsc_detect_loop)) { rsc 515 lib/pacemaker/pcmk_output.c pcmk__set_rsc_flags(rsc, pcmk_rsc_detect_loop); rsc 516 lib/pacemaker/pcmk_output.c for (GList *lpc = rsc->rsc_cons_lhs; lpc != NULL; lpc = lpc->next) { rsc 539 lib/pacemaker/pcmk_output.c pcmk_resource_t *rsc = va_arg(args, pcmk_resource_t *); rsc 542 lib/pacemaker/pcmk_output.c GList *list = rsc->rsc_location; rsc 557 lib/pacemaker/pcmk_output.c rsc->id); rsc 568 lib/pacemaker/pcmk_output.c pcmk_resource_t *rsc = va_arg(args, pcmk_resource_t *); rsc 569 lib/pacemaker/pcmk_output.c return do_locations_list_xml(out, rsc, true); rsc 577 lib/pacemaker/pcmk_output.c pcmk_resource_t *rsc = va_arg(args, pcmk_resource_t *); rsc 581 lib/pacemaker/pcmk_output.c pcmk__unpack_constraints(rsc->cluster); rsc 585 lib/pacemaker/pcmk_output.c rsc = uber_parent(rsc); rsc 588 lib/pacemaker/pcmk_output.c out->message(out, "locations-list", rsc); rsc 590 lib/pacemaker/pcmk_output.c pe__clear_resource_flags_on_all(rsc->cluster, pcmk_rsc_detect_loop); rsc 591 lib/pacemaker/pcmk_output.c out->message(out, "rscs-colocated-with-list", rsc, recursive); rsc 593 lib/pacemaker/pcmk_output.c pe__clear_resource_flags_on_all(rsc->cluster, pcmk_rsc_detect_loop); rsc 594 lib/pacemaker/pcmk_output.c out->message(out, "rsc-is-colocated-with-list", rsc, recursive); rsc 603 lib/pacemaker/pcmk_output.c pcmk_resource_t *rsc = va_arg(args, pcmk_resource_t *); rsc 607 lib/pacemaker/pcmk_output.c pcmk__unpack_constraints(rsc->cluster); rsc 611 lib/pacemaker/pcmk_output.c rsc = uber_parent(rsc); rsc 615 lib/pacemaker/pcmk_output.c do_locations_list_xml(out, rsc, false); rsc 617 lib/pacemaker/pcmk_output.c pe__clear_resource_flags_on_all(rsc->cluster, pcmk_rsc_detect_loop); rsc 618 lib/pacemaker/pcmk_output.c out->message(out, "rscs-colocated-with-list", rsc, recursive); rsc 620 lib/pacemaker/pcmk_output.c pe__clear_resource_flags_on_all(rsc->cluster, pcmk_rsc_detect_loop); rsc 621 lib/pacemaker/pcmk_output.c out->message(out, "rsc-is-colocated-with-list", rsc, recursive); rsc 961 lib/pacemaker/pcmk_output.c const pcmk_resource_t *rsc = va_arg(args, const pcmk_resource_t *); rsc 980 lib/pacemaker/pcmk_output.c if ((rsc != NULL) && (rsc->id != NULL)) { rsc 981 lib/pacemaker/pcmk_output.c rsc_desc = rsc->id; rsc 1029 lib/pacemaker/pcmk_output.c const pcmk_resource_t *rsc = va_arg(args, const pcmk_resource_t *); rsc 1039 lib/pacemaker/pcmk_output.c PCMK_XA_RESOURCE, pcmk__s(rsc->id, ""), rsc 1062 lib/pacemaker/pcmk_output.c __func__, lineno, rsc->id); \ rsc 1076 lib/pacemaker/pcmk_output.c pcmk_resource_t *rsc = va_arg(args, pcmk_resource_t *); rsc 1092 lib/pacemaker/pcmk_output.c if (!pcmk_is_set(rsc->flags, pcmk_rsc_managed) rsc 1094 lib/pacemaker/pcmk_output.c const bool managed = pcmk_is_set(rsc->flags, pcmk_rsc_managed); rsc 1096 lib/pacemaker/pcmk_output.c pcmk__rsc_info(rsc, "Leave %s\t(%s%s)", rsc 1097 lib/pacemaker/pcmk_output.c rsc->id, pcmk_role_text(rsc->role), rsc 1105 lib/pacemaker/pcmk_output.c possible_matches = pe__resource_actions(rsc, next, PCMK_ACTION_START, rsc 1118 lib/pacemaker/pcmk_output.c possible_matches = pe__resource_actions(rsc, start_node, PCMK_ACTION_STOP, rsc 1123 lib/pacemaker/pcmk_output.c } else if (pcmk_is_set(rsc->flags, pcmk_rsc_stop_unexpected)) { rsc 1128 lib/pacemaker/pcmk_output.c possible_matches = pe__resource_actions(rsc, NULL, PCMK_ACTION_STOP, rsc 1136 lib/pacemaker/pcmk_output.c possible_matches = pe__resource_actions(rsc, next, PCMK_ACTION_PROMOTE, rsc 1143 lib/pacemaker/pcmk_output.c possible_matches = pe__resource_actions(rsc, next, PCMK_ACTION_DEMOTE, rsc 1150 lib/pacemaker/pcmk_output.c if (rsc->role == rsc->next_role) { rsc 1155 lib/pacemaker/pcmk_output.c possible_matches = pe__resource_actions(rsc, next, rsc 1164 lib/pacemaker/pcmk_output.c rc = out->message(out, "rsc-action-item", "Migrate", rsc, current, rsc 1167 lib/pacemaker/pcmk_output.c } else if (pcmk_is_set(rsc->flags, pcmk_rsc_reload)) { rsc 1168 lib/pacemaker/pcmk_output.c rc = out->message(out, "rsc-action-item", "Reload", rsc, current, rsc 1176 lib/pacemaker/pcmk_output.c rc = out->message(out, "rsc-action-item", "Re-promote", rsc, rsc 1179 lib/pacemaker/pcmk_output.c pcmk__rsc_info(rsc, "Leave %s\t(%s %s)", rsc->id, rsc 1180 lib/pacemaker/pcmk_output.c pcmk_role_text(rsc->role), rsc 1190 lib/pacemaker/pcmk_output.c rc = out->message(out, "rsc-action-item", "Stop", rsc, current, rsc 1195 lib/pacemaker/pcmk_output.c const bool failed = pcmk_is_set(rsc->flags, pcmk_rsc_failed); rsc 1198 lib/pacemaker/pcmk_output.c (failed? "Recover" : "Move"), rsc, current, next, rsc 1201 lib/pacemaker/pcmk_output.c } else if (pcmk_is_set(rsc->flags, pcmk_rsc_failed)) { rsc 1202 lib/pacemaker/pcmk_output.c rc = out->message(out, "rsc-action-item", "Recover", rsc, current, rsc 1207 lib/pacemaker/pcmk_output.c rc = out->message(out, "rsc-action-item", "Restart", rsc, current, rsc 1222 lib/pacemaker/pcmk_output.c && ((rsc->next_role == pcmk_role_stopped) rsc 1226 lib/pacemaker/pcmk_output.c key = stop_key(rsc); rsc 1227 lib/pacemaker/pcmk_output.c for (GList *iter = rsc->running_on; iter != NULL; iter = iter->next) { rsc 1232 lib/pacemaker/pcmk_output.c possible_matches = find_actions(rsc->actions, key, node); rsc 1247 lib/pacemaker/pcmk_output.c if (out->message(out, "rsc-action-item", "Stop", rsc, node, NULL, rsc 1256 lib/pacemaker/pcmk_output.c && pcmk_all_flags_set(rsc->flags, rsc 1259 lib/pacemaker/pcmk_output.c rc = out->message(out, "rsc-action-item", "Recover", rsc, current, rsc 1264 lib/pacemaker/pcmk_output.c rc = out->message(out, "rsc-action-item", "Move", rsc, current, next, rsc 1268 lib/pacemaker/pcmk_output.c } else if (pcmk_is_set(rsc->flags, pcmk_rsc_reload)) { rsc 1269 lib/pacemaker/pcmk_output.c rc = out->message(out, "rsc-action-item", "Reload", rsc, current, next, rsc 1274 lib/pacemaker/pcmk_output.c rc = out->message(out, "rsc-action-item", "Restart", rsc, current, rsc 1278 lib/pacemaker/pcmk_output.c } else if (rsc->role == pcmk_role_promoted) { rsc 1280 lib/pacemaker/pcmk_output.c rc = out->message(out, "rsc-action-item", "Demote", rsc, current, rsc 1283 lib/pacemaker/pcmk_output.c } else if (rsc->next_role == pcmk_role_promoted) { rsc 1285 lib/pacemaker/pcmk_output.c rc = out->message(out, "rsc-action-item", "Promote", rsc, current, rsc 1288 lib/pacemaker/pcmk_output.c } else if ((rsc->role == pcmk_role_stopped) rsc 1289 lib/pacemaker/pcmk_output.c && (rsc->next_role > pcmk_role_stopped)) { rsc 1290 lib/pacemaker/pcmk_output.c rc = out->message(out, "rsc-action-item", "Start", rsc, current, next, rsc 1392 lib/pacemaker/pcmk_output.c xmlNodePtr rsc = va_arg(args, xmlNodePtr); rsc 1398 lib/pacemaker/pcmk_output.c if (rsc != NULL) { rsc 1400 lib/pacemaker/pcmk_output.c task, pcmk__xe_id(rsc), node); rsc 1415 lib/pacemaker/pcmk_output.c xmlNodePtr rsc = va_arg(args, xmlNodePtr); rsc 1428 lib/pacemaker/pcmk_output.c if (rsc) { rsc 1429 lib/pacemaker/pcmk_output.c crm_xml_add(xml_node, PCMK_XA_ID, pcmk__xe_id(rsc)); rsc 1723 lib/pacemaker/pcmk_output.c const char *rsc = va_arg(args, const char *); rsc 1734 lib/pacemaker/pcmk_output.c rsc, operation, interval_ms, node); rsc 1737 lib/pacemaker/pcmk_output.c rsc, operation, node); rsc 1748 lib/pacemaker/pcmk_output.c const char *rsc = va_arg(args, const char *); rsc 1760 lib/pacemaker/pcmk_output.c PCMK_XA_RESOURCE, rsc, rsc 2488 lib/pacemaker/pcmk_output.c const char *rsc = crm_element_value(node, PCMK_XA_RSC); rsc 2491 lib/pacemaker/pcmk_output.c PCMK_XA_ID, rsc, NULL); rsc 33 lib/pacemaker/pcmk_resource.c best_op(const pcmk_resource_t *rsc, const pcmk_node_t *node) rsc 44 lib/pacemaker/pcmk_resource.c xpath = crm_strdup_printf(XPATH_OP_HISTORY, node->details->uname, rsc->id); rsc 45 lib/pacemaker/pcmk_resource.c history = get_xpath_object(xpath, rsc->cluster->input, LOG_NEVER); rsc 196 lib/pacemaker/pcmk_resource.c pcmk__resource_digests(pcmk__output_t *out, pcmk_resource_t *rsc, rsc 205 lib/pacemaker/pcmk_resource.c if ((out == NULL) || (rsc == NULL) || (node == NULL)) { rsc 208 lib/pacemaker/pcmk_resource.c if (!pcmk__is_primitive(rsc)) { rsc 214 lib/pacemaker/pcmk_resource.c xml_op = best_op(rsc, node); rsc 227 lib/pacemaker/pcmk_resource.c digests = pe__calculate_digests(rsc, task, &interval_ms, node, xml_op, rsc 228 lib/pacemaker/pcmk_resource.c overrides, true, rsc->cluster); rsc 229 lib/pacemaker/pcmk_resource.c rc = out->message(out, "digests", rsc, node, task, interval_ms, digests); rsc 236 lib/pacemaker/pcmk_resource.c pcmk_resource_digests(xmlNodePtr *xml, pcmk_resource_t *rsc, rsc 247 lib/pacemaker/pcmk_resource.c rc = pcmk__resource_digests(out, rsc, node, overrides); rsc 38 lib/pacemaker/pcmk_sched_actions.c if (action->rsc == NULL) { rsc 46 lib/pacemaker/pcmk_sched_actions.c flags = action->rsc->cmds->action_flags(action, NULL); rsc 47 lib/pacemaker/pcmk_sched_actions.c if ((node == NULL) || !pcmk__is_clone(action->rsc)) { rsc 57 lib/pacemaker/pcmk_sched_actions.c flags = action->rsc->cmds->action_flags(action, node); rsc 68 lib/pacemaker/pcmk_sched_actions.c pcmk__set_raw_action_flags(flags, action->rsc->id, rsc 182 lib/pacemaker/pcmk_sched_actions.c pcmk_resource_t *rsc = action->rsc; rsc 184 lib/pacemaker/pcmk_sched_actions.c if ((rsc != NULL) && (rsc->variant >= pcmk_rsc_variant_group) rsc 186 lib/pacemaker/pcmk_sched_actions.c char *uuid = action_uuid_for_ordering(action->uuid, rsc); rsc 188 lib/pacemaker/pcmk_sched_actions.c result = find_first_action(rsc->actions, uuid, NULL, NULL); rsc 191 lib/pacemaker/pcmk_sched_actions.c "remapped action", action->uuid, uuid, rsc->id); rsc 219 lib/pacemaker/pcmk_sched_actions.c update(pcmk_resource_t *rsc, pcmk_action_t *first, pcmk_action_t *then, rsc 223 lib/pacemaker/pcmk_sched_actions.c return rsc->cmds->update_ordered_actions(first, then, node, flags, filter, rsc 265 lib/pacemaker/pcmk_sched_actions.c pcmk__rsc_trace(then->rsc, rsc 273 lib/pacemaker/pcmk_sched_actions.c if (then->rsc != NULL) { rsc 274 lib/pacemaker/pcmk_sched_actions.c changed |= update(then->rsc, first, then, node, rsc 283 lib/pacemaker/pcmk_sched_actions.c pcmk__rsc_trace(then->rsc, rsc 290 lib/pacemaker/pcmk_sched_actions.c && (then->rsc != NULL)) { rsc 294 lib/pacemaker/pcmk_sched_actions.c changed |= update(then->rsc, first, then, node, first_flags, restart, rsc 296 lib/pacemaker/pcmk_sched_actions.c pcmk__rsc_trace(then->rsc, rsc 303 lib/pacemaker/pcmk_sched_actions.c if (first->rsc != NULL) { rsc 304 lib/pacemaker/pcmk_sched_actions.c changed |= update(first->rsc, first, then, node, first_flags, rsc 312 lib/pacemaker/pcmk_sched_actions.c pcmk__rsc_trace(then->rsc, rsc 319 lib/pacemaker/pcmk_sched_actions.c if (then->rsc != NULL) { rsc 320 lib/pacemaker/pcmk_sched_actions.c changed |= update(then->rsc, first, then, node, rsc 325 lib/pacemaker/pcmk_sched_actions.c pcmk__rsc_trace(then->rsc, rsc 333 lib/pacemaker/pcmk_sched_actions.c if (then->rsc != NULL) { rsc 334 lib/pacemaker/pcmk_sched_actions.c changed |= update(then->rsc, first, then, node, first_flags, rsc 352 lib/pacemaker/pcmk_sched_actions.c pcmk__rsc_trace(then->rsc, "%s then %s: %s after pcmk__ar_min_runnable", rsc 358 lib/pacemaker/pcmk_sched_actions.c && (then->rsc != NULL)) { rsc 361 lib/pacemaker/pcmk_sched_actions.c && (first->rsc != NULL) && (first->rsc->running_on != NULL)) { rsc 363 lib/pacemaker/pcmk_sched_actions.c pcmk__rsc_trace(then->rsc, rsc 368 lib/pacemaker/pcmk_sched_actions.c changed |= update(then->rsc, first, then, node, first_flags, rsc 372 lib/pacemaker/pcmk_sched_actions.c pcmk__rsc_trace(then->rsc, rsc 379 lib/pacemaker/pcmk_sched_actions.c if (then->rsc != NULL) { rsc 380 lib/pacemaker/pcmk_sched_actions.c changed |= update(then->rsc, first, then, node, first_flags, rsc 390 lib/pacemaker/pcmk_sched_actions.c pcmk__rsc_trace(then->rsc, rsc 397 lib/pacemaker/pcmk_sched_actions.c if (then->rsc != NULL) { rsc 398 lib/pacemaker/pcmk_sched_actions.c changed |= update(then->rsc, first, then, node, first_flags, rsc 402 lib/pacemaker/pcmk_sched_actions.c pcmk__rsc_trace(then->rsc, rsc 410 lib/pacemaker/pcmk_sched_actions.c if (then->rsc != NULL) { rsc 411 lib/pacemaker/pcmk_sched_actions.c changed |= update(then->rsc, first, then, node, first_flags, rsc 415 lib/pacemaker/pcmk_sched_actions.c pcmk__rsc_trace(then->rsc, rsc 422 lib/pacemaker/pcmk_sched_actions.c if (then->rsc != NULL) { rsc 423 lib/pacemaker/pcmk_sched_actions.c changed |= update(then->rsc, first, then, node, first_flags, rsc 427 lib/pacemaker/pcmk_sched_actions.c pcmk__rsc_trace(then->rsc, "%s then %s: %s after pcmk__ar_ordered", rsc 433 lib/pacemaker/pcmk_sched_actions.c if (then->rsc != NULL) { rsc 434 lib/pacemaker/pcmk_sched_actions.c changed |= update(then->rsc, first, then, node, first_flags, rsc 438 lib/pacemaker/pcmk_sched_actions.c pcmk__rsc_trace(then->rsc, "%s then %s: %s after pcmk__ar_asymmetric", rsc 447 lib/pacemaker/pcmk_sched_actions.c pcmk__rsc_trace(then->rsc, "%s will be in graph because %s is required", rsc 456 lib/pacemaker/pcmk_sched_actions.c pcmk__rsc_trace(then->rsc, "%s will be in graph because %s is required", rsc 465 lib/pacemaker/pcmk_sched_actions.c && (first->rsc != NULL) rsc 466 lib/pacemaker/pcmk_sched_actions.c && !pcmk_is_set(first->rsc->flags, pcmk_rsc_managed) rsc 467 lib/pacemaker/pcmk_sched_actions.c && pcmk_is_set(first->rsc->flags, pcmk_rsc_blocked) rsc 475 lib/pacemaker/pcmk_sched_actions.c pcmk__rsc_trace(then->rsc, rsc 514 lib/pacemaker/pcmk_sched_actions.c pcmk__rsc_trace(then->rsc, "Updating %s %s (%s %s) on %s", rsc 549 lib/pacemaker/pcmk_sched_actions.c if ((first->rsc != NULL) rsc 550 lib/pacemaker/pcmk_sched_actions.c && pcmk__is_group(first->rsc) rsc 553 lib/pacemaker/pcmk_sched_actions.c first_node = first->rsc->fns->location(first->rsc, NULL, FALSE); rsc 555 lib/pacemaker/pcmk_sched_actions.c pcmk__rsc_trace(first->rsc, "Found %s for 'first' %s", rsc 560 lib/pacemaker/pcmk_sched_actions.c if (pcmk__is_group(then->rsc) rsc 563 lib/pacemaker/pcmk_sched_actions.c then_node = then->rsc->fns->location(then->rsc, NULL, FALSE); rsc 565 lib/pacemaker/pcmk_sched_actions.c pcmk__rsc_trace(then->rsc, "Found %s for 'then' %s", rsc 575 lib/pacemaker/pcmk_sched_actions.c pcmk__rsc_trace(then->rsc, rsc 586 lib/pacemaker/pcmk_sched_actions.c if ((first->rsc != NULL) rsc 595 lib/pacemaker/pcmk_sched_actions.c pcmk__clear_rsc_flags(first->rsc, pcmk_rsc_reload); rsc 599 lib/pacemaker/pcmk_sched_actions.c if ((first->rsc != NULL) && (then->rsc != NULL) rsc 600 lib/pacemaker/pcmk_sched_actions.c && (first->rsc != then->rsc) && !is_parent(then->rsc, first->rsc)) { rsc 604 lib/pacemaker/pcmk_sched_actions.c pcmk__rsc_trace(then->rsc, "Ordering %s after %s instead of %s", rsc 608 lib/pacemaker/pcmk_sched_actions.c pcmk__rsc_trace(then->rsc, rsc 635 lib/pacemaker/pcmk_sched_actions.c pcmk__rsc_trace(then->rsc, rsc 684 lib/pacemaker/pcmk_sched_actions.c return (action != NULL) && pcmk__is_primitive(action->rsc); rsc 698 lib/pacemaker/pcmk_sched_actions.c if ((action)->rsc != (reason)->rsc) { \ rsc 722 lib/pacemaker/pcmk_sched_actions.c if ((then->rsc == NULL) rsc 729 lib/pacemaker/pcmk_sched_actions.c enum rsc_role_e then_rsc_role = then->rsc->fns->state(then->rsc, TRUE); rsc 739 lib/pacemaker/pcmk_sched_actions.c && pe__rsc_running_on_only(then->rsc, then->node)) { rsc 784 lib/pacemaker/pcmk_sched_actions.c && pcmk_is_set(then->rsc->flags, pcmk_rsc_managed) rsc 785 lib/pacemaker/pcmk_sched_actions.c && (first->rsc == then->rsc)) { rsc 793 lib/pacemaker/pcmk_sched_actions.c pcmk__rsc_trace(first->rsc, "Handling %s -> %s for %s", rsc 875 lib/pacemaker/pcmk_sched_actions.c && (then->rsc != NULL) && (then->rsc->role == pcmk_role_promoted) rsc 932 lib/pacemaker/pcmk_sched_actions.c pcmk__rsc_trace(then->rsc, rsc 938 lib/pacemaker/pcmk_sched_actions.c if ((then->rsc != NULL) && (then->rsc->parent != NULL)) { rsc 946 lib/pacemaker/pcmk_sched_actions.c pcmk__rsc_trace(first->rsc, rsc 1017 lib/pacemaker/pcmk_sched_actions.c (action->rsc? action->rsc->id : "<none>"), rsc 1308 lib/pacemaker/pcmk_sched_actions.c if ((action == NULL) || (action->rsc == NULL) rsc 1309 lib/pacemaker/pcmk_sched_actions.c || !pcmk__same_node(action->node, action->rsc->lock_node)) { rsc 1407 lib/pacemaker/pcmk_sched_actions.c if (action->rsc != NULL) { rsc 1447 lib/pacemaker/pcmk_sched_actions.c pcmk_resource_t *rsc = (pcmk_resource_t *) iter->data; rsc 1449 lib/pacemaker/pcmk_sched_actions.c rsc->cmds->output_actions(rsc); rsc 1522 lib/pacemaker/pcmk_sched_actions.c force_restart(pcmk_resource_t *rsc, const char *task, guint interval_ms, rsc 1525 lib/pacemaker/pcmk_sched_actions.c char *key = pcmk__op_key(rsc->id, task, interval_ms); rsc 1526 lib/pacemaker/pcmk_sched_actions.c pcmk_action_t *required = custom_action(rsc, key, task, NULL, FALSE, rsc 1527 lib/pacemaker/pcmk_sched_actions.c rsc->cluster); rsc 1530 lib/pacemaker/pcmk_sched_actions.c trigger_unfencing(rsc, node, "Device parameters changed", NULL, rsc 1531 lib/pacemaker/pcmk_sched_actions.c rsc->cluster); rsc 1544 lib/pacemaker/pcmk_sched_actions.c pcmk_resource_t *rsc = data; rsc 1549 lib/pacemaker/pcmk_sched_actions.c if (rsc->variant > pcmk_rsc_variant_primitive) { rsc 1550 lib/pacemaker/pcmk_sched_actions.c g_list_foreach(rsc->children, schedule_reload, user_data); rsc 1556 lib/pacemaker/pcmk_sched_actions.c || !pcmk_is_set(rsc->flags, pcmk_rsc_managed) rsc 1557 lib/pacemaker/pcmk_sched_actions.c || pcmk_is_set(rsc->flags, pcmk_rsc_failed)) { rsc 1558 lib/pacemaker/pcmk_sched_actions.c pcmk__rsc_trace(rsc, "Skip reload of %s:%s%s %s", rsc 1559 lib/pacemaker/pcmk_sched_actions.c rsc->id, rsc 1560 lib/pacemaker/pcmk_sched_actions.c pcmk_is_set(rsc->flags, pcmk_rsc_managed)? "" : " unmanaged", rsc 1561 lib/pacemaker/pcmk_sched_actions.c pcmk_is_set(rsc->flags, pcmk_rsc_failed)? " failed" : "", rsc 1569 lib/pacemaker/pcmk_sched_actions.c if (pcmk_is_set(rsc->flags, pcmk_rsc_start_pending)) { rsc 1570 lib/pacemaker/pcmk_sched_actions.c pcmk__rsc_trace(rsc, rsc 1572 lib/pacemaker/pcmk_sched_actions.c rsc->id); rsc 1573 lib/pacemaker/pcmk_sched_actions.c custom_action(rsc, stop_key(rsc), PCMK_ACTION_STOP, node, FALSE, rsc 1574 lib/pacemaker/pcmk_sched_actions.c rsc->cluster); rsc 1579 lib/pacemaker/pcmk_sched_actions.c pcmk__set_rsc_flags(rsc, pcmk_rsc_reload); rsc 1580 lib/pacemaker/pcmk_sched_actions.c reload = custom_action(rsc, reload_key(rsc), PCMK_ACTION_RELOAD_AGENT, node, rsc 1581 lib/pacemaker/pcmk_sched_actions.c FALSE, rsc->cluster); rsc 1585 lib/pacemaker/pcmk_sched_actions.c pcmk__new_ordering(NULL, NULL, reload, rsc, stop_key(rsc), NULL, rsc 1587 lib/pacemaker/pcmk_sched_actions.c rsc->cluster); rsc 1588 lib/pacemaker/pcmk_sched_actions.c pcmk__new_ordering(NULL, NULL, reload, rsc, demote_key(rsc), NULL, rsc 1590 lib/pacemaker/pcmk_sched_actions.c rsc->cluster); rsc 1608 lib/pacemaker/pcmk_sched_actions.c pcmk__check_action_config(pcmk_resource_t *rsc, pcmk_node_t *node, rsc 1615 lib/pacemaker/pcmk_sched_actions.c CRM_CHECK((rsc != NULL) && (node != NULL) && (xml_op != NULL), rsc 1625 lib/pacemaker/pcmk_sched_actions.c if (pcmk__find_action_config(rsc, task, interval_ms, false) != NULL) { rsc 1626 lib/pacemaker/pcmk_sched_actions.c pcmk__rsc_trace(rsc, rsc 1628 lib/pacemaker/pcmk_sched_actions.c pcmk__readable_interval(interval_ms), task, rsc->id, rsc 1630 lib/pacemaker/pcmk_sched_actions.c } else if (pcmk_is_set(rsc->cluster->flags, rsc 1632 lib/pacemaker/pcmk_sched_actions.c pcmk__schedule_cancel(rsc, rsc 1637 lib/pacemaker/pcmk_sched_actions.c pcmk__rsc_debug(rsc, "%s-interval %s for %s on %s is orphaned", rsc 1638 lib/pacemaker/pcmk_sched_actions.c pcmk__readable_interval(interval_ms), task, rsc->id, rsc 1645 lib/pacemaker/pcmk_sched_actions.c pcmk__readable_interval(interval_ms), task, rsc->id, rsc 1648 lib/pacemaker/pcmk_sched_actions.c digest_data = rsc_action_digest_cmp(rsc, xml_op, node, rsc->cluster); rsc 1650 lib/pacemaker/pcmk_sched_actions.c if (only_sanitized_changed(xml_op, digest_data, rsc->cluster)) { rsc 1651 lib/pacemaker/pcmk_sched_actions.c if (!pcmk__is_daemon && (rsc->cluster->priv != NULL)) { rsc 1652 lib/pacemaker/pcmk_sched_actions.c pcmk__output_t *out = rsc->cluster->priv; rsc 1657 lib/pacemaker/pcmk_sched_actions.c pcmk__readable_interval(interval_ms), task, rsc->id, rsc 1667 lib/pacemaker/pcmk_sched_actions.c force_restart(rsc, task, interval_ms, node); rsc 1680 lib/pacemaker/pcmk_sched_actions.c pcmk__reschedule_recurring(rsc, task, interval_ms, node); rsc 1685 lib/pacemaker/pcmk_sched_actions.c trigger_unfencing(rsc, node, rsc 1687 lib/pacemaker/pcmk_sched_actions.c rsc->cluster); rsc 1689 lib/pacemaker/pcmk_sched_actions.c schedule_reload((gpointer) rsc, (gpointer) node); rsc 1692 lib/pacemaker/pcmk_sched_actions.c pcmk__rsc_trace(rsc, rsc 1695 lib/pacemaker/pcmk_sched_actions.c rsc->id); rsc 1698 lib/pacemaker/pcmk_sched_actions.c force_restart(rsc, task, interval_ms, node); rsc 1747 lib/pacemaker/pcmk_sched_actions.c process_rsc_history(const xmlNode *rsc_entry, pcmk_resource_t *rsc, rsc 1755 lib/pacemaker/pcmk_sched_actions.c if (pcmk_is_set(rsc->flags, pcmk_rsc_removed)) { rsc 1756 lib/pacemaker/pcmk_sched_actions.c if (pcmk__is_anonymous_clone(pe__const_top_resource(rsc, false))) { rsc 1757 lib/pacemaker/pcmk_sched_actions.c pcmk__rsc_trace(rsc, rsc 1760 lib/pacemaker/pcmk_sched_actions.c rsc->id); rsc 1762 lib/pacemaker/pcmk_sched_actions.c pcmk__rsc_trace(rsc, rsc 1764 lib/pacemaker/pcmk_sched_actions.c "clean-up for orphaned resource %s", rsc->id); rsc 1765 lib/pacemaker/pcmk_sched_actions.c pcmk__schedule_cleanup(rsc, node, false); rsc 1770 lib/pacemaker/pcmk_sched_actions.c if (pe_find_node_id(rsc->running_on, node->details->id) == NULL) { rsc 1771 lib/pacemaker/pcmk_sched_actions.c if (pcmk__rsc_agent_changed(rsc, node, rsc_entry, false)) { rsc 1772 lib/pacemaker/pcmk_sched_actions.c pcmk__schedule_cleanup(rsc, node, false); rsc 1774 lib/pacemaker/pcmk_sched_actions.c pcmk__rsc_trace(rsc, rsc 1777 lib/pacemaker/pcmk_sched_actions.c rsc->id, pcmk__node_name(node)); rsc 1781 lib/pacemaker/pcmk_sched_actions.c pcmk__rsc_trace(rsc, "Checking for configuration changes for %s on %s", rsc 1782 lib/pacemaker/pcmk_sched_actions.c rsc->id, pcmk__node_name(node)); rsc 1784 lib/pacemaker/pcmk_sched_actions.c if (pcmk__rsc_agent_changed(rsc, node, rsc_entry, true)) { rsc 1785 lib/pacemaker/pcmk_sched_actions.c pcmk__schedule_cleanup(rsc, node, false); rsc 1807 lib/pacemaker/pcmk_sched_actions.c && (pcmk_is_set(rsc->flags, pcmk_rsc_maintenance) rsc 1810 lib/pacemaker/pcmk_sched_actions.c pcmk__schedule_cancel(rsc, rsc 1823 lib/pacemaker/pcmk_sched_actions.c if (pe__bundle_needs_remote_name(rsc)) { rsc 1831 lib/pacemaker/pcmk_sched_actions.c pe__add_param_check(rsc_op, rsc, node, pcmk__check_active, rsc 1832 lib/pacemaker/pcmk_sched_actions.c rsc->cluster); rsc 1834 lib/pacemaker/pcmk_sched_actions.c } else if (pcmk__check_action_config(rsc, node, rsc_op) rsc 1835 lib/pacemaker/pcmk_sched_actions.c && (pe_get_failcount(node, rsc, NULL, pcmk__fc_effective, rsc 1837 lib/pacemaker/pcmk_sched_actions.c pe__clear_failcount(rsc, node, "action definition changed", rsc 1838 lib/pacemaker/pcmk_sched_actions.c rsc->cluster); rsc 1872 lib/pacemaker/pcmk_sched_actions.c pcmk_resource_t *rsc = (pcmk_resource_t *) iter->data; rsc 1874 lib/pacemaker/pcmk_sched_actions.c if (pcmk__is_primitive(rsc)) { rsc 1875 lib/pacemaker/pcmk_sched_actions.c process_rsc_history(rsc_entry, rsc, node); rsc 111 lib/pacemaker/pcmk_sched_bundle.c pcmk__bundle_assign(pcmk_resource_t *rsc, const pcmk_node_t *prefer, rsc 118 lib/pacemaker/pcmk_sched_bundle.c pcmk__assert(pcmk__is_bundle(rsc)); rsc 120 lib/pacemaker/pcmk_sched_bundle.c pcmk__rsc_trace(rsc, "Assigning bundle %s", rsc->id); rsc 121 lib/pacemaker/pcmk_sched_bundle.c pcmk__set_rsc_flags(rsc, pcmk_rsc_assigning); rsc 123 lib/pacemaker/pcmk_sched_bundle.c pe__show_node_scores(!pcmk_is_set(rsc->cluster->flags, rsc 125 lib/pacemaker/pcmk_sched_bundle.c rsc, __func__, rsc->allowed_nodes, rsc->cluster); rsc 128 lib/pacemaker/pcmk_sched_bundle.c containers = g_list_sort(pe__bundle_containers(rsc), pcmk__cmp_instance); rsc 129 lib/pacemaker/pcmk_sched_bundle.c pcmk__assign_instances(rsc, containers, pe__bundle_max(rsc), rsc 130 lib/pacemaker/pcmk_sched_bundle.c rsc->fns->max_per_node(rsc)); rsc 134 lib/pacemaker/pcmk_sched_bundle.c pe__foreach_bundle_replica(rsc, assign_replica, (void *) &assign_data); rsc 137 lib/pacemaker/pcmk_sched_bundle.c bundled_resource = pe__bundled_resource(rsc); rsc 144 lib/pacemaker/pcmk_sched_bundle.c if (pe__node_is_bundle_instance(rsc, node)) { rsc 153 lib/pacemaker/pcmk_sched_bundle.c pcmk__clear_rsc_flags(rsc, pcmk_rsc_assigning|pcmk_rsc_unassigned); rsc 188 lib/pacemaker/pcmk_sched_bundle.c pcmk__bundle_create_actions(pcmk_resource_t *rsc) rsc 194 lib/pacemaker/pcmk_sched_bundle.c pcmk__assert(pcmk__is_bundle(rsc)); rsc 196 lib/pacemaker/pcmk_sched_bundle.c pe__foreach_bundle_replica(rsc, create_replica_actions, NULL); rsc 198 lib/pacemaker/pcmk_sched_bundle.c containers = pe__bundle_containers(rsc); rsc 199 lib/pacemaker/pcmk_sched_bundle.c pcmk__create_instance_actions(rsc, containers); rsc 202 lib/pacemaker/pcmk_sched_bundle.c bundled_resource = pe__bundled_resource(rsc); rsc 207 lib/pacemaker/pcmk_sched_bundle.c pe__new_rsc_pseudo_action(rsc, PCMK_ACTION_PROMOTE, true, true); rsc 208 lib/pacemaker/pcmk_sched_bundle.c action = pe__new_rsc_pseudo_action(rsc, PCMK_ACTION_PROMOTED, rsc 212 lib/pacemaker/pcmk_sched_bundle.c pe__new_rsc_pseudo_action(rsc, PCMK_ACTION_DEMOTE, true, true); rsc 213 lib/pacemaker/pcmk_sched_bundle.c action = pe__new_rsc_pseudo_action(rsc, PCMK_ACTION_DEMOTED, rsc 297 lib/pacemaker/pcmk_sched_bundle.c pcmk__bundle_internal_constraints(pcmk_resource_t *rsc) rsc 301 lib/pacemaker/pcmk_sched_bundle.c pcmk__assert(pcmk__is_bundle(rsc)); rsc 303 lib/pacemaker/pcmk_sched_bundle.c pe__foreach_bundle_replica(rsc, replica_internal_constraints, rsc); rsc 305 lib/pacemaker/pcmk_sched_bundle.c bundled_resource = pe__bundled_resource(rsc); rsc 311 lib/pacemaker/pcmk_sched_bundle.c pcmk__order_resource_actions(rsc, PCMK_ACTION_START, bundled_resource, rsc 317 lib/pacemaker/pcmk_sched_bundle.c rsc, PCMK_ACTION_RUNNING, rsc 321 lib/pacemaker/pcmk_sched_bundle.c pcmk__order_resource_actions(rsc, PCMK_ACTION_STOP, bundled_resource, rsc 327 lib/pacemaker/pcmk_sched_bundle.c rsc, PCMK_ACTION_STOPPED, rsc 335 lib/pacemaker/pcmk_sched_bundle.c pcmk__promotable_restart_ordering(rsc); rsc 338 lib/pacemaker/pcmk_sched_bundle.c pcmk__order_resource_actions(rsc, PCMK_ACTION_DEMOTE, bundled_resource, rsc 344 lib/pacemaker/pcmk_sched_bundle.c rsc, PCMK_ACTION_DEMOTED, rsc 348 lib/pacemaker/pcmk_sched_bundle.c pcmk__order_resource_actions(rsc, PCMK_ACTION_PROMOTE, rsc 354 lib/pacemaker/pcmk_sched_bundle.c rsc, PCMK_ACTION_PROMOTED, rsc 594 lib/pacemaker/pcmk_sched_bundle.c pcmk__with_bundle_colocations(const pcmk_resource_t *rsc, rsc 599 lib/pacemaker/pcmk_sched_bundle.c pcmk__assert(pcmk__is_bundle(rsc) && (orig_rsc != NULL) && (list != NULL)); rsc 602 lib/pacemaker/pcmk_sched_bundle.c if ((orig_rsc == rsc) rsc 605 lib/pacemaker/pcmk_sched_bundle.c pcmk__add_with_this_list(list, rsc->rsc_cons_lhs, orig_rsc); rsc 612 lib/pacemaker/pcmk_sched_bundle.c bundled_rsc = pe__bundled_resource(rsc); rsc 625 lib/pacemaker/pcmk_sched_bundle.c pcmk__add_with_this_list(list, rsc->rsc_cons_lhs, orig_rsc); rsc 632 lib/pacemaker/pcmk_sched_bundle.c pcmk__add_with_this_list(list, rsc->rsc_cons_lhs, orig_rsc); rsc 638 lib/pacemaker/pcmk_sched_bundle.c pcmk__bundle_with_colocations(const pcmk_resource_t *rsc, rsc 643 lib/pacemaker/pcmk_sched_bundle.c pcmk__assert(pcmk__is_bundle(rsc) && (orig_rsc != NULL) && (list != NULL)); rsc 646 lib/pacemaker/pcmk_sched_bundle.c if ((orig_rsc == rsc) rsc 649 lib/pacemaker/pcmk_sched_bundle.c pcmk__add_this_with_list(list, rsc->rsc_cons, orig_rsc); rsc 656 lib/pacemaker/pcmk_sched_bundle.c bundled_rsc = pe__bundled_resource(rsc); rsc 669 lib/pacemaker/pcmk_sched_bundle.c pcmk__add_this_with_list(list, rsc->rsc_cons, orig_rsc); rsc 676 lib/pacemaker/pcmk_sched_bundle.c pcmk__add_this_with_list(list, rsc->rsc_cons, orig_rsc); rsc 696 lib/pacemaker/pcmk_sched_bundle.c pcmk__assert((action != NULL) && pcmk__is_bundle(action->rsc)); rsc 698 lib/pacemaker/pcmk_sched_bundle.c bundled_resource = pe__bundled_resource(action->rsc); rsc 717 lib/pacemaker/pcmk_sched_bundle.c containers = pe__bundle_containers(action->rsc); rsc 754 lib/pacemaker/pcmk_sched_bundle.c pcmk__bundle_apply_location(pcmk_resource_t *rsc, pcmk__location_t *location) rsc 758 lib/pacemaker/pcmk_sched_bundle.c pcmk__assert((location != NULL) && pcmk__is_bundle(rsc)); rsc 760 lib/pacemaker/pcmk_sched_bundle.c pcmk__apply_location(rsc, location); rsc 761 lib/pacemaker/pcmk_sched_bundle.c pe__foreach_bundle_replica(rsc, apply_location_to_replica, location); rsc 763 lib/pacemaker/pcmk_sched_bundle.c bundled_resource = pe__bundled_resource(rsc); rsc 848 lib/pacemaker/pcmk_sched_bundle.c pcmk__bundle_add_actions_to_graph(pcmk_resource_t *rsc) rsc 852 lib/pacemaker/pcmk_sched_bundle.c pcmk__assert(pcmk__is_bundle(rsc)); rsc 854 lib/pacemaker/pcmk_sched_bundle.c bundled_resource = pe__bundled_resource(rsc); rsc 858 lib/pacemaker/pcmk_sched_bundle.c pe__foreach_bundle_replica(rsc, add_replica_actions_to_graph, rsc); rsc 982 lib/pacemaker/pcmk_sched_bundle.c pcmk__bundle_create_probe(pcmk_resource_t *rsc, pcmk_node_t *node) rsc 984 lib/pacemaker/pcmk_sched_bundle.c struct probe_data probe_data = { rsc, node, false }; rsc 986 lib/pacemaker/pcmk_sched_bundle.c pcmk__assert(pcmk__is_bundle(rsc)); rsc 987 lib/pacemaker/pcmk_sched_bundle.c pe__foreach_bundle_replica(rsc, create_replica_probes, &probe_data); rsc 1025 lib/pacemaker/pcmk_sched_bundle.c pcmk__output_bundle_actions(pcmk_resource_t *rsc) rsc 1027 lib/pacemaker/pcmk_sched_bundle.c pcmk__assert(pcmk__is_bundle(rsc)); rsc 1028 lib/pacemaker/pcmk_sched_bundle.c pe__foreach_bundle_replica(rsc, output_replica_actions, NULL); rsc 1033 lib/pacemaker/pcmk_sched_bundle.c pcmk__bundle_add_utilization(const pcmk_resource_t *rsc, rsc 1039 lib/pacemaker/pcmk_sched_bundle.c pcmk__assert(pcmk__is_bundle(rsc)); rsc 1041 lib/pacemaker/pcmk_sched_bundle.c if (!pcmk_is_set(rsc->flags, pcmk_rsc_unassigned)) { rsc 1049 lib/pacemaker/pcmk_sched_bundle.c container = pe__first_container(rsc); rsc 1058 lib/pacemaker/pcmk_sched_bundle.c pcmk__bundle_shutdown_lock(pcmk_resource_t *rsc) rsc 1060 lib/pacemaker/pcmk_sched_bundle.c pcmk__assert(pcmk__is_bundle(rsc)); rsc 37 lib/pacemaker/pcmk_sched_clone.c pcmk__clone_assign(pcmk_resource_t *rsc, const pcmk_node_t *prefer, rsc 42 lib/pacemaker/pcmk_sched_clone.c pcmk__assert(pcmk__is_clone(rsc)); rsc 44 lib/pacemaker/pcmk_sched_clone.c if (!pcmk_is_set(rsc->flags, pcmk_rsc_unassigned)) { rsc 49 lib/pacemaker/pcmk_sched_clone.c if (pcmk_is_set(rsc->flags, pcmk_rsc_assigning)) { rsc 50 lib/pacemaker/pcmk_sched_clone.c pcmk__rsc_debug(rsc, "Breaking assignment loop involving %s", rsc->id); rsc 53 lib/pacemaker/pcmk_sched_clone.c pcmk__set_rsc_flags(rsc, pcmk_rsc_assigning); rsc 56 lib/pacemaker/pcmk_sched_clone.c if (pcmk_is_set(rsc->flags, pcmk_rsc_promotable)) { rsc 57 lib/pacemaker/pcmk_sched_clone.c pcmk__add_promotion_scores(rsc); rsc 61 lib/pacemaker/pcmk_sched_clone.c colocations = pcmk__this_with_colocations(rsc); rsc 65 lib/pacemaker/pcmk_sched_clone.c pcmk__rsc_trace(rsc, "%s: Assigning colocation %s primary %s first", rsc 66 lib/pacemaker/pcmk_sched_clone.c rsc->id, constraint->id, constraint->primary->id); rsc 73 lib/pacemaker/pcmk_sched_clone.c colocations = pcmk__with_this_colocations(rsc); rsc 74 lib/pacemaker/pcmk_sched_clone.c g_list_foreach(colocations, pcmk__add_dependent_scores, rsc); rsc 77 lib/pacemaker/pcmk_sched_clone.c pe__show_node_scores(!pcmk_is_set(rsc->cluster->flags, rsc 79 lib/pacemaker/pcmk_sched_clone.c rsc, __func__, rsc->allowed_nodes, rsc->cluster); rsc 81 lib/pacemaker/pcmk_sched_clone.c rsc->children = g_list_sort(rsc->children, pcmk__cmp_instance); rsc 82 lib/pacemaker/pcmk_sched_clone.c pcmk__assign_instances(rsc, rsc->children, pe__clone_max(rsc), rsc 83 lib/pacemaker/pcmk_sched_clone.c pe__clone_node_max(rsc)); rsc 85 lib/pacemaker/pcmk_sched_clone.c if (pcmk_is_set(rsc->flags, pcmk_rsc_promotable)) { rsc 86 lib/pacemaker/pcmk_sched_clone.c pcmk__set_instance_roles(rsc); rsc 89 lib/pacemaker/pcmk_sched_clone.c pcmk__clear_rsc_flags(rsc, pcmk_rsc_unassigned|pcmk_rsc_assigning); rsc 90 lib/pacemaker/pcmk_sched_clone.c pcmk__rsc_trace(rsc, "Assigned clone %s", rsc->id); rsc 101 lib/pacemaker/pcmk_sched_clone.c pcmk__clone_create_actions(pcmk_resource_t *rsc) rsc 103 lib/pacemaker/pcmk_sched_clone.c pcmk__assert(pcmk__is_clone(rsc)); rsc 105 lib/pacemaker/pcmk_sched_clone.c pcmk__rsc_trace(rsc, "Creating actions for clone %s", rsc->id); rsc 106 lib/pacemaker/pcmk_sched_clone.c pcmk__create_instance_actions(rsc, rsc->children); rsc 107 lib/pacemaker/pcmk_sched_clone.c if (pcmk_is_set(rsc->flags, pcmk_rsc_promotable)) { rsc 108 lib/pacemaker/pcmk_sched_clone.c pcmk__create_promotable_actions(rsc); rsc 119 lib/pacemaker/pcmk_sched_clone.c pcmk__clone_internal_constraints(pcmk_resource_t *rsc) rsc 123 lib/pacemaker/pcmk_sched_clone.c pcmk__assert(pcmk__is_clone(rsc)); rsc 125 lib/pacemaker/pcmk_sched_clone.c pcmk__rsc_trace(rsc, "Creating internal constraints for clone %s", rsc->id); rsc 128 lib/pacemaker/pcmk_sched_clone.c pcmk__order_resource_actions(rsc, PCMK_ACTION_STOPPED, rsc 129 lib/pacemaker/pcmk_sched_clone.c rsc, PCMK_ACTION_START, rsc 131 lib/pacemaker/pcmk_sched_clone.c pcmk__order_resource_actions(rsc, PCMK_ACTION_START, rsc 132 lib/pacemaker/pcmk_sched_clone.c rsc, PCMK_ACTION_RUNNING, rsc 134 lib/pacemaker/pcmk_sched_clone.c pcmk__order_resource_actions(rsc, PCMK_ACTION_STOP, rsc 135 lib/pacemaker/pcmk_sched_clone.c rsc, PCMK_ACTION_STOPPED, rsc 139 lib/pacemaker/pcmk_sched_clone.c if (pcmk_is_set(rsc->flags, pcmk_rsc_promotable)) { rsc 140 lib/pacemaker/pcmk_sched_clone.c pcmk__order_resource_actions(rsc, PCMK_ACTION_DEMOTED, rsc 141 lib/pacemaker/pcmk_sched_clone.c rsc, PCMK_ACTION_STOP, rsc 143 lib/pacemaker/pcmk_sched_clone.c pcmk__order_resource_actions(rsc, PCMK_ACTION_RUNNING, rsc 144 lib/pacemaker/pcmk_sched_clone.c rsc, PCMK_ACTION_PROMOTE, rsc 148 lib/pacemaker/pcmk_sched_clone.c ordered = pe__clone_is_ordered(rsc); rsc 154 lib/pacemaker/pcmk_sched_clone.c rsc->children = g_list_sort(rsc->children, pcmk__cmp_instance_number); rsc 156 lib/pacemaker/pcmk_sched_clone.c for (GList *iter = rsc->children; iter != NULL; iter = iter->next) { rsc 162 lib/pacemaker/pcmk_sched_clone.c pcmk__order_starts(rsc, instance, pcmk__ar_unrunnable_first_blocks rsc 165 lib/pacemaker/pcmk_sched_clone.c rsc, PCMK_ACTION_RUNNING, rsc 169 lib/pacemaker/pcmk_sched_clone.c pcmk__order_stops(rsc, instance, pcmk__ar_then_implies_first_graphed); rsc 171 lib/pacemaker/pcmk_sched_clone.c rsc, PCMK_ACTION_STOPPED, rsc 188 lib/pacemaker/pcmk_sched_clone.c if (pcmk_is_set(rsc->flags, pcmk_rsc_promotable)) { rsc 189 lib/pacemaker/pcmk_sched_clone.c pcmk__order_promotable_instances(rsc); rsc 362 lib/pacemaker/pcmk_sched_clone.c pcmk__with_clone_colocations(const pcmk_resource_t *rsc, rsc 365 lib/pacemaker/pcmk_sched_clone.c CRM_CHECK((rsc != NULL) && (orig_rsc != NULL) && (list != NULL), return); rsc 367 lib/pacemaker/pcmk_sched_clone.c pcmk__add_with_this_list(list, rsc->rsc_cons_lhs, orig_rsc); rsc 369 lib/pacemaker/pcmk_sched_clone.c if (rsc->parent != NULL) { rsc 370 lib/pacemaker/pcmk_sched_clone.c rsc->parent->cmds->with_this_colocations(rsc->parent, orig_rsc, list); rsc 376 lib/pacemaker/pcmk_sched_clone.c pcmk__clone_with_colocations(const pcmk_resource_t *rsc, rsc 379 lib/pacemaker/pcmk_sched_clone.c CRM_CHECK((rsc != NULL) && (orig_rsc != NULL) && (list != NULL), return); rsc 381 lib/pacemaker/pcmk_sched_clone.c pcmk__add_this_with_list(list, rsc->rsc_cons, orig_rsc); rsc 383 lib/pacemaker/pcmk_sched_clone.c if (rsc->parent != NULL) { rsc 384 lib/pacemaker/pcmk_sched_clone.c rsc->parent->cmds->this_with_colocations(rsc->parent, orig_rsc, list); rsc 400 lib/pacemaker/pcmk_sched_clone.c pcmk__assert((action != NULL) && pcmk__is_clone(action->rsc)); rsc 402 lib/pacemaker/pcmk_sched_clone.c return pcmk__collective_action_flags(action, action->rsc->children, node); rsc 413 lib/pacemaker/pcmk_sched_clone.c pcmk__clone_apply_location(pcmk_resource_t *rsc, pcmk__location_t *location) rsc 415 lib/pacemaker/pcmk_sched_clone.c CRM_CHECK((location != NULL) && pcmk__is_clone(rsc), return); rsc 417 lib/pacemaker/pcmk_sched_clone.c pcmk__apply_location(rsc, location); rsc 419 lib/pacemaker/pcmk_sched_clone.c for (GList *iter = rsc->children; iter != NULL; iter = iter->next) { rsc 430 lib/pacemaker/pcmk_sched_clone.c pcmk_resource_t *rsc = user_data; rsc 432 lib/pacemaker/pcmk_sched_clone.c rsc->cmds->action_flags((pcmk_action_t *) data, NULL); rsc 442 lib/pacemaker/pcmk_sched_clone.c pcmk__clone_add_actions_to_graph(pcmk_resource_t *rsc) rsc 444 lib/pacemaker/pcmk_sched_clone.c pcmk__assert(pcmk__is_clone(rsc)); rsc 446 lib/pacemaker/pcmk_sched_clone.c g_list_foreach(rsc->actions, call_action_flags, rsc); rsc 447 lib/pacemaker/pcmk_sched_clone.c pe__create_clone_notifications(rsc); rsc 449 lib/pacemaker/pcmk_sched_clone.c for (GList *iter = rsc->children; iter != NULL; iter = iter->next) { rsc 455 lib/pacemaker/pcmk_sched_clone.c pcmk__add_rsc_actions_to_graph(rsc); rsc 456 lib/pacemaker/pcmk_sched_clone.c pe__free_clone_notification_data(rsc); rsc 470 lib/pacemaker/pcmk_sched_clone.c rsc_probed_on(const pcmk_resource_t *rsc, const pcmk_node_t *node) rsc 472 lib/pacemaker/pcmk_sched_clone.c if (rsc->children != NULL) { rsc 473 lib/pacemaker/pcmk_sched_clone.c for (GList *child_iter = rsc->children; child_iter != NULL; rsc 485 lib/pacemaker/pcmk_sched_clone.c if (rsc->known_on != NULL) { rsc 489 lib/pacemaker/pcmk_sched_clone.c g_hash_table_iter_init(&iter, rsc->known_on); rsc 566 lib/pacemaker/pcmk_sched_clone.c pcmk__clone_create_probe(pcmk_resource_t *rsc, pcmk_node_t *node) rsc 568 lib/pacemaker/pcmk_sched_clone.c pcmk__assert((node != NULL) && pcmk__is_clone(rsc)); rsc 570 lib/pacemaker/pcmk_sched_clone.c if (rsc->exclusive_discover) { rsc 580 lib/pacemaker/pcmk_sched_clone.c pcmk_node_t *allowed = g_hash_table_lookup(rsc->allowed_nodes, rsc 589 lib/pacemaker/pcmk_sched_clone.c pcmk__rsc_trace(rsc, rsc 592 lib/pacemaker/pcmk_sched_clone.c rsc->id, pcmk__node_name(node)); rsc 593 lib/pacemaker/pcmk_sched_clone.c g_hash_table_remove(rsc->allowed_nodes, node->details->id); rsc 598 lib/pacemaker/pcmk_sched_clone.c rsc->children = g_list_sort(rsc->children, pcmk__cmp_instance_number); rsc 599 lib/pacemaker/pcmk_sched_clone.c if (pcmk_is_set(rsc->flags, pcmk_rsc_unique)) { rsc 600 lib/pacemaker/pcmk_sched_clone.c return pcmk__probe_resource_list(rsc->children, node); rsc 602 lib/pacemaker/pcmk_sched_clone.c return probe_anonymous_clone(rsc, node); rsc 616 lib/pacemaker/pcmk_sched_clone.c pcmk__clone_add_graph_meta(const pcmk_resource_t *rsc, xmlNode *xml) rsc 620 lib/pacemaker/pcmk_sched_clone.c pcmk__assert(pcmk__is_clone(rsc) && (xml != NULL)); rsc 623 lib/pacemaker/pcmk_sched_clone.c crm_xml_add(xml, name, pcmk__flag_text(rsc->flags, pcmk_rsc_unique)); rsc 627 lib/pacemaker/pcmk_sched_clone.c crm_xml_add(xml, name, pcmk__flag_text(rsc->flags, pcmk_rsc_notify)); rsc 631 lib/pacemaker/pcmk_sched_clone.c crm_xml_add_int(xml, name, pe__clone_max(rsc)); rsc 635 lib/pacemaker/pcmk_sched_clone.c crm_xml_add_int(xml, name, pe__clone_node_max(rsc)); rsc 638 lib/pacemaker/pcmk_sched_clone.c if (pcmk_is_set(rsc->flags, pcmk_rsc_promotable)) { rsc 639 lib/pacemaker/pcmk_sched_clone.c int promoted_max = pe__clone_promoted_max(rsc); rsc 640 lib/pacemaker/pcmk_sched_clone.c int promoted_node_max = pe__clone_promoted_node_max(rsc); rsc 665 lib/pacemaker/pcmk_sched_clone.c pcmk__clone_add_utilization(const pcmk_resource_t *rsc, rsc 672 lib/pacemaker/pcmk_sched_clone.c pcmk__assert(pcmk__is_clone(rsc) && (orig_rsc != NULL) rsc 675 lib/pacemaker/pcmk_sched_clone.c if (!pcmk_is_set(rsc->flags, pcmk_rsc_unassigned)) { rsc 680 lib/pacemaker/pcmk_sched_clone.c for (GList *iter = rsc->children; iter != NULL; iter = iter->next) { rsc 702 lib/pacemaker/pcmk_sched_clone.c if (!existing && (rsc->children != NULL)) { rsc 704 lib/pacemaker/pcmk_sched_clone.c child = (pcmk_resource_t *) rsc->children->data; rsc 712 lib/pacemaker/pcmk_sched_clone.c pcmk__clone_shutdown_lock(pcmk_resource_t *rsc) rsc 714 lib/pacemaker/pcmk_sched_clone.c pcmk__assert(pcmk__is_clone(rsc)); rsc 174 lib/pacemaker/pcmk_sched_colocation.c const pcmk_resource_t *rsc) rsc 176 lib/pacemaker/pcmk_sched_colocation.c pcmk__assert((list != NULL) && (colocation != NULL) && (rsc != NULL)); rsc 178 lib/pacemaker/pcmk_sched_colocation.c pcmk__rsc_trace(rsc, rsc 183 lib/pacemaker/pcmk_sched_colocation.c pcmk_readable_score(colocation->score), rsc->id); rsc 201 lib/pacemaker/pcmk_sched_colocation.c const pcmk_resource_t *rsc) rsc 203 lib/pacemaker/pcmk_sched_colocation.c pcmk__assert((list != NULL) && (rsc != NULL)); rsc 217 lib/pacemaker/pcmk_sched_colocation.c pcmk__add_this_with(list, addition->data, rsc); rsc 234 lib/pacemaker/pcmk_sched_colocation.c const pcmk_resource_t *rsc) rsc 236 lib/pacemaker/pcmk_sched_colocation.c pcmk__assert((list != NULL) && (colocation != NULL) && (rsc != NULL)); rsc 238 lib/pacemaker/pcmk_sched_colocation.c pcmk__rsc_trace(rsc, rsc 243 lib/pacemaker/pcmk_sched_colocation.c pcmk_readable_score(colocation->score), rsc->id); rsc 261 lib/pacemaker/pcmk_sched_colocation.c const pcmk_resource_t *rsc) rsc 263 lib/pacemaker/pcmk_sched_colocation.c pcmk__assert((list != NULL) && (rsc != NULL)); rsc 277 lib/pacemaker/pcmk_sched_colocation.c pcmk__add_with_this(list, addition->data, rsc); rsc 418 lib/pacemaker/pcmk_sched_colocation.c unpack_influence(const char *coloc_id, const pcmk_resource_t *rsc, rsc 432 lib/pacemaker/pcmk_sched_colocation.c if (pcmk_is_set(rsc->flags, pcmk_rsc_critical)) { rsc 1041 lib/pacemaker/pcmk_sched_colocation.c const pcmk_resource_t *rsc) rsc 1043 lib/pacemaker/pcmk_sched_colocation.c if (rsc == NULL) { rsc 1044 lib/pacemaker/pcmk_sched_colocation.c rsc = colocation->primary; rsc 1061 lib/pacemaker/pcmk_sched_colocation.c && !pcmk_is_set(rsc->flags, pcmk_rsc_failed) rsc 1062 lib/pacemaker/pcmk_sched_colocation.c && pcmk__list_of_1(rsc->running_on)) { rsc 1070 lib/pacemaker/pcmk_sched_colocation.c || (rsc->running_on == NULL); rsc 1082 lib/pacemaker/pcmk_sched_colocation.c mark_action_blocked(pcmk_resource_t *rsc, const char *task, rsc 1088 lib/pacemaker/pcmk_sched_colocation.c for (iter = rsc->actions; iter != NULL; iter = iter->next) { rsc 1097 lib/pacemaker/pcmk_sched_colocation.c pcmk__update_action_for_orderings(action, rsc->cluster); rsc 1102 lib/pacemaker/pcmk_sched_colocation.c for (iter = rsc->children; iter != NULL; iter = iter->next) { rsc 1123 lib/pacemaker/pcmk_sched_colocation.c pcmk_resource_t *rsc = NULL; rsc 1136 lib/pacemaker/pcmk_sched_colocation.c pcmk__assert(action->rsc != NULL); // Start and promote are resource actions rsc 1142 lib/pacemaker/pcmk_sched_colocation.c rsc = uber_parent(action->rsc); rsc 1143 lib/pacemaker/pcmk_sched_colocation.c if (rsc->parent != NULL) { rsc 1144 lib/pacemaker/pcmk_sched_colocation.c rsc = rsc->parent; // Bundle rsc 1148 lib/pacemaker/pcmk_sched_colocation.c for (iter = rsc->children; iter != NULL; iter = iter->next) { rsc 1157 lib/pacemaker/pcmk_sched_colocation.c rsc->id, child->id, action->task); rsc 1163 lib/pacemaker/pcmk_sched_colocation.c rsc->id, action->rsc->id, action->task); rsc 1166 lib/pacemaker/pcmk_sched_colocation.c colocations = pcmk__with_this_colocations(rsc); rsc 1187 lib/pacemaker/pcmk_sched_colocation.c action->rsc); rsc 1190 lib/pacemaker/pcmk_sched_colocation.c action->rsc); rsc 1215 lib/pacemaker/pcmk_sched_colocation.c get_resource_for_role(const pcmk_resource_t *rsc) rsc 1217 lib/pacemaker/pcmk_sched_colocation.c if (pcmk_is_set(rsc->flags, pcmk_rsc_replica_container)) { rsc 1218 lib/pacemaker/pcmk_sched_colocation.c const pcmk_resource_t *child = pe__get_rsc_in_container(rsc); rsc 1224 lib/pacemaker/pcmk_sched_colocation.c return rsc; rsc 1540 lib/pacemaker/pcmk_sched_colocation.c pcmk_resource_t *rsc, const char *attr, rsc 1549 lib/pacemaker/pcmk_sched_colocation.c if ((colocation != NULL) && (rsc == colocation->dependent) rsc 1551 lib/pacemaker/pcmk_sched_colocation.c && pcmk__is_group(rsc->parent) rsc 1552 lib/pacemaker/pcmk_sched_colocation.c && (rsc != rsc->parent->children->data)) { rsc 1564 lib/pacemaker/pcmk_sched_colocation.c allowed_nodes_orig = rsc->allowed_nodes; rsc 1565 lib/pacemaker/pcmk_sched_colocation.c rsc->allowed_nodes = pcmk__copy_node_table(allowed_nodes_orig); rsc 1566 lib/pacemaker/pcmk_sched_colocation.c for (GList *loc_iter = rsc->cluster->placement_constraints; rsc 1571 lib/pacemaker/pcmk_sched_colocation.c if (location->rsc == rsc->parent) { rsc 1572 lib/pacemaker/pcmk_sched_colocation.c rsc->cmds->apply_location(rsc, location); rsc 1578 lib/pacemaker/pcmk_sched_colocation.c g_hash_table_iter_init(&iter, rsc->allowed_nodes); rsc 1583 lib/pacemaker/pcmk_sched_colocation.c && pcmk__str_eq(value, pcmk__colocation_node_attr(node, attr, rsc), rsc 1594 lib/pacemaker/pcmk_sched_colocation.c rsc->id, attr, value); rsc 1598 lib/pacemaker/pcmk_sched_colocation.c best_node, rsc->id, best_score, attr, value); rsc 1603 lib/pacemaker/pcmk_sched_colocation.c g_hash_table_destroy(rsc->allowed_nodes); rsc 1604 lib/pacemaker/pcmk_sched_colocation.c rsc->allowed_nodes = allowed_nodes_orig; rsc 1618 lib/pacemaker/pcmk_sched_colocation.c allowed_on_one(const pcmk_resource_t *rsc) rsc 1624 lib/pacemaker/pcmk_sched_colocation.c g_hash_table_iter_init(&iter, rsc->allowed_nodes); rsc 1627 lib/pacemaker/pcmk_sched_colocation.c pcmk__rsc_trace(rsc, "%s is allowed on multiple nodes", rsc->id); rsc 1631 lib/pacemaker/pcmk_sched_colocation.c pcmk__rsc_trace(rsc, "%s is allowed %s", rsc->id, rsc 2015 lib/pacemaker/pcmk_sched_colocation.c pcmk__with_this_colocations(const pcmk_resource_t *rsc) rsc 2019 lib/pacemaker/pcmk_sched_colocation.c rsc->cmds->with_this_colocations(rsc, rsc, &list); rsc 2034 lib/pacemaker/pcmk_sched_colocation.c pcmk__this_with_colocations(const pcmk_resource_t *rsc) rsc 2038 lib/pacemaker/pcmk_sched_colocation.c rsc->cmds->this_with_colocations(rsc, rsc, &list); rsc 189 lib/pacemaker/pcmk_sched_constraints.c pcmk_resource_t **rsc, pcmk_tag_t **tag) rsc 191 lib/pacemaker/pcmk_sched_constraints.c if (rsc != NULL) { rsc 192 lib/pacemaker/pcmk_sched_constraints.c *rsc = pcmk__find_constraint_resource(scheduler->resources, id); rsc 193 lib/pacemaker/pcmk_sched_constraints.c if (*rsc != NULL) { rsc 246 lib/pacemaker/pcmk_sched_constraints.c pcmk_resource_t *rsc = NULL; rsc 250 lib/pacemaker/pcmk_sched_constraints.c &rsc, &tag)) { rsc 257 lib/pacemaker/pcmk_sched_constraints.c } else if (rsc) { rsc 348 lib/pacemaker/pcmk_sched_constraints.c pcmk_resource_t *rsc = NULL; rsc 367 lib/pacemaker/pcmk_sched_constraints.c if (!pcmk__valid_resource_or_tag(scheduler, id, &rsc, &tag)) { rsc 391 lib/pacemaker/pcmk_sched_constraints.c } else if ((rsc != NULL) && convert_rsc) { rsc 427 lib/pacemaker/pcmk_sched_constraints.c pcmk_resource_t *rsc = (pcmk_resource_t *) iter->data; rsc 429 lib/pacemaker/pcmk_sched_constraints.c rsc->cmds->internal_constraints(rsc); rsc 29 lib/pacemaker/pcmk_sched_fencing.c rsc_is_known_on(const pcmk_resource_t *rsc, const pcmk_node_t *node) rsc 31 lib/pacemaker/pcmk_sched_fencing.c if (g_hash_table_lookup(rsc->known_on, node->details->id) != NULL) { rsc 34 lib/pacemaker/pcmk_sched_fencing.c } else if (pcmk__is_primitive(rsc) rsc 35 lib/pacemaker/pcmk_sched_fencing.c && pcmk__is_anonymous_clone(rsc->parent) rsc 36 lib/pacemaker/pcmk_sched_fencing.c && (g_hash_table_lookup(rsc->parent->known_on, rsc 55 lib/pacemaker/pcmk_sched_fencing.c order_start_vs_fencing(pcmk_resource_t *rsc, pcmk_action_t *stonith_op) rsc 62 lib/pacemaker/pcmk_sched_fencing.c for (GList *iter = rsc->actions; iter != NULL; iter = iter->next) { rsc 77 lib/pacemaker/pcmk_sched_fencing.c && (g_hash_table_lookup(rsc->allowed_nodes, rsc 79 lib/pacemaker/pcmk_sched_fencing.c && !rsc_is_known_on(rsc, target)) { rsc 90 lib/pacemaker/pcmk_sched_fencing.c pcmk__rsc_debug(rsc, "Ordering %s after %s recovery", rsc 109 lib/pacemaker/pcmk_sched_fencing.c order_stop_vs_fencing(pcmk_resource_t *rsc, pcmk_action_t *stonith_op) rsc 115 lib/pacemaker/pcmk_sched_fencing.c pcmk_resource_t *top = uber_parent(rsc); rsc 123 lib/pacemaker/pcmk_sched_fencing.c action_list = pe__resource_actions(rsc, target, PCMK_ACTION_STOP, FALSE); rsc 131 lib/pacemaker/pcmk_sched_fencing.c if (pcmk_is_set(rsc->flags, pcmk_rsc_needs_fencing) rsc 161 lib/pacemaker/pcmk_sched_fencing.c if (!pcmk__is_bundled(rsc)) { rsc 167 lib/pacemaker/pcmk_sched_fencing.c if (pcmk_is_set(rsc->flags, pcmk_rsc_failed)) { rsc 169 lib/pacemaker/pcmk_sched_fencing.c rsc->id, (order_implicit? "after" : "because"), rsc 177 lib/pacemaker/pcmk_sched_fencing.c if (pcmk_is_set(rsc->flags, pcmk_rsc_notify)) { rsc 178 lib/pacemaker/pcmk_sched_fencing.c pe__order_notifs_after_fencing(action, rsc, stonith_op); rsc 201 lib/pacemaker/pcmk_sched_fencing.c rsc->id, pcmk__node_name(node)); rsc 202 lib/pacemaker/pcmk_sched_fencing.c pcmk__new_ordering(rsc, stop_key(rsc), NULL, NULL, rsc 204 lib/pacemaker/pcmk_sched_fencing.c pcmk__ar_ordered, rsc->cluster); rsc 211 lib/pacemaker/pcmk_sched_fencing.c action_list = pe__resource_actions(rsc, target, PCMK_ACTION_DEMOTE, FALSE); rsc 217 lib/pacemaker/pcmk_sched_fencing.c || pcmk_is_set(rsc->flags, pcmk_rsc_failed)) { rsc 219 lib/pacemaker/pcmk_sched_fencing.c if (pcmk_is_set(rsc->flags, pcmk_rsc_failed)) { rsc 220 lib/pacemaker/pcmk_sched_fencing.c pcmk__rsc_info(rsc, rsc 223 lib/pacemaker/pcmk_sched_fencing.c rsc->id, pcmk__node_name(target)); rsc 225 lib/pacemaker/pcmk_sched_fencing.c pcmk__rsc_info(rsc, "%s is implicit after %s is fenced", rsc 235 lib/pacemaker/pcmk_sched_fencing.c if (pcmk__is_bundled(rsc)) { rsc 256 lib/pacemaker/pcmk_sched_fencing.c rsc_stonith_ordering(pcmk_resource_t *rsc, pcmk_action_t *stonith_op) rsc 258 lib/pacemaker/pcmk_sched_fencing.c if (rsc->children) { rsc 259 lib/pacemaker/pcmk_sched_fencing.c for (GList *iter = rsc->children; iter != NULL; iter = iter->next) { rsc 265 lib/pacemaker/pcmk_sched_fencing.c } else if (!pcmk_is_set(rsc->flags, pcmk_rsc_managed)) { rsc 266 lib/pacemaker/pcmk_sched_fencing.c pcmk__rsc_trace(rsc, rsc 268 lib/pacemaker/pcmk_sched_fencing.c "%s", rsc->id); rsc 271 lib/pacemaker/pcmk_sched_fencing.c order_start_vs_fencing(rsc, stonith_op); rsc 272 lib/pacemaker/pcmk_sched_fencing.c order_stop_vs_fencing(rsc, stonith_op); rsc 306 lib/pacemaker/pcmk_sched_fencing.c pcmk__order_vs_unfence(const pcmk_resource_t *rsc, pcmk_node_t *node, rsc 317 lib/pacemaker/pcmk_sched_fencing.c if ((pcmk_is_set(rsc->flags, pcmk_rsc_fence_device) rsc 318 lib/pacemaker/pcmk_sched_fencing.c && pcmk_is_set(rsc->cluster->flags, pcmk_sched_enable_unfencing)) rsc 319 lib/pacemaker/pcmk_sched_fencing.c || pcmk_is_set(rsc->flags, pcmk_rsc_needs_unfencing)) { rsc 333 lib/pacemaker/pcmk_sched_fencing.c rsc->id, action->task); rsc 468 lib/pacemaker/pcmk_sched_fencing.c pcmk_resource_t *rsc = (pcmk_resource_t *) user_data; rsc 471 lib/pacemaker/pcmk_sched_fencing.c false, rsc->cluster); rsc 474 lib/pacemaker/pcmk_sched_fencing.c rsc->id, unfence->uuid); rsc 491 lib/pacemaker/pcmk_sched_fencing.c pcmk__new_ordering(rsc, stop_key(rsc), NULL, rsc 494 lib/pacemaker/pcmk_sched_fencing.c rsc->cluster); rsc 497 lib/pacemaker/pcmk_sched_fencing.c rsc, start_key(rsc), NULL, rsc 500 lib/pacemaker/pcmk_sched_fencing.c rsc->cluster); rsc 40 lib/pacemaker/pcmk_sched_group.c pcmk__group_assign(pcmk_resource_t *rsc, const pcmk_node_t *prefer, rsc 46 lib/pacemaker/pcmk_sched_group.c pcmk__assert(pcmk__is_group(rsc)); rsc 48 lib/pacemaker/pcmk_sched_group.c if (!pcmk_is_set(rsc->flags, pcmk_rsc_unassigned)) { rsc 49 lib/pacemaker/pcmk_sched_group.c return rsc->allocated_to; // Assignment already done rsc 51 lib/pacemaker/pcmk_sched_group.c if (pcmk_is_set(rsc->flags, pcmk_rsc_assigning)) { rsc 52 lib/pacemaker/pcmk_sched_group.c pcmk__rsc_debug(rsc, "Assignment dependency loop detected involving %s", rsc 53 lib/pacemaker/pcmk_sched_group.c rsc->id); rsc 57 lib/pacemaker/pcmk_sched_group.c if (rsc->children == NULL) { rsc 59 lib/pacemaker/pcmk_sched_group.c pcmk__clear_rsc_flags(rsc, pcmk_rsc_unassigned); rsc 63 lib/pacemaker/pcmk_sched_group.c pcmk__set_rsc_flags(rsc, pcmk_rsc_assigning); rsc 64 lib/pacemaker/pcmk_sched_group.c first_member = (pcmk_resource_t *) rsc->children->data; rsc 65 lib/pacemaker/pcmk_sched_group.c rsc->role = first_member->role; rsc 67 lib/pacemaker/pcmk_sched_group.c pe__show_node_scores(!pcmk_is_set(rsc->cluster->flags, rsc 69 lib/pacemaker/pcmk_sched_group.c rsc, __func__, rsc->allowed_nodes, rsc->cluster); rsc 71 lib/pacemaker/pcmk_sched_group.c for (GList *iter = rsc->children; iter != NULL; iter = iter->next) { rsc 75 lib/pacemaker/pcmk_sched_group.c pcmk__rsc_trace(rsc, "Assigning group %s member %s", rsc 76 lib/pacemaker/pcmk_sched_group.c rsc->id, member->id); rsc 83 lib/pacemaker/pcmk_sched_group.c pe__set_next_role(rsc, first_member->next_role, "first group member"); rsc 84 lib/pacemaker/pcmk_sched_group.c pcmk__clear_rsc_flags(rsc, pcmk_rsc_assigning|pcmk_rsc_unassigned); rsc 86 lib/pacemaker/pcmk_sched_group.c if (!pe__group_flag_is_set(rsc, pcmk__group_colocated)) { rsc 118 lib/pacemaker/pcmk_sched_group.c pcmk__group_create_actions(pcmk_resource_t *rsc) rsc 120 lib/pacemaker/pcmk_sched_group.c pcmk__assert(pcmk__is_group(rsc)); rsc 122 lib/pacemaker/pcmk_sched_group.c pcmk__rsc_trace(rsc, "Creating actions for group %s", rsc->id); rsc 125 lib/pacemaker/pcmk_sched_group.c for (GList *iter = rsc->children; iter != NULL; iter = iter->next) { rsc 132 lib/pacemaker/pcmk_sched_group.c create_group_pseudo_op(rsc, PCMK_ACTION_START); rsc 133 lib/pacemaker/pcmk_sched_group.c create_group_pseudo_op(rsc, PCMK_ACTION_RUNNING); rsc 134 lib/pacemaker/pcmk_sched_group.c create_group_pseudo_op(rsc, PCMK_ACTION_STOP); rsc 135 lib/pacemaker/pcmk_sched_group.c create_group_pseudo_op(rsc, PCMK_ACTION_STOPPED); rsc 136 lib/pacemaker/pcmk_sched_group.c if (crm_is_true(g_hash_table_lookup(rsc->meta, PCMK_META_PROMOTABLE))) { rsc 137 lib/pacemaker/pcmk_sched_group.c create_group_pseudo_op(rsc, PCMK_ACTION_DEMOTE); rsc 138 lib/pacemaker/pcmk_sched_group.c create_group_pseudo_op(rsc, PCMK_ACTION_DEMOTED); rsc 139 lib/pacemaker/pcmk_sched_group.c create_group_pseudo_op(rsc, PCMK_ACTION_PROMOTE); rsc 140 lib/pacemaker/pcmk_sched_group.c create_group_pseudo_op(rsc, PCMK_ACTION_PROMOTED); rsc 310 lib/pacemaker/pcmk_sched_group.c pcmk__group_internal_constraints(pcmk_resource_t *rsc) rsc 315 lib/pacemaker/pcmk_sched_group.c pcmk__assert(pcmk__is_group(rsc)); rsc 320 lib/pacemaker/pcmk_sched_group.c pcmk__order_resource_actions(rsc, PCMK_ACTION_STOP, rsc 321 lib/pacemaker/pcmk_sched_group.c rsc, PCMK_ACTION_STOPPED, rsc 323 lib/pacemaker/pcmk_sched_group.c pcmk__order_resource_actions(rsc, PCMK_ACTION_STOPPED, rsc 324 lib/pacemaker/pcmk_sched_group.c rsc, PCMK_ACTION_START, rsc 326 lib/pacemaker/pcmk_sched_group.c pcmk__order_resource_actions(rsc, PCMK_ACTION_START, rsc 327 lib/pacemaker/pcmk_sched_group.c rsc, PCMK_ACTION_RUNNING, rsc 330 lib/pacemaker/pcmk_sched_group.c top = pe__const_top_resource(rsc, false); rsc 332 lib/pacemaker/pcmk_sched_group.c member_data.ordered = pe__group_flag_is_set(rsc, pcmk__group_ordered); rsc 333 lib/pacemaker/pcmk_sched_group.c member_data.colocated = pe__group_flag_is_set(rsc, pcmk__group_colocated); rsc 335 lib/pacemaker/pcmk_sched_group.c g_list_foreach(rsc->children, member_internal_constraints, &member_data); rsc 543 lib/pacemaker/pcmk_sched_group.c for (GList *iter = action->rsc->children; iter != NULL; iter = iter->next) { rsc 559 lib/pacemaker/pcmk_sched_group.c pcmk__rsc_trace(action->rsc, "%s is mandatory because %s is", rsc 571 lib/pacemaker/pcmk_sched_group.c pcmk__rsc_trace(action->rsc, "%s is unrunnable because %s is", rsc 582 lib/pacemaker/pcmk_sched_group.c pcmk__rsc_trace(action->rsc, rsc 624 lib/pacemaker/pcmk_sched_group.c pcmk__assert((first != NULL) && (then != NULL) && (then->rsc != NULL) rsc 632 lib/pacemaker/pcmk_sched_group.c for (GList *iter = then->rsc->children; iter != NULL; iter = iter->next) { rsc 656 lib/pacemaker/pcmk_sched_group.c pcmk__group_apply_location(pcmk_resource_t *rsc, pcmk__location_t *location) rsc 661 lib/pacemaker/pcmk_sched_group.c pcmk__assert(pcmk__is_group(rsc) && (location != NULL)); rsc 673 lib/pacemaker/pcmk_sched_group.c pcmk__apply_location(rsc, location); rsc 676 lib/pacemaker/pcmk_sched_group.c for (GList *iter = rsc->children; iter != NULL; iter = iter->next) { rsc 679 lib/pacemaker/pcmk_sched_group.c if (pe__group_flag_is_set(rsc, pcmk__group_colocated) rsc 680 lib/pacemaker/pcmk_sched_group.c && (iter != rsc->children)) { rsc 705 lib/pacemaker/pcmk_sched_group.c pcmk__group_colocated_resources(const pcmk_resource_t *rsc, rsc 711 lib/pacemaker/pcmk_sched_group.c pcmk__assert(pcmk__is_group(rsc)); rsc 714 lib/pacemaker/pcmk_sched_group.c orig_rsc = rsc; rsc 717 lib/pacemaker/pcmk_sched_group.c if (pe__group_flag_is_set(rsc, pcmk__group_colocated) rsc 718 lib/pacemaker/pcmk_sched_group.c || pcmk__is_clone(rsc->parent)) { rsc 723 lib/pacemaker/pcmk_sched_group.c colocated_rscs = g_list_prepend(colocated_rscs, (gpointer) rsc); rsc 724 lib/pacemaker/pcmk_sched_group.c for (const GList *iter = rsc->children; rsc 732 lib/pacemaker/pcmk_sched_group.c } else if (rsc->children != NULL) { rsc 736 lib/pacemaker/pcmk_sched_group.c colocated_rscs = pcmk__colocated_resources(rsc, orig_rsc, rsc 745 lib/pacemaker/pcmk_sched_group.c pcmk__with_group_colocations(const pcmk_resource_t *rsc, rsc 749 lib/pacemaker/pcmk_sched_group.c pcmk__assert((orig_rsc != NULL) && (list != NULL) && pcmk__is_group(rsc)); rsc 752 lib/pacemaker/pcmk_sched_group.c if (rsc->children == NULL) { rsc 760 lib/pacemaker/pcmk_sched_group.c if ((orig_rsc != rsc) && (orig_rsc != pe__last_group_member(rsc))) { rsc 764 lib/pacemaker/pcmk_sched_group.c pcmk__rsc_trace(rsc, "Adding 'with %s' colocations to list for %s", rsc 765 lib/pacemaker/pcmk_sched_group.c rsc->id, orig_rsc->id); rsc 768 lib/pacemaker/pcmk_sched_group.c pcmk__add_with_this_list(list, rsc->rsc_cons_lhs, orig_rsc); rsc 771 lib/pacemaker/pcmk_sched_group.c if (rsc->parent != NULL) { rsc 772 lib/pacemaker/pcmk_sched_group.c rsc->parent->cmds->with_this_colocations(rsc->parent, orig_rsc, rsc 776 lib/pacemaker/pcmk_sched_group.c if (!pe__group_flag_is_set(rsc, pcmk__group_colocated)) { rsc 782 lib/pacemaker/pcmk_sched_group.c for (const GList *iter = rsc->children; iter != NULL; iter = iter->next) { rsc 793 lib/pacemaker/pcmk_sched_group.c pcmk__group_with_colocations(const pcmk_resource_t *rsc, rsc 798 lib/pacemaker/pcmk_sched_group.c pcmk__assert((orig_rsc != NULL) && (list != NULL) && pcmk__is_group(rsc)); rsc 801 lib/pacemaker/pcmk_sched_group.c if (rsc->children == NULL) { rsc 808 lib/pacemaker/pcmk_sched_group.c if ((rsc == orig_rsc) rsc 809 lib/pacemaker/pcmk_sched_group.c || (orig_rsc == (const pcmk_resource_t *) rsc->children->data)) { rsc 810 lib/pacemaker/pcmk_sched_group.c pcmk__rsc_trace(rsc, "Adding '%s with' colocations to list for %s", rsc 811 lib/pacemaker/pcmk_sched_group.c rsc->id, orig_rsc->id); rsc 814 lib/pacemaker/pcmk_sched_group.c pcmk__add_this_with_list(list, rsc->rsc_cons, orig_rsc); rsc 817 lib/pacemaker/pcmk_sched_group.c if (rsc->parent != NULL) { rsc 818 lib/pacemaker/pcmk_sched_group.c rsc->parent->cmds->this_with_colocations(rsc->parent, orig_rsc, rsc 822 lib/pacemaker/pcmk_sched_group.c if (!pe__group_flag_is_set(rsc, pcmk__group_colocated)) { rsc 828 lib/pacemaker/pcmk_sched_group.c for (const GList *iter = rsc->children; rsc 843 lib/pacemaker/pcmk_sched_group.c for (const GList *iter = rsc->children; iter != NULL; iter = iter->next) { rsc 852 lib/pacemaker/pcmk_sched_group.c rsc->id, orig_rsc->id, member->id); rsc 853 lib/pacemaker/pcmk_sched_group.c for (const GList *cons_iter = rsc->rsc_cons; cons_iter != NULL; rsc 952 lib/pacemaker/pcmk_sched_group.c pcmk__group_add_utilization(const pcmk_resource_t *rsc, rsc 959 lib/pacemaker/pcmk_sched_group.c && pcmk__is_group(rsc)); rsc 961 lib/pacemaker/pcmk_sched_group.c if (!pcmk_is_set(rsc->flags, pcmk_rsc_unassigned)) { rsc 966 lib/pacemaker/pcmk_sched_group.c orig_rsc->id, rsc->id); rsc 967 lib/pacemaker/pcmk_sched_group.c if (pe__group_flag_is_set(rsc, pcmk__group_colocated) rsc 968 lib/pacemaker/pcmk_sched_group.c || pcmk__is_clone(rsc->parent)) { rsc 970 lib/pacemaker/pcmk_sched_group.c for (GList *iter = rsc->children; iter != NULL; iter = iter->next) { rsc 980 lib/pacemaker/pcmk_sched_group.c } else if (rsc->children != NULL) { rsc 982 lib/pacemaker/pcmk_sched_group.c member = (pcmk_resource_t *) rsc->children->data; rsc 994 lib/pacemaker/pcmk_sched_group.c pcmk__group_shutdown_lock(pcmk_resource_t *rsc) rsc 996 lib/pacemaker/pcmk_sched_group.c pcmk__assert(pcmk__is_group(rsc)); rsc 998 lib/pacemaker/pcmk_sched_group.c for (GList *iter = rsc->children; iter != NULL; iter = iter->next) { rsc 145 lib/pacemaker/pcmk_sched_instances.c apply_parent_colocations(const pcmk_resource_t *rsc, GHashTable **nodes) rsc 147 lib/pacemaker/pcmk_sched_instances.c GList *colocations = pcmk__this_with_colocations(rsc); rsc 154 lib/pacemaker/pcmk_sched_instances.c other->cmds->add_colocated_node_scores(other, rsc, rsc->id, nodes, rsc 159 lib/pacemaker/pcmk_sched_instances.c colocations = pcmk__with_this_colocations(rsc); rsc 166 lib/pacemaker/pcmk_sched_instances.c if (!pcmk__colocation_has_influence(colocation, rsc)) { rsc 169 lib/pacemaker/pcmk_sched_instances.c other->cmds->add_colocated_node_scores(other, rsc, rsc->id, nodes, rsc 247 lib/pacemaker/pcmk_sched_instances.c did_fail(const pcmk_resource_t *rsc) rsc 249 lib/pacemaker/pcmk_sched_instances.c if (pcmk_is_set(rsc->flags, pcmk_rsc_failed)) { rsc 252 lib/pacemaker/pcmk_sched_instances.c for (GList *iter = rsc->children; iter != NULL; iter = iter->next) { rsc 270 lib/pacemaker/pcmk_sched_instances.c node_is_allowed(const pcmk_resource_t *rsc, pcmk_node_t **node) rsc 273 lib/pacemaker/pcmk_sched_instances.c pcmk_node_t *allowed = g_hash_table_lookup(rsc->allowed_nodes, rsc 277 lib/pacemaker/pcmk_sched_instances.c pcmk__rsc_trace(rsc, "%s: current location (%s) is unavailable", rsc 278 lib/pacemaker/pcmk_sched_instances.c rsc->id, pcmk__node_name(*node)); rsc 592 lib/pacemaker/pcmk_sched_instances.c assign_instance_early(const pcmk_resource_t *rsc, pcmk_resource_t *instance, rsc 678 lib/pacemaker/pcmk_sched_instances.c rsc->id, pcmk__node_name(chosen), instance->id, rsc 712 lib/pacemaker/pcmk_sched_instances.c reset_allowed_node_counts(pcmk_resource_t *rsc) rsc 718 lib/pacemaker/pcmk_sched_instances.c g_hash_table_iter_init(&iter, rsc->allowed_nodes); rsc 1038 lib/pacemaker/pcmk_sched_instances.c get_instance_list(const pcmk_resource_t *rsc) rsc 1040 lib/pacemaker/pcmk_sched_instances.c if (pcmk__is_bundle(rsc)) { rsc 1041 lib/pacemaker/pcmk_sched_instances.c return pe__bundle_containers(rsc); rsc 1043 lib/pacemaker/pcmk_sched_instances.c return rsc->children; rsc 1055 lib/pacemaker/pcmk_sched_instances.c free_instance_list(const pcmk_resource_t *rsc, GList *list) rsc 1057 lib/pacemaker/pcmk_sched_instances.c if (list != rsc->children) { rsc 1134 lib/pacemaker/pcmk_sched_instances.c const pcmk_resource_t *rsc, rsc 1140 lib/pacemaker/pcmk_sched_instances.c instances = get_instance_list(rsc); rsc 1147 lib/pacemaker/pcmk_sched_instances.c display_role(role), rsc->id, instance->id, rsc 1149 lib/pacemaker/pcmk_sched_instances.c free_instance_list(rsc, instances); // Only frees list, not contents rsc 1153 lib/pacemaker/pcmk_sched_instances.c free_instance_list(rsc, instances); rsc 1157 lib/pacemaker/pcmk_sched_instances.c display_role(role), rsc->id, match_rsc->id, rsc 1177 lib/pacemaker/pcmk_sched_instances.c const pcmk_resource_t *rsc, enum rsc_role_e role, rsc 1187 lib/pacemaker/pcmk_sched_instances.c return find_compatible_instance_on_node(match_rsc, rsc, node, role, rsc 1196 lib/pacemaker/pcmk_sched_instances.c instance = find_compatible_instance_on_node(match_rsc, rsc, rsc 1202 lib/pacemaker/pcmk_sched_instances.c pcmk__rsc_debug(rsc, "No %s instance found compatible with %s", rsc 1203 lib/pacemaker/pcmk_sched_instances.c rsc->id, match_rsc->id); rsc 1228 lib/pacemaker/pcmk_sched_instances.c pcmk__rsc_trace(then->rsc, rsc 1231 lib/pacemaker/pcmk_sched_instances.c first->rsc->id, then_instance->id); rsc 1238 lib/pacemaker/pcmk_sched_instances.c pcmk__rsc_info(then->rsc, rsc 1241 lib/pacemaker/pcmk_sched_instances.c then_instance->id, first->rsc->id); rsc 1267 lib/pacemaker/pcmk_sched_instances.c const pcmk_resource_t *rsc = NULL; rsc 1293 lib/pacemaker/pcmk_sched_instances.c rsc = pe__get_rsc_in_container(instance); rsc 1295 lib/pacemaker/pcmk_sched_instances.c if (rsc == NULL) { rsc 1296 lib/pacemaker/pcmk_sched_instances.c rsc = instance; // No containerized resource, use instance itself rsc 1301 lib/pacemaker/pcmk_sched_instances.c matching_action = find_first_action(rsc->actions, NULL, action_name, node); rsc 1337 lib/pacemaker/pcmk_sched_instances.c const pcmk_resource_t *instance = action->rsc->children->data; rsc 1393 lib/pacemaker/pcmk_sched_instances.c instances = get_instance_list(then->rsc); rsc 1403 lib/pacemaker/pcmk_sched_instances.c first->rsc, rsc 1435 lib/pacemaker/pcmk_sched_instances.c type, then->rsc->cluster); rsc 1437 lib/pacemaker/pcmk_sched_instances.c free_instance_list(then->rsc, instances); rsc 1454 lib/pacemaker/pcmk_sched_instances.c pcmk_resource_t *rsc = NULL; rsc 1456 lib/pacemaker/pcmk_sched_instances.c if ((first->rsc == NULL) || (then->rsc == NULL)) { rsc 1462 lib/pacemaker/pcmk_sched_instances.c if (first->rsc == then->rsc) { rsc 1468 lib/pacemaker/pcmk_sched_instances.c if ((first->rsc->variant < pcmk_rsc_variant_clone) rsc 1469 lib/pacemaker/pcmk_sched_instances.c || (then->rsc->variant < pcmk_rsc_variant_clone)) { rsc 1477 lib/pacemaker/pcmk_sched_instances.c rsc = first->rsc; rsc 1479 lib/pacemaker/pcmk_sched_instances.c rsc = then->rsc; rsc 1482 lib/pacemaker/pcmk_sched_instances.c interleave = crm_is_true(g_hash_table_lookup(rsc->meta, rsc 1484 lib/pacemaker/pcmk_sched_instances.c pcmk__rsc_trace(rsc, "'%s then %s' will %sbe interleaved (based on %s)", rsc 1486 lib/pacemaker/pcmk_sched_instances.c rsc->id); rsc 1583 lib/pacemaker/pcmk_sched_instances.c if (then->rsc == NULL) { rsc 1591 lib/pacemaker/pcmk_sched_instances.c GList *instances = get_instance_list(then->rsc); rsc 1604 lib/pacemaker/pcmk_sched_instances.c free_instance_list(then->rsc, instances); rsc 1611 lib/pacemaker/pcmk_sched_instances.c "Action summary", action->rsc->id, \ rsc 1651 lib/pacemaker/pcmk_sched_instances.c pcmk__rsc_trace(action->rsc, "%s has no %s action on %s", rsc 1656 lib/pacemaker/pcmk_sched_instances.c pcmk__rsc_trace(action->rsc, "%s has %s for %s on %s", rsc 1679 lib/pacemaker/pcmk_sched_instances.c pcmk__rsc_trace(action->rsc, rsc 25 lib/pacemaker/pcmk_sched_location.c pcmk_node_t *node, pcmk_resource_t *rsc) rsc 39 lib/pacemaker/pcmk_sched_location.c target = g_hash_table_lookup(rsc->meta, rsc 111 lib/pacemaker/pcmk_sched_location.c generate_location_rule(pcmk_resource_t *rsc, xmlNode *rule_xml, rsc 129 lib/pacemaker/pcmk_sched_location.c rule_xml = expand_idref(rule_xml, rsc->cluster->input); rsc 179 lib/pacemaker/pcmk_sched_location.c location_rule = pcmk__new_location(rule_id, rsc, 0, discovery, NULL); rsc 197 lib/pacemaker/pcmk_sched_location.c for (iter = rsc->cluster->nodes; iter != NULL; iter = iter->next) { rsc 201 lib/pacemaker/pcmk_sched_location.c rule_input->rsc_params = pe_rsc_params(rsc, node, rsc->cluster); rsc 209 lib/pacemaker/pcmk_sched_location.c rsc); rsc 229 lib/pacemaker/pcmk_sched_location.c unpack_rsc_location(xmlNode *xml_obj, pcmk_resource_t *rsc, rsc 240 lib/pacemaker/pcmk_sched_location.c if (rsc == NULL) { rsc 252 lib/pacemaker/pcmk_sched_location.c pcmk_node_t *match = pcmk_find_node(rsc->cluster, node); rsc 278 lib/pacemaker/pcmk_sched_location.c location = pcmk__new_location(id, rsc, score_i, discovery, match); rsc 288 lib/pacemaker/pcmk_sched_location.c .now = rsc->cluster->now, rsc 289 lib/pacemaker/pcmk_sched_location.c .rsc_meta = rsc->meta, rsc 308 lib/pacemaker/pcmk_sched_location.c if (generate_location_rule(rsc, rule_xml, discovery, next_change, rsc 335 lib/pacemaker/pcmk_sched_location.c pe__update_recheck_time(t, rsc->cluster, rsc 349 lib/pacemaker/pcmk_sched_location.c pcmk_resource_t *rsc; rsc 351 lib/pacemaker/pcmk_sched_location.c rsc = pcmk__find_constraint_resource(scheduler->resources, value); rsc 352 lib/pacemaker/pcmk_sched_location.c unpack_rsc_location(xml_obj, rsc, NULL, NULL, NULL, 0, NULL); rsc 418 lib/pacemaker/pcmk_sched_location.c pcmk_resource_t *rsc = NULL; rsc 445 lib/pacemaker/pcmk_sched_location.c if (!pcmk__valid_resource_or_tag(scheduler, rsc_id, &rsc, &tag)) { rsc 450 lib/pacemaker/pcmk_sched_location.c } else if (rsc != NULL) { rsc 588 lib/pacemaker/pcmk_sched_location.c pcmk__new_location(const char *id, pcmk_resource_t *rsc, rsc 600 lib/pacemaker/pcmk_sched_location.c if (rsc == NULL) { rsc 607 lib/pacemaker/pcmk_sched_location.c new_con->rsc = rsc; rsc 622 lib/pacemaker/pcmk_sched_location.c rsc->exclusive_discover = TRUE; rsc 636 lib/pacemaker/pcmk_sched_location.c rsc->cluster->placement_constraints = g_list_prepend( rsc 637 lib/pacemaker/pcmk_sched_location.c rsc->cluster->placement_constraints, new_con); rsc 638 lib/pacemaker/pcmk_sched_location.c rsc->rsc_location = g_list_prepend(rsc->rsc_location, new_con); rsc 656 lib/pacemaker/pcmk_sched_location.c location->rsc->cmds->apply_location(location->rsc, location); rsc 671 lib/pacemaker/pcmk_sched_location.c pcmk__apply_location(pcmk_resource_t *rsc, pcmk__location_t *location) rsc 675 lib/pacemaker/pcmk_sched_location.c pcmk__assert((rsc != NULL) && (location != NULL)); rsc 679 lib/pacemaker/pcmk_sched_location.c if (need_role && (location->role_filter != rsc->next_role)) { rsc 680 lib/pacemaker/pcmk_sched_location.c pcmk__rsc_trace(rsc, rsc 682 lib/pacemaker/pcmk_sched_location.c location->id, rsc->id, pcmk_role_text(rsc->next_role), rsc 688 lib/pacemaker/pcmk_sched_location.c pcmk__rsc_trace(rsc, "Not applying %s to %s because no nodes match", rsc 689 lib/pacemaker/pcmk_sched_location.c location->id, rsc->id); rsc 695 lib/pacemaker/pcmk_sched_location.c pcmk_node_t *allowed_node = g_hash_table_lookup(rsc->allowed_nodes, rsc 698 lib/pacemaker/pcmk_sched_location.c pcmk__rsc_trace(rsc, "Applying %s%s%s to %s score on %s: %c %s", rsc 702 lib/pacemaker/pcmk_sched_location.c rsc->id, pcmk__node_name(node), rsc 708 lib/pacemaker/pcmk_sched_location.c g_hash_table_insert(rsc->allowed_nodes, rsc 718 lib/pacemaker/pcmk_sched_location.c rsc->exclusive_discover = TRUE; rsc 46 lib/pacemaker/pcmk_sched_migration.c pcmk__create_migration_actions(pcmk_resource_t *rsc, const pcmk_node_t *current) rsc 53 lib/pacemaker/pcmk_sched_migration.c pcmk__rsc_trace(rsc, "Creating actions to %smigrate %s from %s to %s", rsc 54 lib/pacemaker/pcmk_sched_migration.c ((rsc->partial_migration_target == NULL)? "" : "partially "), rsc 55 lib/pacemaker/pcmk_sched_migration.c rsc->id, pcmk__node_name(current), rsc 56 lib/pacemaker/pcmk_sched_migration.c pcmk__node_name(rsc->allocated_to)); rsc 57 lib/pacemaker/pcmk_sched_migration.c start = start_action(rsc, rsc->allocated_to, TRUE); rsc 58 lib/pacemaker/pcmk_sched_migration.c stop = stop_action(rsc, current, TRUE); rsc 60 lib/pacemaker/pcmk_sched_migration.c if (rsc->partial_migration_target == NULL) { rsc 61 lib/pacemaker/pcmk_sched_migration.c migrate_to = custom_action(rsc, pcmk__op_key(rsc->id, rsc 64 lib/pacemaker/pcmk_sched_migration.c rsc->cluster); rsc 66 lib/pacemaker/pcmk_sched_migration.c migrate_from = custom_action(rsc, pcmk__op_key(rsc->id, rsc 68 lib/pacemaker/pcmk_sched_migration.c PCMK_ACTION_MIGRATE_FROM, rsc->allocated_to, rsc 69 lib/pacemaker/pcmk_sched_migration.c TRUE, rsc->cluster); rsc 77 lib/pacemaker/pcmk_sched_migration.c if (rsc->partial_migration_target == NULL) { rsc 83 lib/pacemaker/pcmk_sched_migration.c pcmk__new_ordering(rsc, pcmk__op_key(rsc->id, PCMK_ACTION_MONITOR, 0), rsc 85 lib/pacemaker/pcmk_sched_migration.c rsc, rsc 86 lib/pacemaker/pcmk_sched_migration.c pcmk__op_key(rsc->id, PCMK_ACTION_MIGRATE_TO, 0), rsc 87 lib/pacemaker/pcmk_sched_migration.c NULL, pcmk__ar_ordered, rsc->cluster); rsc 88 lib/pacemaker/pcmk_sched_migration.c pcmk__new_ordering(rsc, pcmk__op_key(rsc->id, PCMK_ACTION_MIGRATE_TO, 0), rsc 90 lib/pacemaker/pcmk_sched_migration.c rsc, rsc 91 lib/pacemaker/pcmk_sched_migration.c pcmk__op_key(rsc->id, PCMK_ACTION_MIGRATE_FROM, 0), rsc 94 lib/pacemaker/pcmk_sched_migration.c rsc->cluster); rsc 100 lib/pacemaker/pcmk_sched_migration.c pcmk__new_ordering(rsc, pcmk__op_key(rsc->id, PCMK_ACTION_MONITOR, 0), rsc 102 lib/pacemaker/pcmk_sched_migration.c rsc, rsc 103 lib/pacemaker/pcmk_sched_migration.c pcmk__op_key(rsc->id, PCMK_ACTION_MIGRATE_FROM, 0), rsc 104 lib/pacemaker/pcmk_sched_migration.c NULL, pcmk__ar_ordered, rsc->cluster); rsc 108 lib/pacemaker/pcmk_sched_migration.c pcmk__new_ordering(rsc, pcmk__op_key(rsc->id, PCMK_ACTION_MIGRATE_FROM, 0), rsc 110 lib/pacemaker/pcmk_sched_migration.c rsc, pcmk__op_key(rsc->id, PCMK_ACTION_STOP, 0), rsc 113 lib/pacemaker/pcmk_sched_migration.c rsc->cluster); rsc 114 lib/pacemaker/pcmk_sched_migration.c pcmk__new_ordering(rsc, pcmk__op_key(rsc->id, PCMK_ACTION_MIGRATE_FROM, 0), rsc 116 lib/pacemaker/pcmk_sched_migration.c rsc, pcmk__op_key(rsc->id, PCMK_ACTION_START, 0), rsc 121 lib/pacemaker/pcmk_sched_migration.c rsc->cluster); rsc 124 lib/pacemaker/pcmk_sched_migration.c add_migration_meta(migrate_to, current, rsc->allocated_to); rsc 126 lib/pacemaker/pcmk_sched_migration.c if (!rsc->is_remote_node) { rsc 143 lib/pacemaker/pcmk_sched_migration.c add_migration_meta(migrate_from, current, rsc->allocated_to); rsc 157 lib/pacemaker/pcmk_sched_migration.c pcmk_resource_t *rsc = (pcmk_resource_t *) user_data; rsc 160 lib/pacemaker/pcmk_sched_migration.c bool cleanup = pcmk_is_set(rsc->cluster->flags, rsc 163 lib/pacemaker/pcmk_sched_migration.c pcmk__rsc_trace(rsc, rsc 165 lib/pacemaker/pcmk_sched_migration.c (cleanup? " and cleanup" : ""), rsc->id, rsc 167 lib/pacemaker/pcmk_sched_migration.c stop = stop_action(rsc, dangling_source, FALSE); rsc 170 lib/pacemaker/pcmk_sched_migration.c pcmk__schedule_cleanup(rsc, dangling_source, false); rsc 184 lib/pacemaker/pcmk_sched_migration.c pcmk__rsc_can_migrate(const pcmk_resource_t *rsc, const pcmk_node_t *current) rsc 186 lib/pacemaker/pcmk_sched_migration.c CRM_CHECK(rsc != NULL, return false); rsc 188 lib/pacemaker/pcmk_sched_migration.c if (!pcmk_is_set(rsc->flags, pcmk_rsc_migratable)) { rsc 189 lib/pacemaker/pcmk_sched_migration.c pcmk__rsc_trace(rsc, rsc 191 lib/pacemaker/pcmk_sched_migration.c "the configuration does not allow it", rsc->id); rsc 195 lib/pacemaker/pcmk_sched_migration.c if (!pcmk_is_set(rsc->flags, pcmk_rsc_managed)) { rsc 196 lib/pacemaker/pcmk_sched_migration.c pcmk__rsc_trace(rsc, "%s cannot migrate because it is not managed", rsc 197 lib/pacemaker/pcmk_sched_migration.c rsc->id); rsc 201 lib/pacemaker/pcmk_sched_migration.c if (pcmk_is_set(rsc->flags, pcmk_rsc_failed)) { rsc 202 lib/pacemaker/pcmk_sched_migration.c pcmk__rsc_trace(rsc, "%s cannot migrate because it is failed", rsc->id); rsc 206 lib/pacemaker/pcmk_sched_migration.c if (pcmk_is_set(rsc->flags, pcmk_rsc_start_pending)) { rsc 207 lib/pacemaker/pcmk_sched_migration.c pcmk__rsc_trace(rsc, "%s cannot migrate because it has a start pending", rsc 208 lib/pacemaker/pcmk_sched_migration.c rsc->id); rsc 213 lib/pacemaker/pcmk_sched_migration.c pcmk__rsc_trace(rsc, rsc 216 lib/pacemaker/pcmk_sched_migration.c rsc->id, pcmk__node_name(current)); rsc 220 lib/pacemaker/pcmk_sched_migration.c if ((rsc->allocated_to == NULL) || rsc->allocated_to->details->unclean) { rsc 221 lib/pacemaker/pcmk_sched_migration.c pcmk__rsc_trace(rsc, rsc 224 lib/pacemaker/pcmk_sched_migration.c rsc->id, pcmk__node_name(rsc->allocated_to)); rsc 114 lib/pacemaker/pcmk_sched_nodes.c pcmk__copy_node_tables(const pcmk_resource_t *rsc, GHashTable **copy) rsc 116 lib/pacemaker/pcmk_sched_nodes.c pcmk__assert((rsc != NULL) && (copy != NULL)); rsc 122 lib/pacemaker/pcmk_sched_nodes.c g_hash_table_insert(*copy, rsc->id, rsc 123 lib/pacemaker/pcmk_sched_nodes.c pcmk__copy_node_table(rsc->allowed_nodes)); rsc 125 lib/pacemaker/pcmk_sched_nodes.c for (const GList *iter = rsc->children; iter != NULL; iter = iter->next) { rsc 145 lib/pacemaker/pcmk_sched_nodes.c pcmk__restore_node_tables(pcmk_resource_t *rsc, GHashTable *backup) rsc 147 lib/pacemaker/pcmk_sched_nodes.c pcmk__assert((rsc != NULL) && (backup != NULL)); rsc 149 lib/pacemaker/pcmk_sched_nodes.c g_hash_table_destroy(rsc->allowed_nodes); rsc 152 lib/pacemaker/pcmk_sched_nodes.c rsc->allowed_nodes = g_hash_table_lookup(backup, rsc->id); rsc 153 lib/pacemaker/pcmk_sched_nodes.c rsc->allowed_nodes = pcmk__copy_node_table(rsc->allowed_nodes); rsc 155 lib/pacemaker/pcmk_sched_nodes.c for (GList *iter = rsc->children; iter != NULL; iter = iter->next) { rsc 393 lib/pacemaker/pcmk_sched_nodes.c pcmk_resource_t *rsc = (pcmk_resource_t *) r->data; rsc 401 lib/pacemaker/pcmk_sched_nodes.c constrain = !crm_is_true(g_hash_table_lookup(rsc->meta, rsc 405 lib/pacemaker/pcmk_sched_nodes.c pcmk__new_location(strategy_str, rsc, health, NULL, node); rsc 407 lib/pacemaker/pcmk_sched_nodes.c pcmk__rsc_trace(rsc, "%s is immune from health ban on %s", rsc 408 lib/pacemaker/pcmk_sched_nodes.c rsc->id, pcmk__node_name(node)); rsc 425 lib/pacemaker/pcmk_sched_nodes.c pcmk__top_allowed_node(const pcmk_resource_t *rsc, const pcmk_node_t *node) rsc 429 lib/pacemaker/pcmk_sched_nodes.c if ((rsc == NULL) || (node == NULL)) { rsc 431 lib/pacemaker/pcmk_sched_nodes.c } else if (rsc->parent == NULL) { rsc 432 lib/pacemaker/pcmk_sched_nodes.c allowed_nodes = rsc->allowed_nodes; rsc 434 lib/pacemaker/pcmk_sched_nodes.c allowed_nodes = rsc->parent->allowed_nodes; rsc 246 lib/pacemaker/pcmk_sched_ordering.c pcmk_resource_t *rsc = NULL; rsc 256 lib/pacemaker/pcmk_sched_ordering.c rsc = pcmk__find_constraint_resource(scheduler->resources, rsc_id); rsc 257 lib/pacemaker/pcmk_sched_ordering.c if (rsc == NULL) { rsc 269 lib/pacemaker/pcmk_sched_ordering.c if (!pcmk__is_clone(rsc)) { rsc 275 lib/pacemaker/pcmk_sched_ordering.c rsc = find_clone_instance(rsc, instance_id); rsc 276 lib/pacemaker/pcmk_sched_ordering.c if (rsc == NULL) { rsc 283 lib/pacemaker/pcmk_sched_ordering.c return rsc; rsc 296 lib/pacemaker/pcmk_sched_ordering.c get_minimum_first_instances(const pcmk_resource_t *rsc, const xmlNode *xml) rsc 301 lib/pacemaker/pcmk_sched_ordering.c if (!pcmk__is_clone(rsc)) { rsc 305 lib/pacemaker/pcmk_sched_ordering.c clone_min = g_hash_table_lookup(rsc->meta, PCMK_META_CLONE_MIN); rsc 393 lib/pacemaker/pcmk_sched_ordering.c #define handle_restart_type(rsc, kind, flag, flags) do { \ rsc 395 lib/pacemaker/pcmk_sched_ordering.c && ((rsc)->restart_type == pe_restart_restart)) { \ rsc 545 lib/pacemaker/pcmk_sched_ordering.c first_rsc = first_action->rsc; rsc 548 lib/pacemaker/pcmk_sched_ordering.c then_rsc = then_action->rsc; rsc 571 lib/pacemaker/pcmk_sched_ordering.c order->rsc1 = first_action->rsc; rsc 575 lib/pacemaker/pcmk_sched_ordering.c order->rsc2 = then_action->rsc; rsc 1110 lib/pacemaker/pcmk_sched_ordering.c && (input->action->rsc != NULL) rsc 1111 lib/pacemaker/pcmk_sched_ordering.c && pcmk__rsc_corresponds_to_guest(action->rsc, input->action->node)) { rsc 1114 lib/pacemaker/pcmk_sched_ordering.c input->action->rsc->id, action->rsc->id); rsc 1126 lib/pacemaker/pcmk_sched_ordering.c && (action->rsc != NULL) rsc 1176 lib/pacemaker/pcmk_sched_ordering.c if (pcmk_is_set(action->rsc->flags, pcmk_rsc_maintenance)) { rsc 1177 lib/pacemaker/pcmk_sched_ordering.c pcmk__rsc_trace(action->rsc, rsc 1184 lib/pacemaker/pcmk_sched_ordering.c pcmk__rsc_trace(action->rsc, rsc 1195 lib/pacemaker/pcmk_sched_ordering.c if (!pcmk_any_flags_set(action->rsc->flags, rsc 1197 lib/pacemaker/pcmk_sched_ordering.c pcmk__rsc_trace(action->rsc, rsc 1204 lib/pacemaker/pcmk_sched_ordering.c pcmk__rsc_trace(action->rsc, "Ordering %s before shutdown of %s", rsc 1207 lib/pacemaker/pcmk_sched_ordering.c pcmk__new_ordering(action->rsc, NULL, action, NULL, rsc 1225 lib/pacemaker/pcmk_sched_ordering.c find_actions_by_task(const pcmk_resource_t *rsc, const char *original_key) rsc 1228 lib/pacemaker/pcmk_sched_ordering.c GList *list = find_actions(rsc->actions, original_key, NULL); rsc 1238 lib/pacemaker/pcmk_sched_ordering.c key = pcmk__op_key(rsc->id, task, interval_ms); rsc 1239 lib/pacemaker/pcmk_sched_ordering.c list = find_actions(rsc->actions, key, NULL); rsc 1256 lib/pacemaker/pcmk_sched_ordering.c const pcmk_resource_t *rsc, rsc 1262 lib/pacemaker/pcmk_sched_ordering.c CRM_CHECK((rsc != NULL) && (order != NULL), return); rsc 1265 lib/pacemaker/pcmk_sched_ordering.c pcmk__rsc_trace(rsc, "Applying ordering %d for 'then' resource %s", rsc 1266 lib/pacemaker/pcmk_sched_ordering.c order->id, rsc->id); rsc 1272 lib/pacemaker/pcmk_sched_ordering.c then_actions = find_actions_by_task(rsc, order->task2); rsc 1276 lib/pacemaker/pcmk_sched_ordering.c pcmk__rsc_trace(rsc, "Ignoring ordering %d: no %s actions found for %s", rsc 1277 lib/pacemaker/pcmk_sched_ordering.c order->id, order->task2, rsc->id); rsc 1281 lib/pacemaker/pcmk_sched_ordering.c if ((first_action != NULL) && (first_action->rsc == rsc) rsc 1284 lib/pacemaker/pcmk_sched_ordering.c pcmk__rsc_trace(rsc, rsc 1286 lib/pacemaker/pcmk_sched_ordering.c first_action->uuid, order->task2, rsc->id); rsc 1293 lib/pacemaker/pcmk_sched_ordering.c pcmk__rsc_debug(rsc, rsc 1295 lib/pacemaker/pcmk_sched_ordering.c order->id, rsc->id); rsc 1308 lib/pacemaker/pcmk_sched_ordering.c "to order it after", then_action_iter->task, rsc->id, rsc 1383 lib/pacemaker/pcmk_sched_ordering.c then_rsc = order->action2->rsc; rsc 1443 lib/pacemaker/pcmk_sched_ordering.c pcmk_resource_t *rsc = order->rsc1; rsc 1445 lib/pacemaker/pcmk_sched_ordering.c if (rsc != NULL) { rsc 1446 lib/pacemaker/pcmk_sched_ordering.c rsc_order_first(rsc, order); rsc 1450 lib/pacemaker/pcmk_sched_ordering.c rsc = order->rsc2; rsc 1451 lib/pacemaker/pcmk_sched_ordering.c if (rsc != NULL) { rsc 1452 lib/pacemaker/pcmk_sched_ordering.c order_resource_actions_after(order->action1, rsc, order); rsc 1502 lib/pacemaker/pcmk_sched_ordering.c pcmk__promotable_restart_ordering(pcmk_resource_t *rsc) rsc 1505 lib/pacemaker/pcmk_sched_ordering.c pcmk__order_resource_actions(rsc, PCMK_ACTION_STOPPED, rsc 1506 lib/pacemaker/pcmk_sched_ordering.c rsc, PCMK_ACTION_START, rsc 1508 lib/pacemaker/pcmk_sched_ordering.c pcmk__order_resource_actions(rsc, PCMK_ACTION_STOPPED, rsc 1509 lib/pacemaker/pcmk_sched_ordering.c rsc, PCMK_ACTION_PROMOTE, rsc 1513 lib/pacemaker/pcmk_sched_ordering.c pcmk__order_resource_actions(rsc, PCMK_ACTION_DEMOTED, rsc 1514 lib/pacemaker/pcmk_sched_ordering.c rsc, PCMK_ACTION_STOP, rsc 1516 lib/pacemaker/pcmk_sched_ordering.c pcmk__order_resource_actions(rsc, PCMK_ACTION_DEMOTED, rsc 1517 lib/pacemaker/pcmk_sched_ordering.c rsc, PCMK_ACTION_START, rsc 1519 lib/pacemaker/pcmk_sched_ordering.c pcmk__order_resource_actions(rsc, PCMK_ACTION_DEMOTED, rsc 1520 lib/pacemaker/pcmk_sched_ordering.c rsc, PCMK_ACTION_PROMOTE, rsc 1524 lib/pacemaker/pcmk_sched_ordering.c pcmk__order_resource_actions(rsc, PCMK_ACTION_RUNNING, rsc 1525 lib/pacemaker/pcmk_sched_ordering.c rsc, PCMK_ACTION_PROMOTE, rsc 1529 lib/pacemaker/pcmk_sched_ordering.c pcmk__order_resource_actions(rsc, PCMK_ACTION_DEMOTE, rsc 1530 lib/pacemaker/pcmk_sched_ordering.c rsc, PCMK_ACTION_DEMOTED, rsc 20 lib/pacemaker/pcmk_sched_primitive.c static void stop_resource(pcmk_resource_t *rsc, pcmk_node_t *node, rsc 22 lib/pacemaker/pcmk_sched_primitive.c static void start_resource(pcmk_resource_t *rsc, pcmk_node_t *node, rsc 24 lib/pacemaker/pcmk_sched_primitive.c static void demote_resource(pcmk_resource_t *rsc, pcmk_node_t *node, rsc 26 lib/pacemaker/pcmk_sched_primitive.c static void promote_resource(pcmk_resource_t *rsc, pcmk_node_t *node, rsc 28 lib/pacemaker/pcmk_sched_primitive.c static void assert_role_error(pcmk_resource_t *rsc, pcmk_node_t *node, rsc 83 lib/pacemaker/pcmk_sched_primitive.c typedef void (*rsc_transition_fn)(pcmk_resource_t *rsc, pcmk_node_t *node, rsc 134 lib/pacemaker/pcmk_sched_primitive.c sorted_allowed_nodes(const pcmk_resource_t *rsc) rsc 136 lib/pacemaker/pcmk_sched_primitive.c if (rsc->allowed_nodes != NULL) { rsc 137 lib/pacemaker/pcmk_sched_primitive.c GList *nodes = g_hash_table_get_values(rsc->allowed_nodes); rsc 140 lib/pacemaker/pcmk_sched_primitive.c return pcmk__sort_nodes(nodes, pcmk__current_node(rsc)); rsc 166 lib/pacemaker/pcmk_sched_primitive.c assign_best_node(pcmk_resource_t *rsc, const pcmk_node_t *prefer, rsc 172 lib/pacemaker/pcmk_sched_primitive.c const pcmk_node_t *most_free_node = pcmk__ban_insufficient_capacity(rsc); rsc 178 lib/pacemaker/pcmk_sched_primitive.c if (!pcmk_is_set(rsc->flags, pcmk_rsc_unassigned)) { rsc 180 lib/pacemaker/pcmk_sched_primitive.c return rsc->allocated_to != NULL; rsc 184 lib/pacemaker/pcmk_sched_primitive.c nodes = sorted_allowed_nodes(rsc); rsc 191 lib/pacemaker/pcmk_sched_primitive.c chosen = g_hash_table_lookup(rsc->allowed_nodes, prefer->details->id); rsc 194 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_trace(rsc, "Preferred node %s for %s was unknown", rsc 195 lib/pacemaker/pcmk_sched_primitive.c pcmk__node_name(prefer), rsc->id); rsc 204 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_trace(rsc, "Preferred node %s for %s was unsuitable", rsc 205 lib/pacemaker/pcmk_sched_primitive.c pcmk__node_name(chosen), rsc->id); rsc 209 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_trace(rsc, "Preferred node %s for %s was unavailable", rsc 210 lib/pacemaker/pcmk_sched_primitive.c pcmk__node_name(chosen), rsc->id); rsc 214 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_trace(rsc, rsc 217 lib/pacemaker/pcmk_sched_primitive.c pcmk__node_name(chosen), rsc->id, rsc 229 lib/pacemaker/pcmk_sched_primitive.c if (!pcmk__is_unique_clone(rsc->parent) rsc 241 lib/pacemaker/pcmk_sched_primitive.c pcmk_node_t *running = pcmk__current_node(rsc); rsc 247 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_trace(rsc, rsc 249 lib/pacemaker/pcmk_sched_primitive.c rsc->id, pcmk__node_name(running)); rsc 276 lib/pacemaker/pcmk_sched_primitive.c pcmk__node_name(chosen), rsc->id, rsc 283 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_trace(rsc, "Chose %s for %s from %d candidates", rsc 284 lib/pacemaker/pcmk_sched_primitive.c pcmk__node_name(chosen), rsc->id, g_list_length(nodes)); rsc 287 lib/pacemaker/pcmk_sched_primitive.c pcmk__assign_resource(rsc, chosen, false, stop_if_fail); rsc 289 lib/pacemaker/pcmk_sched_primitive.c return rsc->allocated_to != NULL; rsc 300 lib/pacemaker/pcmk_sched_primitive.c apply_this_with(pcmk__colocation_t *colocation, pcmk_resource_t *rsc) rsc 309 lib/pacemaker/pcmk_sched_primitive.c archive = pcmk__copy_node_table(rsc->allowed_nodes); rsc 313 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_trace(rsc, rsc 316 lib/pacemaker/pcmk_sched_primitive.c rsc->id, colocation->id, other->id, rsc 323 lib/pacemaker/pcmk_sched_primitive.c rsc->cmds->apply_coloc_score(rsc, other, colocation, true); rsc 325 lib/pacemaker/pcmk_sched_primitive.c && !pcmk__any_node_available(rsc->allowed_nodes)) { rsc 326 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_info(rsc, rsc 329 lib/pacemaker/pcmk_sched_primitive.c rsc->id, other->id); rsc 330 lib/pacemaker/pcmk_sched_primitive.c g_hash_table_destroy(rsc->allowed_nodes); rsc 331 lib/pacemaker/pcmk_sched_primitive.c rsc->allowed_nodes = archive; rsc 393 lib/pacemaker/pcmk_sched_primitive.c pcmk__primitive_assign(pcmk_resource_t *rsc, const pcmk_node_t *prefer, rsc 401 lib/pacemaker/pcmk_sched_primitive.c pcmk__assert(pcmk__is_primitive(rsc)); rsc 404 lib/pacemaker/pcmk_sched_primitive.c if ((rsc->parent != NULL) rsc 405 lib/pacemaker/pcmk_sched_primitive.c && !pcmk_is_set(rsc->parent->flags, pcmk_rsc_assigning)) { rsc 406 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_debug(rsc, "%s: Assigning parent %s first", rsc 407 lib/pacemaker/pcmk_sched_primitive.c rsc->id, rsc->parent->id); rsc 408 lib/pacemaker/pcmk_sched_primitive.c rsc->parent->cmds->assign(rsc->parent, prefer, stop_if_fail); rsc 411 lib/pacemaker/pcmk_sched_primitive.c if (!pcmk_is_set(rsc->flags, pcmk_rsc_unassigned)) { rsc 415 lib/pacemaker/pcmk_sched_primitive.c if (rsc->allocated_to != NULL) { rsc 416 lib/pacemaker/pcmk_sched_primitive.c node_name = pcmk__node_name(rsc->allocated_to); rsc 418 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_debug(rsc, "%s: pre-assigned to %s", rsc->id, node_name); rsc 419 lib/pacemaker/pcmk_sched_primitive.c return rsc->allocated_to; rsc 423 lib/pacemaker/pcmk_sched_primitive.c if (pcmk_is_set(rsc->flags, pcmk_rsc_assigning)) { rsc 424 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_debug(rsc, "Breaking assignment loop involving %s", rsc->id); rsc 427 lib/pacemaker/pcmk_sched_primitive.c pcmk__set_rsc_flags(rsc, pcmk_rsc_assigning); rsc 429 lib/pacemaker/pcmk_sched_primitive.c pe__show_node_scores(true, rsc, "Pre-assignment", rsc->allowed_nodes, rsc 430 lib/pacemaker/pcmk_sched_primitive.c rsc->cluster); rsc 432 lib/pacemaker/pcmk_sched_primitive.c this_with_colocations = pcmk__this_with_colocations(rsc); rsc 433 lib/pacemaker/pcmk_sched_primitive.c with_this_colocations = pcmk__with_this_colocations(rsc); rsc 441 lib/pacemaker/pcmk_sched_primitive.c apply_this_with(colocation, rsc); rsc 449 lib/pacemaker/pcmk_sched_primitive.c pcmk__add_dependent_scores(colocation, rsc); rsc 453 lib/pacemaker/pcmk_sched_primitive.c pe__show_node_scores(true, rsc, "Mandatory-colocations", rsc 454 lib/pacemaker/pcmk_sched_primitive.c rsc->allowed_nodes, rsc->cluster); rsc 462 lib/pacemaker/pcmk_sched_primitive.c apply_this_with(colocation, rsc); rsc 470 lib/pacemaker/pcmk_sched_primitive.c pcmk__add_dependent_scores(colocation, rsc); rsc 477 lib/pacemaker/pcmk_sched_primitive.c if (rsc->next_role == pcmk_role_stopped) { rsc 478 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_trace(rsc, rsc 480 lib/pacemaker/pcmk_sched_primitive.c rsc->id); rsc 481 lib/pacemaker/pcmk_sched_primitive.c resource_location(rsc, NULL, -PCMK_SCORE_INFINITY, rsc 482 lib/pacemaker/pcmk_sched_primitive.c PCMK_META_TARGET_ROLE, rsc->cluster); rsc 484 lib/pacemaker/pcmk_sched_primitive.c } else if ((rsc->next_role > rsc->role) rsc 485 lib/pacemaker/pcmk_sched_primitive.c && !pcmk_is_set(rsc->cluster->flags, pcmk_sched_quorate) rsc 486 lib/pacemaker/pcmk_sched_primitive.c && (rsc->cluster->no_quorum_policy == pcmk_no_quorum_freeze)) { rsc 489 lib/pacemaker/pcmk_sched_primitive.c rsc->id, pcmk_role_text(rsc->role), rsc 490 lib/pacemaker/pcmk_sched_primitive.c pcmk_role_text(rsc->next_role)); rsc 491 lib/pacemaker/pcmk_sched_primitive.c pe__set_next_role(rsc, rsc->role, rsc 495 lib/pacemaker/pcmk_sched_primitive.c pe__show_node_scores(!pcmk_is_set(rsc->cluster->flags, rsc 497 lib/pacemaker/pcmk_sched_primitive.c rsc, __func__, rsc->allowed_nodes, rsc->cluster); rsc 500 lib/pacemaker/pcmk_sched_primitive.c if (pcmk_is_set(rsc->cluster->flags, pcmk_sched_fencing_enabled) rsc 501 lib/pacemaker/pcmk_sched_primitive.c && !pcmk_is_set(rsc->cluster->flags, pcmk_sched_have_fencing)) { rsc 502 lib/pacemaker/pcmk_sched_primitive.c pcmk__clear_rsc_flags(rsc, pcmk_rsc_managed); rsc 505 lib/pacemaker/pcmk_sched_primitive.c if (!pcmk_is_set(rsc->flags, pcmk_rsc_managed)) { rsc 510 lib/pacemaker/pcmk_sched_primitive.c pe__set_next_role(rsc, rsc->role, "unmanaged"); rsc 511 lib/pacemaker/pcmk_sched_primitive.c assign_to = pcmk__current_node(rsc); rsc 514 lib/pacemaker/pcmk_sched_primitive.c } else if (rsc->role == pcmk_role_promoted) { rsc 516 lib/pacemaker/pcmk_sched_primitive.c } else if (pcmk_is_set(rsc->flags, pcmk_rsc_failed)) { rsc 521 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_info(rsc, "Unmanaged resource %s assigned to %s: %s", rsc->id, rsc 524 lib/pacemaker/pcmk_sched_primitive.c pcmk__assign_resource(rsc, assign_to, true, stop_if_fail); rsc 526 lib/pacemaker/pcmk_sched_primitive.c } else if (pcmk_is_set(rsc->cluster->flags, pcmk_sched_stop_all)) { rsc 529 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_debug(rsc, rsc 531 lib/pacemaker/pcmk_sched_primitive.c rsc->id); rsc 533 lib/pacemaker/pcmk_sched_primitive.c pcmk__assign_resource(rsc, NULL, true, stop_if_fail); rsc 535 lib/pacemaker/pcmk_sched_primitive.c } else if (!assign_best_node(rsc, prefer, stop_if_fail)) { rsc 537 lib/pacemaker/pcmk_sched_primitive.c if (!pcmk_is_set(rsc->flags, pcmk_rsc_removed)) { rsc 538 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_info(rsc, "Resource %s cannot run anywhere", rsc->id); rsc 539 lib/pacemaker/pcmk_sched_primitive.c } else if ((rsc->running_on != NULL) && stop_if_fail) { rsc 540 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_info(rsc, "Stopping removed resource %s", rsc->id); rsc 544 lib/pacemaker/pcmk_sched_primitive.c pcmk__clear_rsc_flags(rsc, pcmk_rsc_assigning); rsc 546 lib/pacemaker/pcmk_sched_primitive.c if (rsc->is_remote_node) { rsc 547 lib/pacemaker/pcmk_sched_primitive.c remote_connection_assigned(rsc); rsc 550 lib/pacemaker/pcmk_sched_primitive.c return rsc->allocated_to; rsc 565 lib/pacemaker/pcmk_sched_primitive.c schedule_restart_actions(pcmk_resource_t *rsc, pcmk_node_t *current, rsc 568 lib/pacemaker/pcmk_sched_primitive.c enum rsc_role_e role = rsc->role; rsc 572 lib/pacemaker/pcmk_sched_primitive.c pcmk__set_rsc_flags(rsc, pcmk_rsc_restarting); rsc 577 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_trace(rsc, "Creating %s action to take %s down from %s to %s", rsc 578 lib/pacemaker/pcmk_sched_primitive.c (need_stop? "required" : "optional"), rsc->id, rsc 584 lib/pacemaker/pcmk_sched_primitive.c fn(rsc, current, !need_stop); rsc 589 lib/pacemaker/pcmk_sched_primitive.c while ((rsc->role <= rsc->next_role) && (role != rsc->role) rsc 590 lib/pacemaker/pcmk_sched_primitive.c && !pcmk_is_set(rsc->flags, pcmk_rsc_blocked)) { rsc 593 lib/pacemaker/pcmk_sched_primitive.c next_role = rsc_state_matrix[role][rsc->role]; rsc 597 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_trace(rsc, "Creating %s action to take %s up from %s to %s", rsc 598 lib/pacemaker/pcmk_sched_primitive.c (required? "required" : "optional"), rsc->id, rsc 604 lib/pacemaker/pcmk_sched_primitive.c fn(rsc, rsc->allocated_to, !required); rsc 608 lib/pacemaker/pcmk_sched_primitive.c pcmk__clear_rsc_flags(rsc, pcmk_rsc_restarting); rsc 620 lib/pacemaker/pcmk_sched_primitive.c set_default_next_role(pcmk_resource_t *rsc) rsc 622 lib/pacemaker/pcmk_sched_primitive.c if (rsc->next_role != pcmk_role_unknown) { rsc 626 lib/pacemaker/pcmk_sched_primitive.c if (rsc->allocated_to == NULL) { rsc 627 lib/pacemaker/pcmk_sched_primitive.c pe__set_next_role(rsc, pcmk_role_stopped, "assignment"); rsc 629 lib/pacemaker/pcmk_sched_primitive.c pe__set_next_role(rsc, pcmk_role_started, "assignment"); rsc 641 lib/pacemaker/pcmk_sched_primitive.c create_pending_start(pcmk_resource_t *rsc) rsc 645 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_trace(rsc, rsc 647 lib/pacemaker/pcmk_sched_primitive.c rsc->id); rsc 648 lib/pacemaker/pcmk_sched_primitive.c start = start_action(rsc, rsc->allocated_to, TRUE); rsc 659 lib/pacemaker/pcmk_sched_primitive.c schedule_role_transition_actions(pcmk_resource_t *rsc) rsc 661 lib/pacemaker/pcmk_sched_primitive.c enum rsc_role_e role = rsc->role; rsc 663 lib/pacemaker/pcmk_sched_primitive.c while (role != rsc->next_role) { rsc 664 lib/pacemaker/pcmk_sched_primitive.c enum rsc_role_e next_role = rsc_state_matrix[role][rsc->next_role]; rsc 667 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_trace(rsc, rsc 670 lib/pacemaker/pcmk_sched_primitive.c rsc->id, pcmk_role_text(role), rsc 672 lib/pacemaker/pcmk_sched_primitive.c pcmk_role_text(rsc->next_role)); rsc 677 lib/pacemaker/pcmk_sched_primitive.c fn(rsc, rsc->allocated_to, false); rsc 689 lib/pacemaker/pcmk_sched_primitive.c pcmk__primitive_create_actions(pcmk_resource_t *rsc) rsc 702 lib/pacemaker/pcmk_sched_primitive.c pcmk__assert(pcmk__is_primitive(rsc)); rsc 704 lib/pacemaker/pcmk_sched_primitive.c next_role_source = set_default_next_role(rsc); rsc 705 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_trace(rsc, rsc 708 lib/pacemaker/pcmk_sched_primitive.c rsc->id, pcmk_role_text(rsc->role), rsc 709 lib/pacemaker/pcmk_sched_primitive.c pcmk_role_text(rsc->next_role), next_role_source, rsc 710 lib/pacemaker/pcmk_sched_primitive.c pcmk__node_name(rsc->allocated_to)); rsc 712 lib/pacemaker/pcmk_sched_primitive.c current = rsc->fns->active_node(rsc, &num_all_active, &num_clean_active); rsc 714 lib/pacemaker/pcmk_sched_primitive.c g_list_foreach(rsc->dangling_migrations, pcmk__abort_dangling_migration, rsc 715 lib/pacemaker/pcmk_sched_primitive.c rsc); rsc 717 lib/pacemaker/pcmk_sched_primitive.c if ((current != NULL) && (rsc->allocated_to != NULL) rsc 718 lib/pacemaker/pcmk_sched_primitive.c && !pcmk__same_node(current, rsc->allocated_to) rsc 719 lib/pacemaker/pcmk_sched_primitive.c && (rsc->next_role >= pcmk_role_started)) { rsc 721 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_trace(rsc, "Moving %s from %s to %s", rsc 722 lib/pacemaker/pcmk_sched_primitive.c rsc->id, pcmk__node_name(current), rsc 723 lib/pacemaker/pcmk_sched_primitive.c pcmk__node_name(rsc->allocated_to)); rsc 725 lib/pacemaker/pcmk_sched_primitive.c allow_migrate = pcmk__rsc_can_migrate(rsc, current); rsc 732 lib/pacemaker/pcmk_sched_primitive.c if ((rsc->partial_migration_source != NULL) rsc 733 lib/pacemaker/pcmk_sched_primitive.c && (rsc->partial_migration_target != NULL) rsc 735 lib/pacemaker/pcmk_sched_primitive.c && pcmk__same_node(current, rsc->partial_migration_source) rsc 736 lib/pacemaker/pcmk_sched_primitive.c && pcmk__same_node(rsc->allocated_to, rsc->partial_migration_target)) { rsc 740 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_trace(rsc, rsc 742 lib/pacemaker/pcmk_sched_primitive.c rsc->id, pcmk__node_name(rsc->partial_migration_source), rsc 743 lib/pacemaker/pcmk_sched_primitive.c pcmk__node_name(rsc->partial_migration_target)); rsc 745 lib/pacemaker/pcmk_sched_primitive.c } else if ((rsc->partial_migration_source != NULL) rsc 746 lib/pacemaker/pcmk_sched_primitive.c || (rsc->partial_migration_target != NULL)) { rsc 753 lib/pacemaker/pcmk_sched_primitive.c rsc->id, pcmk__node_name(rsc->partial_migration_source), rsc 754 lib/pacemaker/pcmk_sched_primitive.c pcmk__node_name(rsc->partial_migration_target)); rsc 759 lib/pacemaker/pcmk_sched_primitive.c rsc->id, pcmk__node_name(rsc->partial_migration_source), rsc 760 lib/pacemaker/pcmk_sched_primitive.c pcmk__node_name(rsc->partial_migration_target)); rsc 763 lib/pacemaker/pcmk_sched_primitive.c rsc->partial_migration_source = rsc->partial_migration_target = NULL; rsc 766 lib/pacemaker/pcmk_sched_primitive.c } else if (pcmk_is_set(rsc->flags, pcmk_rsc_needs_fencing)) { rsc 780 lib/pacemaker/pcmk_sched_primitive.c const char *class = crm_element_value(rsc->xml, PCMK_XA_CLASS); rsc 784 lib/pacemaker/pcmk_sched_primitive.c pcmk__s(class, "Untyped"), rsc->id, num_all_active, rsc 785 lib/pacemaker/pcmk_sched_primitive.c pcmk__multiply_active_text(rsc->recovery_type)); rsc 790 lib/pacemaker/pcmk_sched_primitive.c switch (rsc->recovery_type) { rsc 796 lib/pacemaker/pcmk_sched_primitive.c pcmk__set_rsc_flags(rsc, pcmk_rsc_stop_unexpected); rsc 803 lib/pacemaker/pcmk_sched_primitive.c pcmk__clear_rsc_flags(rsc, pcmk_rsc_stop_unexpected); rsc 806 lib/pacemaker/pcmk_sched_primitive.c if (pcmk_is_set(rsc->flags, pcmk_rsc_start_pending)) { rsc 807 lib/pacemaker/pcmk_sched_primitive.c create_pending_start(rsc); rsc 813 lib/pacemaker/pcmk_sched_primitive.c } else if (pcmk_is_set(rsc->flags, pcmk_rsc_failed)) { rsc 814 lib/pacemaker/pcmk_sched_primitive.c if (pcmk_is_set(rsc->flags, pcmk_rsc_stop_if_failed)) { rsc 816 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_trace(rsc, "Recovering %s", rsc->id); rsc 818 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_trace(rsc, "Recovering %s by demotion", rsc->id); rsc 819 lib/pacemaker/pcmk_sched_primitive.c if (rsc->next_role == pcmk_role_promoted) { rsc 824 lib/pacemaker/pcmk_sched_primitive.c } else if (pcmk_is_set(rsc->flags, pcmk_rsc_blocked)) { rsc 825 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_trace(rsc, "Blocking further actions on %s", rsc->id); rsc 828 lib/pacemaker/pcmk_sched_primitive.c } else if ((rsc->role > pcmk_role_started) && (current != NULL) rsc 829 lib/pacemaker/pcmk_sched_primitive.c && (rsc->allocated_to != NULL)) { rsc 832 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_trace(rsc, "Creating start action for promoted resource %s", rsc 833 lib/pacemaker/pcmk_sched_primitive.c rsc->id); rsc 834 lib/pacemaker/pcmk_sched_primitive.c start = start_action(rsc, rsc->allocated_to, TRUE); rsc 837 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_trace(rsc, "%s restart is required for recovery", rsc->id); rsc 843 lib/pacemaker/pcmk_sched_primitive.c schedule_restart_actions(rsc, current, need_stop, need_promote); rsc 846 lib/pacemaker/pcmk_sched_primitive.c schedule_role_transition_actions(rsc); rsc 848 lib/pacemaker/pcmk_sched_primitive.c pcmk__create_recurring_actions(rsc); rsc 851 lib/pacemaker/pcmk_sched_primitive.c pcmk__create_migration_actions(rsc, current); rsc 862 lib/pacemaker/pcmk_sched_primitive.c rsc_avoids_remote_nodes(const pcmk_resource_t *rsc) rsc 867 lib/pacemaker/pcmk_sched_primitive.c g_hash_table_iter_init(&iter, rsc->allowed_nodes); rsc 889 lib/pacemaker/pcmk_sched_primitive.c allowed_nodes_as_list(const pcmk_resource_t *rsc) rsc 893 lib/pacemaker/pcmk_sched_primitive.c if (rsc->allowed_nodes) { rsc 894 lib/pacemaker/pcmk_sched_primitive.c allowed_nodes = g_hash_table_get_values(rsc->allowed_nodes); rsc 911 lib/pacemaker/pcmk_sched_primitive.c pcmk__primitive_internal_constraints(pcmk_resource_t *rsc) rsc 917 lib/pacemaker/pcmk_sched_primitive.c pcmk__assert(pcmk__is_primitive(rsc)); rsc 919 lib/pacemaker/pcmk_sched_primitive.c if (!pcmk_is_set(rsc->flags, pcmk_rsc_managed)) { rsc 920 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_trace(rsc, rsc 922 lib/pacemaker/pcmk_sched_primitive.c "%s", rsc->id); rsc 927 lib/pacemaker/pcmk_sched_primitive.c check_unfencing = !pcmk_is_set(rsc->flags, pcmk_rsc_fence_device) rsc 928 lib/pacemaker/pcmk_sched_primitive.c && pcmk_is_set(rsc->cluster->flags, rsc 930 lib/pacemaker/pcmk_sched_primitive.c && pcmk_is_set(rsc->flags, pcmk_rsc_needs_unfencing); rsc 933 lib/pacemaker/pcmk_sched_primitive.c check_utilization = (g_hash_table_size(rsc->utilization) > 0) rsc 934 lib/pacemaker/pcmk_sched_primitive.c && !pcmk__str_eq(rsc->cluster->placement_strategy, rsc 938 lib/pacemaker/pcmk_sched_primitive.c pcmk__new_ordering(rsc, pcmk__op_key(rsc->id, PCMK_ACTION_STOP, 0), NULL, rsc 939 lib/pacemaker/pcmk_sched_primitive.c rsc, pcmk__op_key(rsc->id, PCMK_ACTION_START, 0), NULL, rsc 943 lib/pacemaker/pcmk_sched_primitive.c rsc->cluster); rsc 946 lib/pacemaker/pcmk_sched_primitive.c if (pcmk_is_set(pe__const_top_resource(rsc, false)->flags, rsc 948 lib/pacemaker/pcmk_sched_primitive.c || (rsc->role > pcmk_role_unpromoted)) { rsc 950 lib/pacemaker/pcmk_sched_primitive.c pcmk__new_ordering(rsc, pcmk__op_key(rsc->id, PCMK_ACTION_DEMOTE, 0), rsc 952 lib/pacemaker/pcmk_sched_primitive.c rsc, pcmk__op_key(rsc->id, PCMK_ACTION_STOP, 0), rsc 954 lib/pacemaker/pcmk_sched_primitive.c pcmk__ar_promoted_then_implies_first, rsc->cluster); rsc 956 lib/pacemaker/pcmk_sched_primitive.c pcmk__new_ordering(rsc, pcmk__op_key(rsc->id, PCMK_ACTION_START, 0), rsc 958 lib/pacemaker/pcmk_sched_primitive.c rsc, pcmk__op_key(rsc->id, PCMK_ACTION_PROMOTE, 0), rsc 960 lib/pacemaker/pcmk_sched_primitive.c pcmk__ar_unrunnable_first_blocks, rsc->cluster); rsc 964 lib/pacemaker/pcmk_sched_primitive.c pcmk__new_ordering(rsc, pcmk__op_key(rsc->id, PCMK_ACTION_LRM_DELETE, 0), rsc 965 lib/pacemaker/pcmk_sched_primitive.c NULL, rsc, rsc 966 lib/pacemaker/pcmk_sched_primitive.c pcmk__op_key(rsc->id, PCMK_ACTION_MONITOR, 0), rsc 969 lib/pacemaker/pcmk_sched_primitive.c rsc->cluster); rsc 972 lib/pacemaker/pcmk_sched_primitive.c if (check_unfencing || check_utilization || (rsc->container != NULL)) { rsc 973 lib/pacemaker/pcmk_sched_primitive.c allowed_nodes = allowed_nodes_as_list(rsc); rsc 977 lib/pacemaker/pcmk_sched_primitive.c g_list_foreach(allowed_nodes, pcmk__order_restart_vs_unfence, rsc); rsc 981 lib/pacemaker/pcmk_sched_primitive.c pcmk__create_utilization_constraints(rsc, allowed_nodes); rsc 984 lib/pacemaker/pcmk_sched_primitive.c if (rsc->container != NULL) { rsc 987 lib/pacemaker/pcmk_sched_primitive.c if (rsc->is_remote_node) { rsc 993 lib/pacemaker/pcmk_sched_primitive.c if (!pcmk_is_set(rsc->flags, pcmk_rsc_remote_nesting_allowed)) { rsc 994 lib/pacemaker/pcmk_sched_primitive.c rsc_avoids_remote_nodes(rsc->container); rsc 1003 lib/pacemaker/pcmk_sched_primitive.c pcmk__order_resource_actions(rsc->container, PCMK_ACTION_MONITOR, rsc 1004 lib/pacemaker/pcmk_sched_primitive.c rsc, PCMK_ACTION_STOP, rsc 1014 lib/pacemaker/pcmk_sched_primitive.c } else if (rsc->container->is_remote_node) { rsc 1015 lib/pacemaker/pcmk_sched_primitive.c remote_rsc = rsc->container; rsc 1017 lib/pacemaker/pcmk_sched_primitive.c remote_rsc = pe__resource_contains_guest_node(rsc->cluster, rsc 1018 lib/pacemaker/pcmk_sched_primitive.c rsc->container); rsc 1041 lib/pacemaker/pcmk_sched_primitive.c rsc->id, rsc->container->id); rsc 1043 lib/pacemaker/pcmk_sched_primitive.c pcmk__new_ordering(rsc->container, rsc 1044 lib/pacemaker/pcmk_sched_primitive.c pcmk__op_key(rsc->container->id, rsc 1046 lib/pacemaker/pcmk_sched_primitive.c NULL, rsc, rsc 1047 lib/pacemaker/pcmk_sched_primitive.c pcmk__op_key(rsc->id, PCMK_ACTION_START, 0), rsc 1051 lib/pacemaker/pcmk_sched_primitive.c rsc->cluster); rsc 1053 lib/pacemaker/pcmk_sched_primitive.c pcmk__new_ordering(rsc, rsc 1054 lib/pacemaker/pcmk_sched_primitive.c pcmk__op_key(rsc->id, PCMK_ACTION_STOP, 0), rsc 1056 lib/pacemaker/pcmk_sched_primitive.c rsc->container, rsc 1057 lib/pacemaker/pcmk_sched_primitive.c pcmk__op_key(rsc->container->id, rsc 1059 lib/pacemaker/pcmk_sched_primitive.c NULL, pcmk__ar_then_implies_first, rsc->cluster); rsc 1061 lib/pacemaker/pcmk_sched_primitive.c if (pcmk_is_set(rsc->flags, pcmk_rsc_remote_nesting_allowed)) { rsc 1066 lib/pacemaker/pcmk_sched_primitive.c pcmk__new_colocation("#resource-with-container", NULL, score, rsc, rsc 1067 lib/pacemaker/pcmk_sched_primitive.c rsc->container, NULL, NULL, rsc 1072 lib/pacemaker/pcmk_sched_primitive.c if (rsc->is_remote_node rsc 1073 lib/pacemaker/pcmk_sched_primitive.c || pcmk_is_set(rsc->flags, pcmk_rsc_fence_device)) { rsc 1077 lib/pacemaker/pcmk_sched_primitive.c rsc_avoids_remote_nodes(rsc); rsc 1140 lib/pacemaker/pcmk_sched_primitive.c pcmk__with_primitive_colocations(const pcmk_resource_t *rsc, rsc 1143 lib/pacemaker/pcmk_sched_primitive.c pcmk__assert(pcmk__is_primitive(rsc) && (list != NULL)); rsc 1145 lib/pacemaker/pcmk_sched_primitive.c if (rsc == orig_rsc) { rsc 1149 lib/pacemaker/pcmk_sched_primitive.c pcmk__add_with_this_list(list, rsc->rsc_cons_lhs, orig_rsc); rsc 1150 lib/pacemaker/pcmk_sched_primitive.c if (rsc->parent != NULL) { rsc 1151 lib/pacemaker/pcmk_sched_primitive.c rsc->parent->cmds->with_this_colocations(rsc->parent, orig_rsc, list); rsc 1155 lib/pacemaker/pcmk_sched_primitive.c for (GList *iter = rsc->rsc_cons_lhs; iter != NULL; iter = iter->next) { rsc 1169 lib/pacemaker/pcmk_sched_primitive.c pcmk__primitive_with_colocations(const pcmk_resource_t *rsc, rsc 1172 lib/pacemaker/pcmk_sched_primitive.c pcmk__assert(pcmk__is_primitive(rsc) && (list != NULL)); rsc 1174 lib/pacemaker/pcmk_sched_primitive.c if (rsc == orig_rsc) { rsc 1178 lib/pacemaker/pcmk_sched_primitive.c pcmk__add_this_with_list(list, rsc->rsc_cons, orig_rsc); rsc 1179 lib/pacemaker/pcmk_sched_primitive.c if (rsc->parent != NULL) { rsc 1180 lib/pacemaker/pcmk_sched_primitive.c rsc->parent->cmds->this_with_colocations(rsc->parent, orig_rsc, list); rsc 1184 lib/pacemaker/pcmk_sched_primitive.c for (GList *iter = rsc->rsc_cons; iter != NULL; iter = iter->next) { rsc 1225 lib/pacemaker/pcmk_sched_primitive.c is_expected_node(const pcmk_resource_t *rsc, const pcmk_node_t *node) rsc 1227 lib/pacemaker/pcmk_sched_primitive.c return pcmk_all_flags_set(rsc->flags, rsc 1229 lib/pacemaker/pcmk_sched_primitive.c && (rsc->next_role > pcmk_role_stopped) rsc 1230 lib/pacemaker/pcmk_sched_primitive.c && pcmk__same_node(rsc->allocated_to, node); rsc 1242 lib/pacemaker/pcmk_sched_primitive.c stop_resource(pcmk_resource_t *rsc, pcmk_node_t *node, bool optional) rsc 1244 lib/pacemaker/pcmk_sched_primitive.c for (GList *iter = rsc->running_on; iter != NULL; iter = iter->next) { rsc 1248 lib/pacemaker/pcmk_sched_primitive.c if (is_expected_node(rsc, current)) { rsc 1253 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_trace(rsc, rsc 1256 lib/pacemaker/pcmk_sched_primitive.c rsc->id, pcmk__node_name(current)); rsc 1260 lib/pacemaker/pcmk_sched_primitive.c if (rsc->partial_migration_target != NULL) { rsc 1262 lib/pacemaker/pcmk_sched_primitive.c if (pcmk__same_node(current, rsc->partial_migration_target) rsc 1263 lib/pacemaker/pcmk_sched_primitive.c && pcmk__same_node(current, rsc->allocated_to)) { rsc 1264 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_trace(rsc, rsc 1267 lib/pacemaker/pcmk_sched_primitive.c rsc->id, pcmk__node_name(current)); rsc 1270 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_trace(rsc, rsc 1273 lib/pacemaker/pcmk_sched_primitive.c rsc->id, pcmk__node_name(current)); rsc 1278 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_trace(rsc, "Scheduling stop of %s on %s", rsc 1279 lib/pacemaker/pcmk_sched_primitive.c rsc->id, pcmk__node_name(current)); rsc 1280 lib/pacemaker/pcmk_sched_primitive.c stop = stop_action(rsc, current, optional); rsc 1282 lib/pacemaker/pcmk_sched_primitive.c if (rsc->allocated_to == NULL) { rsc 1284 lib/pacemaker/pcmk_sched_primitive.c } else if (pcmk_all_flags_set(rsc->flags, pcmk_rsc_restarting rsc 1293 lib/pacemaker/pcmk_sched_primitive.c if (!pcmk_is_set(rsc->flags, pcmk_rsc_managed)) { rsc 1297 lib/pacemaker/pcmk_sched_primitive.c if (pcmk_is_set(rsc->cluster->flags, pcmk_sched_remove_after_stop)) { rsc 1298 lib/pacemaker/pcmk_sched_primitive.c pcmk__schedule_cleanup(rsc, current, optional); rsc 1301 lib/pacemaker/pcmk_sched_primitive.c if (pcmk_is_set(rsc->flags, pcmk_rsc_needs_unfencing)) { rsc 1303 lib/pacemaker/pcmk_sched_primitive.c NULL, false, rsc->cluster); rsc 1308 lib/pacemaker/pcmk_sched_primitive.c rsc->id, pcmk__node_name(current)); rsc 1323 lib/pacemaker/pcmk_sched_primitive.c start_resource(pcmk_resource_t *rsc, pcmk_node_t *node, bool optional) rsc 1329 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_trace(rsc, "Scheduling %s start of %s on %s (score %d)", rsc 1330 lib/pacemaker/pcmk_sched_primitive.c (optional? "optional" : "required"), rsc->id, rsc 1332 lib/pacemaker/pcmk_sched_primitive.c start = start_action(rsc, node, TRUE); rsc 1334 lib/pacemaker/pcmk_sched_primitive.c pcmk__order_vs_unfence(rsc, node, start, pcmk__ar_first_implies_then); rsc 1340 lib/pacemaker/pcmk_sched_primitive.c if (is_expected_node(rsc, node)) { rsc 1344 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_trace(rsc, rsc 1347 lib/pacemaker/pcmk_sched_primitive.c rsc->id, pcmk__node_name(node)); rsc 1361 lib/pacemaker/pcmk_sched_primitive.c promote_resource(pcmk_resource_t *rsc, pcmk_node_t *node, bool optional) rsc 1370 lib/pacemaker/pcmk_sched_primitive.c action_list = pe__resource_actions(rsc, node, PCMK_ACTION_START, true); rsc 1381 lib/pacemaker/pcmk_sched_primitive.c pcmk_action_t *promote = promote_action(rsc, node, optional); rsc 1383 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_trace(rsc, "Scheduling %s promotion of %s on %s", rsc 1384 lib/pacemaker/pcmk_sched_primitive.c (optional? "optional" : "required"), rsc->id, rsc 1387 lib/pacemaker/pcmk_sched_primitive.c if (is_expected_node(rsc, node)) { rsc 1391 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_trace(rsc, rsc 1394 lib/pacemaker/pcmk_sched_primitive.c rsc->id, pcmk__node_name(node)); rsc 1398 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_trace(rsc, "Not promoting %s on %s: start unrunnable", rsc 1399 lib/pacemaker/pcmk_sched_primitive.c rsc->id, pcmk__node_name(node)); rsc 1400 lib/pacemaker/pcmk_sched_primitive.c action_list = pe__resource_actions(rsc, node, PCMK_ACTION_PROMOTE, rsc 1420 lib/pacemaker/pcmk_sched_primitive.c demote_resource(pcmk_resource_t *rsc, pcmk_node_t *node, bool optional) rsc 1427 lib/pacemaker/pcmk_sched_primitive.c for (GList *iter = rsc->running_on; iter != NULL; iter = iter->next) { rsc 1430 lib/pacemaker/pcmk_sched_primitive.c if (is_expected_node(rsc, current)) { rsc 1431 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_trace(rsc, rsc 1434 lib/pacemaker/pcmk_sched_primitive.c rsc->id, pcmk__node_name(current)); rsc 1436 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_trace(rsc, "Scheduling %s demotion of %s on %s", rsc 1437 lib/pacemaker/pcmk_sched_primitive.c (optional? "optional" : "required"), rsc->id, rsc 1439 lib/pacemaker/pcmk_sched_primitive.c demote_action(rsc, current, optional); rsc 1445 lib/pacemaker/pcmk_sched_primitive.c assert_role_error(pcmk_resource_t *rsc, pcmk_node_t *node, bool optional) rsc 1459 lib/pacemaker/pcmk_sched_primitive.c pcmk__schedule_cleanup(pcmk_resource_t *rsc, const pcmk_node_t *node, rsc 1469 lib/pacemaker/pcmk_sched_primitive.c CRM_CHECK((rsc != NULL) && (node != NULL), return); rsc 1471 lib/pacemaker/pcmk_sched_primitive.c if (pcmk_is_set(rsc->flags, pcmk_rsc_failed)) { rsc 1472 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_trace(rsc, "Skipping clean-up of %s on %s: resource failed", rsc 1473 lib/pacemaker/pcmk_sched_primitive.c rsc->id, pcmk__node_name(node)); rsc 1478 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_trace(rsc, "Skipping clean-up of %s on %s: node unavailable", rsc 1479 lib/pacemaker/pcmk_sched_primitive.c rsc->id, pcmk__node_name(node)); rsc 1484 lib/pacemaker/pcmk_sched_primitive.c rsc->id, pcmk__node_name(node)); rsc 1485 lib/pacemaker/pcmk_sched_primitive.c delete_action(rsc, node, optional); rsc 1488 lib/pacemaker/pcmk_sched_primitive.c pcmk__order_resource_actions(rsc, PCMK_ACTION_STOP, rsc 1489 lib/pacemaker/pcmk_sched_primitive.c rsc, PCMK_ACTION_DELETE, flag); rsc 1490 lib/pacemaker/pcmk_sched_primitive.c pcmk__order_resource_actions(rsc, PCMK_ACTION_DELETE, rsc 1491 lib/pacemaker/pcmk_sched_primitive.c rsc, PCMK_ACTION_START, flag); rsc 1502 lib/pacemaker/pcmk_sched_primitive.c pcmk__primitive_add_graph_meta(const pcmk_resource_t *rsc, xmlNode *xml) rsc 1508 lib/pacemaker/pcmk_sched_primitive.c pcmk__assert(pcmk__is_primitive(rsc) && (xml != NULL)); rsc 1514 lib/pacemaker/pcmk_sched_primitive.c value = g_hash_table_lookup(rsc->meta, PCMK__META_CLONE); rsc 1522 lib/pacemaker/pcmk_sched_primitive.c value = g_hash_table_lookup(rsc->meta, PCMK_META_REMOTE_NODE); rsc 1533 lib/pacemaker/pcmk_sched_primitive.c for (parent = rsc; parent != NULL; parent = parent->parent) { rsc 1544 lib/pacemaker/pcmk_sched_primitive.c value = g_hash_table_lookup(rsc->meta, "external-ip"); rsc 1552 lib/pacemaker/pcmk_sched_primitive.c pcmk__primitive_add_utilization(const pcmk_resource_t *rsc, rsc 1556 lib/pacemaker/pcmk_sched_primitive.c pcmk__assert(pcmk__is_primitive(rsc) && (orig_rsc != NULL) rsc 1559 lib/pacemaker/pcmk_sched_primitive.c if (!pcmk_is_set(rsc->flags, pcmk_rsc_unassigned)) { rsc 1565 lib/pacemaker/pcmk_sched_primitive.c orig_rsc->id, rsc->id); rsc 1566 lib/pacemaker/pcmk_sched_primitive.c pcmk__release_node_capacity(utilization, rsc); rsc 1610 lib/pacemaker/pcmk_sched_primitive.c pcmk_resource_t *rsc = (pcmk_resource_t *) user_data; rsc 1612 lib/pacemaker/pcmk_sched_primitive.c if (strcmp(node->details->uname, rsc->lock_node->details->uname) != 0) { rsc 1613 lib/pacemaker/pcmk_sched_primitive.c resource_location(rsc, node, -PCMK_SCORE_INFINITY, rsc 1614 lib/pacemaker/pcmk_sched_primitive.c PCMK_OPT_SHUTDOWN_LOCK, rsc->cluster); rsc 1620 lib/pacemaker/pcmk_sched_primitive.c pcmk__primitive_shutdown_lock(pcmk_resource_t *rsc) rsc 1623 lib/pacemaker/pcmk_sched_primitive.c pcmk__assert(pcmk__is_primitive(rsc)); rsc 1626 lib/pacemaker/pcmk_sched_primitive.c if (pcmk_is_set(rsc->flags, pcmk_rsc_fence_device) rsc 1627 lib/pacemaker/pcmk_sched_primitive.c || rsc->is_remote_node) { rsc 1631 lib/pacemaker/pcmk_sched_primitive.c if (rsc->lock_node != NULL) { rsc 1634 lib/pacemaker/pcmk_sched_primitive.c if (rsc->running_on != NULL) { rsc 1639 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_info(rsc, rsc 1641 lib/pacemaker/pcmk_sched_primitive.c "because %s is already active", rsc->id); rsc 1642 lib/pacemaker/pcmk_sched_primitive.c pe__clear_resource_history(rsc, rsc->lock_node); rsc 1643 lib/pacemaker/pcmk_sched_primitive.c rsc->lock_node = NULL; rsc 1644 lib/pacemaker/pcmk_sched_primitive.c rsc->lock_time = 0; rsc 1648 lib/pacemaker/pcmk_sched_primitive.c } else if (pcmk__list_of_1(rsc->running_on)) { rsc 1649 lib/pacemaker/pcmk_sched_primitive.c pcmk_node_t *node = rsc->running_on->data; rsc 1653 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_debug(rsc, rsc 1655 lib/pacemaker/pcmk_sched_primitive.c rsc->id, pcmk__node_name(node)); rsc 1657 lib/pacemaker/pcmk_sched_primitive.c rsc->lock_node = node; rsc 1658 lib/pacemaker/pcmk_sched_primitive.c rsc->lock_time = shutdown_time(node); rsc 1663 lib/pacemaker/pcmk_sched_primitive.c if (rsc->lock_node == NULL) { rsc 1668 lib/pacemaker/pcmk_sched_primitive.c if (rsc->cluster->shutdown_lock > 0) { rsc 1669 lib/pacemaker/pcmk_sched_primitive.c time_t lock_expiration = rsc->lock_time + rsc->cluster->shutdown_lock; rsc 1671 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_info(rsc, "Locking %s to %s due to shutdown (expires @%lld)", rsc 1672 lib/pacemaker/pcmk_sched_primitive.c rsc->id, pcmk__node_name(rsc->lock_node), rsc 1674 lib/pacemaker/pcmk_sched_primitive.c pe__update_recheck_time(++lock_expiration, rsc->cluster, rsc 1677 lib/pacemaker/pcmk_sched_primitive.c pcmk__rsc_info(rsc, "Locking %s to %s due to shutdown", rsc 1678 lib/pacemaker/pcmk_sched_primitive.c rsc->id, pcmk__node_name(rsc->lock_node)); rsc 1682 lib/pacemaker/pcmk_sched_primitive.c g_list_foreach(rsc->cluster->nodes, ban_if_not_locked, rsc); rsc 28 lib/pacemaker/pcmk_sched_probes.c add_expected_result(pcmk_action_t *probe, const pcmk_resource_t *rsc, rsc 32 lib/pacemaker/pcmk_sched_probes.c pcmk_node_t *running = pe_find_node_id(rsc->running_on, node->details->id); rsc 38 lib/pacemaker/pcmk_sched_probes.c } else if (rsc->role == pcmk_role_promoted) { rsc 58 lib/pacemaker/pcmk_sched_probes.c pcmk_resource_t *rsc = (pcmk_resource_t *) iter->data; rsc 60 lib/pacemaker/pcmk_sched_probes.c if (rsc->cmds->create_probe(rsc, node)) { rsc 128 lib/pacemaker/pcmk_sched_probes.c probe_action(pcmk_resource_t *rsc, pcmk_node_t *node) rsc 131 lib/pacemaker/pcmk_sched_probes.c char *key = pcmk__op_key(rsc->id, PCMK_ACTION_MONITOR, 0); rsc 134 lib/pacemaker/pcmk_sched_probes.c pcmk_role_text(rsc->role), rsc->id, pcmk__node_name(node)); rsc 136 lib/pacemaker/pcmk_sched_probes.c probe = custom_action(rsc, key, PCMK_ACTION_MONITOR, node, FALSE, rsc 137 lib/pacemaker/pcmk_sched_probes.c rsc->cluster); rsc 140 lib/pacemaker/pcmk_sched_probes.c pcmk__order_vs_unfence(rsc, node, probe, pcmk__ar_ordered); rsc 141 lib/pacemaker/pcmk_sched_probes.c add_expected_result(probe, rsc, node); rsc 157 lib/pacemaker/pcmk_sched_probes.c pcmk__probe_rsc_on_node(pcmk_resource_t *rsc, pcmk_node_t *node) rsc 162 lib/pacemaker/pcmk_sched_probes.c pcmk_resource_t *top = uber_parent(rsc); rsc 165 lib/pacemaker/pcmk_sched_probes.c pcmk__assert((rsc != NULL) && (node != NULL)); rsc 167 lib/pacemaker/pcmk_sched_probes.c if (!pcmk_is_set(rsc->cluster->flags, pcmk_sched_probe_resources)) { rsc 173 lib/pacemaker/pcmk_sched_probes.c if (pcmk_is_set(rsc->flags, pcmk_rsc_fence_device)) { rsc 178 lib/pacemaker/pcmk_sched_probes.c && pe__resource_contains_guest_node(rsc->cluster, rsc)) { rsc 182 lib/pacemaker/pcmk_sched_probes.c } else if (rsc->is_remote_node) { rsc 189 lib/pacemaker/pcmk_sched_probes.c if (rsc->children != NULL) { rsc 190 lib/pacemaker/pcmk_sched_probes.c return pcmk__probe_resource_list(rsc->children, node); rsc 193 lib/pacemaker/pcmk_sched_probes.c if ((rsc->container != NULL) && !rsc->is_remote_node) { rsc 197 lib/pacemaker/pcmk_sched_probes.c } else if (pcmk_is_set(rsc->flags, pcmk_rsc_removed)) { rsc 201 lib/pacemaker/pcmk_sched_probes.c } else if (g_hash_table_lookup(rsc->known_on, node->details->id) != NULL) { rsc 206 lib/pacemaker/pcmk_sched_probes.c allowed = g_hash_table_lookup(rsc->allowed_nodes, node->details->id); rsc 208 lib/pacemaker/pcmk_sched_probes.c if (rsc->exclusive_discover || top->exclusive_discover) { rsc 250 lib/pacemaker/pcmk_sched_probes.c NULL, pcmk__ar_ordered, rsc->cluster); rsc 256 lib/pacemaker/pcmk_sched_probes.c probe = probe_action(rsc, node); rsc 264 lib/pacemaker/pcmk_sched_probes.c top = rsc; rsc 276 lib/pacemaker/pcmk_sched_probes.c pcmk__new_ordering(rsc, NULL, probe, rsc 278 lib/pacemaker/pcmk_sched_probes.c flags, rsc->cluster); rsc 279 lib/pacemaker/pcmk_sched_probes.c pcmk__new_ordering(rsc, NULL, probe, top, reload_key(rsc), NULL, rsc 280 lib/pacemaker/pcmk_sched_probes.c pcmk__ar_ordered, rsc->cluster); rsc 285 lib/pacemaker/pcmk_sched_probes.c pcmk__rsc_trace(rsc, rsc 287 lib/pacemaker/pcmk_sched_probes.c rsc->id, node->details->id, reason); rsc 484 lib/pacemaker/pcmk_sched_probes.c if ((after->action->rsc->variant <= pcmk_rsc_variant_group) rsc 488 lib/pacemaker/pcmk_sched_probes.c || (pe__const_top_resource(probe->rsc, false) != after->action->rsc) rsc 504 lib/pacemaker/pcmk_sched_probes.c if (then->action->rsc->running_on rsc 505 lib/pacemaker/pcmk_sched_probes.c || (pe__const_top_resource(then->action->rsc, false) rsc 506 lib/pacemaker/pcmk_sched_probes.c != after->action->rsc) rsc 547 lib/pacemaker/pcmk_sched_probes.c if ((after == NULL) || (probe == NULL) || !pcmk__is_primitive(probe->rsc) rsc 565 lib/pacemaker/pcmk_sched_probes.c if (pcmk__is_primitive(after->rsc) && (probe->rsc != after->rsc)) { rsc 570 lib/pacemaker/pcmk_sched_probes.c then_actions = pe__resource_actions(after->rsc, NULL, rsc 575 lib/pacemaker/pcmk_sched_probes.c then_actions = pe__resource_actions(after->rsc, NULL, rsc 593 lib/pacemaker/pcmk_sched_probes.c if ((after->rsc != NULL) rsc 594 lib/pacemaker/pcmk_sched_probes.c && (after->rsc->variant > pcmk_rsc_variant_group)) { rsc 595 lib/pacemaker/pcmk_sched_probes.c const char *interleave_s = g_hash_table_lookup(after->rsc->meta, rsc 600 lib/pacemaker/pcmk_sched_probes.c compatible_rsc = pcmk__find_compatible_instance(probe->rsc, rsc 601 lib/pacemaker/pcmk_sched_probes.c after->rsc, rsc 631 lib/pacemaker/pcmk_sched_probes.c if ((after->rsc == NULL) rsc 632 lib/pacemaker/pcmk_sched_probes.c || (after->rsc->variant < pcmk_rsc_variant_group) rsc 633 lib/pacemaker/pcmk_sched_probes.c || (probe->rsc->parent == after->rsc) rsc 634 lib/pacemaker/pcmk_sched_probes.c || (after_wrapper->action->rsc == NULL) rsc 635 lib/pacemaker/pcmk_sched_probes.c || (after_wrapper->action->rsc->variant > pcmk_rsc_variant_group) rsc 636 lib/pacemaker/pcmk_sched_probes.c || (after->rsc != after_wrapper->action->rsc->parent)) { rsc 643 lib/pacemaker/pcmk_sched_probes.c if ((after->rsc->variant > pcmk_rsc_variant_group) && interleave rsc 645 lib/pacemaker/pcmk_sched_probes.c || (compatible_rsc != after_wrapper->action->rsc))) { rsc 687 lib/pacemaker/pcmk_sched_probes.c pcmk_resource_t *rsc = data; rsc 691 lib/pacemaker/pcmk_sched_probes.c if (!pcmk__is_primitive(rsc)) { rsc 692 lib/pacemaker/pcmk_sched_probes.c g_list_foreach(rsc->children, add_start_restart_orderings_for_rsc, rsc 698 lib/pacemaker/pcmk_sched_probes.c probes = pe__resource_actions(rsc, NULL, PCMK_ACTION_MONITOR, FALSE); rsc 711 lib/pacemaker/pcmk_sched_probes.c clear_actions_tracking_flag(rsc->cluster); rsc 760 lib/pacemaker/pcmk_sched_probes.c pcmk_resource_t *rsc = (pcmk_resource_t *) iter->data; rsc 766 lib/pacemaker/pcmk_sched_probes.c actions = pe__resource_actions(rsc, NULL, PCMK_ACTION_START, FALSE); rsc 774 lib/pacemaker/pcmk_sched_probes.c crm_debug("No start action for %s", rsc->id); rsc 778 lib/pacemaker/pcmk_sched_probes.c probes = pe__resource_actions(rsc, NULL, PCMK_ACTION_MONITOR, FALSE); rsc 786 lib/pacemaker/pcmk_sched_probes.c pcmk_resource_t *first_rsc = first->rsc; rsc 798 lib/pacemaker/pcmk_sched_probes.c pcmk__assert(before->action->rsc != NULL); rsc 799 lib/pacemaker/pcmk_sched_probes.c first_rsc = before->action->rsc; rsc 812 lib/pacemaker/pcmk_sched_probes.c == pe__const_top_resource(start->rsc, false)) { rsc 81 lib/pacemaker/pcmk_sched_promotable.c check_for_role_change(const pcmk_resource_t *rsc, bool *demoting, rsc 87 lib/pacemaker/pcmk_sched_promotable.c if (rsc->children != NULL) { rsc 88 lib/pacemaker/pcmk_sched_promotable.c for (iter = rsc->children; iter != NULL; iter = iter->next) { rsc 95 lib/pacemaker/pcmk_sched_promotable.c for (iter = rsc->actions; iter != NULL; iter = iter->next) { rsc 166 lib/pacemaker/pcmk_sched_promotable.c node_to_be_promoted_on(const pcmk_resource_t *rsc) rsc 173 lib/pacemaker/pcmk_sched_promotable.c for (GList *iter = rsc->children; iter != NULL; iter = iter->next) { rsc 177 lib/pacemaker/pcmk_sched_promotable.c pcmk__rsc_trace(rsc, rsc 179 lib/pacemaker/pcmk_sched_promotable.c rsc->id, child->id); rsc 184 lib/pacemaker/pcmk_sched_promotable.c node = rsc->fns->location(rsc, NULL, FALSE); rsc 186 lib/pacemaker/pcmk_sched_promotable.c pcmk__rsc_trace(rsc, "%s can't be promoted because it won't be active", rsc 187 lib/pacemaker/pcmk_sched_promotable.c rsc->id); rsc 190 lib/pacemaker/pcmk_sched_promotable.c } else if (!pcmk_is_set(rsc->flags, pcmk_rsc_managed)) { rsc 191 lib/pacemaker/pcmk_sched_promotable.c if (rsc->fns->state(rsc, TRUE) == pcmk_role_promoted) { rsc 193 lib/pacemaker/pcmk_sched_promotable.c rsc->id, pcmk__node_name(node)); rsc 195 lib/pacemaker/pcmk_sched_promotable.c pcmk__rsc_trace(rsc, "%s can't be promoted because it is unmanaged", rsc 196 lib/pacemaker/pcmk_sched_promotable.c rsc->id); rsc 200 lib/pacemaker/pcmk_sched_promotable.c } else if (rsc->priority < 0) { rsc 201 lib/pacemaker/pcmk_sched_promotable.c pcmk__rsc_trace(rsc, rsc 204 lib/pacemaker/pcmk_sched_promotable.c rsc->id, rsc->priority); rsc 208 lib/pacemaker/pcmk_sched_promotable.c pcmk__rsc_trace(rsc, rsc 210 lib/pacemaker/pcmk_sched_promotable.c rsc->id, pcmk__node_name(node)); rsc 214 lib/pacemaker/pcmk_sched_promotable.c parent = pe__const_top_resource(rsc, false); rsc 222 lib/pacemaker/pcmk_sched_promotable.c if (pcmk_is_set(rsc->flags, pcmk_rsc_managed)) { rsc 225 lib/pacemaker/pcmk_sched_promotable.c rsc->id, parent->id, pcmk__node_name(node)); rsc 230 lib/pacemaker/pcmk_sched_promotable.c && pcmk_is_set(rsc->flags, pcmk_rsc_managed)) { rsc 231 lib/pacemaker/pcmk_sched_promotable.c pcmk__rsc_trace(rsc, rsc 234 lib/pacemaker/pcmk_sched_promotable.c rsc->id, pcmk__node_name(node)); rsc 540 lib/pacemaker/pcmk_sched_promotable.c is_allowed(const pcmk_resource_t *rsc, const pcmk_node_t *node) rsc 542 lib/pacemaker/pcmk_sched_promotable.c pcmk_node_t *allowed = g_hash_table_lookup(rsc->allowed_nodes, rsc 558 lib/pacemaker/pcmk_sched_promotable.c promotion_score_applies(const pcmk_resource_t *rsc, const pcmk_node_t *node) rsc 560 lib/pacemaker/pcmk_sched_promotable.c char *id = clone_strip(rsc->id); rsc 561 lib/pacemaker/pcmk_sched_promotable.c const pcmk_resource_t *parent = pe__const_top_resource(rsc, false); rsc 566 lib/pacemaker/pcmk_sched_promotable.c if (!pcmk_is_set(rsc->flags, pcmk_rsc_unique)) { rsc 570 lib/pacemaker/pcmk_sched_promotable.c if (active == rsc) { rsc 588 lib/pacemaker/pcmk_sched_promotable.c if ((rsc->running_on == NULL) && (g_hash_table_size(rsc->known_on) == 0)) { rsc 596 lib/pacemaker/pcmk_sched_promotable.c if ((g_hash_table_lookup(rsc->known_on, node->details->id) != NULL) rsc 597 lib/pacemaker/pcmk_sched_promotable.c || (pe_find_node_id(rsc->running_on, node->details->id) != NULL)) { rsc 600 lib/pacemaker/pcmk_sched_promotable.c pcmk__rsc_trace(rsc, rsc 603 lib/pacemaker/pcmk_sched_promotable.c rsc->id, id, pcmk__node_name(node)); rsc 609 lib/pacemaker/pcmk_sched_promotable.c if (is_allowed(rsc, node)) { rsc 610 lib/pacemaker/pcmk_sched_promotable.c pcmk__rsc_trace(rsc, "Counting %s promotion score (for %s) on %s: %s", rsc 611 lib/pacemaker/pcmk_sched_promotable.c rsc->id, id, pcmk__node_name(node), reason); rsc 616 lib/pacemaker/pcmk_sched_promotable.c pcmk__rsc_trace(rsc, rsc 618 lib/pacemaker/pcmk_sched_promotable.c rsc->id, id, pcmk__node_name(node)); rsc 634 lib/pacemaker/pcmk_sched_promotable.c promotion_attr_value(const pcmk_resource_t *rsc, const pcmk_node_t *node, rsc 642 lib/pacemaker/pcmk_sched_promotable.c if (pcmk_is_set(rsc->flags, pcmk_rsc_unassigned)) { rsc 646 lib/pacemaker/pcmk_sched_promotable.c target = g_hash_table_lookup(rsc->meta, rsc 665 lib/pacemaker/pcmk_sched_promotable.c promotion_score(const pcmk_resource_t *rsc, const pcmk_node_t *node, rsc 677 lib/pacemaker/pcmk_sched_promotable.c CRM_CHECK((rsc != NULL) && (node != NULL), return 0); rsc 682 lib/pacemaker/pcmk_sched_promotable.c if (rsc->children != NULL) { rsc 685 lib/pacemaker/pcmk_sched_promotable.c for (const GList *iter = rsc->children; rsc 700 lib/pacemaker/pcmk_sched_promotable.c if (!promotion_score_applies(rsc, node)) { rsc 708 lib/pacemaker/pcmk_sched_promotable.c name = (rsc->clone_name == NULL)? rsc->id : rsc->clone_name; rsc 710 lib/pacemaker/pcmk_sched_promotable.c attr_value = promotion_attr_value(rsc, node, name); rsc 712 lib/pacemaker/pcmk_sched_promotable.c pcmk__rsc_trace(rsc, "Promotion score for %s on %s = %s", rsc 715 lib/pacemaker/pcmk_sched_promotable.c } else if (!pcmk_is_set(rsc->flags, pcmk_rsc_unique)) { rsc 720 lib/pacemaker/pcmk_sched_promotable.c name = clone_strip(rsc->id); rsc 721 lib/pacemaker/pcmk_sched_promotable.c if (strcmp(rsc->id, name) != 0) { rsc 722 lib/pacemaker/pcmk_sched_promotable.c attr_value = promotion_attr_value(rsc, node, name); rsc 723 lib/pacemaker/pcmk_sched_promotable.c pcmk__rsc_trace(rsc, "Promotion score for %s on %s (for %s) = %s", rsc 724 lib/pacemaker/pcmk_sched_promotable.c name, pcmk__node_name(node), rsc->id, rsc 742 lib/pacemaker/pcmk_sched_promotable.c rsc->id, pcmk__node_name(node), attr_value); rsc 754 lib/pacemaker/pcmk_sched_promotable.c pcmk__add_promotion_scores(pcmk_resource_t *rsc) rsc 756 lib/pacemaker/pcmk_sched_promotable.c if (pe__set_clone_flag(rsc, rsc 761 lib/pacemaker/pcmk_sched_promotable.c for (GList *iter = rsc->children; iter != NULL; iter = iter->next) { rsc 782 lib/pacemaker/pcmk_sched_promotable.c pcmk__rsc_trace(rsc, rsc 792 lib/pacemaker/pcmk_sched_promotable.c pcmk__rsc_trace(rsc, rsc 812 lib/pacemaker/pcmk_sched_promotable.c pcmk_resource_t *rsc = (pcmk_resource_t *) data; rsc 814 lib/pacemaker/pcmk_sched_promotable.c if (rsc->role == pcmk_role_started) { rsc 816 lib/pacemaker/pcmk_sched_promotable.c rsc->role = pcmk_role_unpromoted; rsc 818 lib/pacemaker/pcmk_sched_promotable.c g_list_foreach(rsc->children, set_current_role_unpromoted, NULL); rsc 831 lib/pacemaker/pcmk_sched_promotable.c pcmk_resource_t *rsc = (pcmk_resource_t *) data; rsc 834 lib/pacemaker/pcmk_sched_promotable.c rsc->fns->location(rsc, &assigned, FALSE); rsc 836 lib/pacemaker/pcmk_sched_promotable.c pe__set_next_role(rsc, pcmk_role_stopped, "stopped instance"); rsc 838 lib/pacemaker/pcmk_sched_promotable.c pe__set_next_role(rsc, pcmk_role_unpromoted, "unpromoted instance"); rsc 841 lib/pacemaker/pcmk_sched_promotable.c g_list_foreach(rsc->children, set_next_role_unpromoted, NULL); rsc 854 lib/pacemaker/pcmk_sched_promotable.c pcmk_resource_t *rsc = (pcmk_resource_t *) data; rsc 856 lib/pacemaker/pcmk_sched_promotable.c if (rsc->next_role == pcmk_role_unknown) { rsc 857 lib/pacemaker/pcmk_sched_promotable.c pe__set_next_role(rsc, pcmk_role_promoted, "promoted instance"); rsc 859 lib/pacemaker/pcmk_sched_promotable.c g_list_foreach(rsc->children, set_next_role_promoted, NULL); rsc 1043 lib/pacemaker/pcmk_sched_promotable.c pcmk__set_instance_roles(pcmk_resource_t *rsc) rsc 1050 lib/pacemaker/pcmk_sched_promotable.c g_hash_table_iter_init(&iter, rsc->allowed_nodes); rsc 1056 lib/pacemaker/pcmk_sched_promotable.c g_list_foreach(rsc->children, set_instance_priority, rsc); rsc 1057 lib/pacemaker/pcmk_sched_promotable.c sort_promotable_instances(rsc); rsc 1060 lib/pacemaker/pcmk_sched_promotable.c g_list_foreach(rsc->children, set_instance_role, &promoted); rsc 1061 lib/pacemaker/pcmk_sched_promotable.c pcmk__rsc_info(rsc, "%s: Promoted %d instances of a possible %d", rsc 1062 lib/pacemaker/pcmk_sched_promotable.c rsc->id, promoted, pe__clone_promoted_max(rsc)); rsc 62 lib/pacemaker/pcmk_sched_recurring.c is_op_dup(const pcmk_resource_t *rsc, const char *name, guint interval_ms) rsc 66 lib/pacemaker/pcmk_sched_recurring.c for (xmlNode *op = pcmk__xe_first_child(rsc->ops_xml, PCMK_XE_OP, NULL, rsc 130 lib/pacemaker/pcmk_sched_recurring.c is_recurring_history(const pcmk_resource_t *rsc, const xmlNode *xml, rsc 154 lib/pacemaker/pcmk_sched_recurring.c if (is_op_dup(rsc, op->name, op->interval_ms)) { rsc 172 lib/pacemaker/pcmk_sched_recurring.c if (pcmk__find_action_config(rsc, op->name, op->interval_ms, rsc 174 lib/pacemaker/pcmk_sched_recurring.c pcmk__rsc_trace(rsc, rsc 178 lib/pacemaker/pcmk_sched_recurring.c op->name, rsc->id); rsc 182 lib/pacemaker/pcmk_sched_recurring.c op->key = pcmk__op_key(rsc->id, op->name, op->interval_ms); rsc 198 lib/pacemaker/pcmk_sched_recurring.c active_recurring_should_be_optional(const pcmk_resource_t *rsc, rsc 205 lib/pacemaker/pcmk_sched_recurring.c pcmk__rsc_trace(rsc, rsc 211 lib/pacemaker/pcmk_sched_recurring.c if (!pcmk_is_set(rsc->cmds->action_flags(start, NULL), rsc 213 lib/pacemaker/pcmk_sched_recurring.c pcmk__rsc_trace(rsc, "%s will be mandatory because %s is", rsc 218 lib/pacemaker/pcmk_sched_recurring.c possible_matches = find_actions_exact(rsc->actions, key, node); rsc 220 lib/pacemaker/pcmk_sched_recurring.c pcmk__rsc_trace(rsc, rsc 232 lib/pacemaker/pcmk_sched_recurring.c pcmk__rsc_trace(rsc, rsc 254 lib/pacemaker/pcmk_sched_recurring.c recurring_op_for_active(pcmk_resource_t *rsc, pcmk_action_t *start, rsc 267 lib/pacemaker/pcmk_sched_recurring.c is_optional = active_recurring_should_be_optional(rsc, node, op->key, rsc 273 lib/pacemaker/pcmk_sched_recurring.c role_match = (rsc->next_role != pcmk_role_promoted); rsc 275 lib/pacemaker/pcmk_sched_recurring.c role_match = (rsc->next_role == monitor_role); rsc 281 lib/pacemaker/pcmk_sched_recurring.c pcmk_action_t *cancel_op = pcmk__new_cancel_action(rsc, op->name, rsc 285 lib/pacemaker/pcmk_sched_recurring.c switch (rsc->role) { rsc 288 lib/pacemaker/pcmk_sched_recurring.c if (rsc->next_role == pcmk_role_promoted) { rsc 289 lib/pacemaker/pcmk_sched_recurring.c after_key = promote_key(rsc); rsc 291 lib/pacemaker/pcmk_sched_recurring.c } else if (rsc->next_role == pcmk_role_stopped) { rsc 292 lib/pacemaker/pcmk_sched_recurring.c after_key = stop_key(rsc); rsc 297 lib/pacemaker/pcmk_sched_recurring.c after_key = demote_key(rsc); rsc 304 lib/pacemaker/pcmk_sched_recurring.c pcmk__new_ordering(rsc, NULL, cancel_op, rsc, after_key, NULL, rsc 306 lib/pacemaker/pcmk_sched_recurring.c rsc->cluster); rsc 315 lib/pacemaker/pcmk_sched_recurring.c pcmk_role_text(rsc->next_role)); rsc 319 lib/pacemaker/pcmk_sched_recurring.c pcmk__rsc_trace(rsc, rsc 322 lib/pacemaker/pcmk_sched_recurring.c op->id, rsc->id, pcmk_role_text(rsc->next_role), rsc 325 lib/pacemaker/pcmk_sched_recurring.c mon = custom_action(rsc, strdup(op->key), op->name, node, is_optional, rsc 326 lib/pacemaker/pcmk_sched_recurring.c rsc->cluster); rsc 329 lib/pacemaker/pcmk_sched_recurring.c pcmk__rsc_trace(rsc, "%s is unrunnable because start is", mon->uuid); rsc 334 lib/pacemaker/pcmk_sched_recurring.c pcmk__rsc_trace(rsc, "%s is unrunnable because no node is available", rsc 339 lib/pacemaker/pcmk_sched_recurring.c pcmk__rsc_info(rsc, "Start %s-interval %s for %s on %s", rsc 341 lib/pacemaker/pcmk_sched_recurring.c rsc->id, pcmk__node_name(node)); rsc 344 lib/pacemaker/pcmk_sched_recurring.c if (rsc->next_role == pcmk_role_promoted) { rsc 349 lib/pacemaker/pcmk_sched_recurring.c if ((node == NULL) || pcmk_is_set(rsc->flags, pcmk_rsc_managed)) { rsc 350 lib/pacemaker/pcmk_sched_recurring.c pcmk__new_ordering(rsc, start_key(rsc), NULL, rsc 354 lib/pacemaker/pcmk_sched_recurring.c rsc->cluster); rsc 356 lib/pacemaker/pcmk_sched_recurring.c pcmk__new_ordering(rsc, reload_key(rsc), NULL, rsc 360 lib/pacemaker/pcmk_sched_recurring.c rsc->cluster); rsc 362 lib/pacemaker/pcmk_sched_recurring.c if (rsc->next_role == pcmk_role_promoted) { rsc 363 lib/pacemaker/pcmk_sched_recurring.c pcmk__new_ordering(rsc, promote_key(rsc), NULL, rsc 364 lib/pacemaker/pcmk_sched_recurring.c rsc, NULL, mon, rsc 367 lib/pacemaker/pcmk_sched_recurring.c rsc->cluster); rsc 369 lib/pacemaker/pcmk_sched_recurring.c } else if (rsc->role == pcmk_role_promoted) { rsc 370 lib/pacemaker/pcmk_sched_recurring.c pcmk__new_ordering(rsc, demote_key(rsc), NULL, rsc 371 lib/pacemaker/pcmk_sched_recurring.c rsc, NULL, mon, rsc 374 lib/pacemaker/pcmk_sched_recurring.c rsc->cluster); rsc 390 lib/pacemaker/pcmk_sched_recurring.c cancel_if_running(pcmk_resource_t *rsc, const pcmk_node_t *node, rsc 393 lib/pacemaker/pcmk_sched_recurring.c GList *possible_matches = find_actions_exact(rsc->actions, key, node); rsc 401 lib/pacemaker/pcmk_sched_recurring.c cancel_op = pcmk__new_cancel_action(rsc, name, interval_ms, node); rsc 403 lib/pacemaker/pcmk_sched_recurring.c switch (rsc->next_role) { rsc 411 lib/pacemaker/pcmk_sched_recurring.c pcmk__new_ordering(rsc, NULL, cancel_op, rsc 412 lib/pacemaker/pcmk_sched_recurring.c rsc, start_key(rsc), NULL, rsc 413 lib/pacemaker/pcmk_sched_recurring.c pcmk__ar_unrunnable_first_blocks, rsc->cluster); rsc 418 lib/pacemaker/pcmk_sched_recurring.c pcmk__rsc_info(rsc, rsc 421 lib/pacemaker/pcmk_sched_recurring.c pcmk__readable_interval(interval_ms), name, rsc->id, rsc 422 lib/pacemaker/pcmk_sched_recurring.c pcmk__node_name(node), pcmk_role_text(rsc->next_role)); rsc 434 lib/pacemaker/pcmk_sched_recurring.c order_after_probes(pcmk_resource_t *rsc, const pcmk_node_t *node, rsc 437 lib/pacemaker/pcmk_sched_recurring.c GList *probes = pe__resource_actions(rsc, node, PCMK_ACTION_MONITOR, FALSE); rsc 455 lib/pacemaker/pcmk_sched_recurring.c order_after_stops(pcmk_resource_t *rsc, const pcmk_node_t *node, rsc 458 lib/pacemaker/pcmk_sched_recurring.c GList *stop_ops = pe__resource_actions(rsc, node, PCMK_ACTION_STOP, TRUE); rsc 465 lib/pacemaker/pcmk_sched_recurring.c && !pcmk_is_set(rsc->flags, pcmk_rsc_managed)) { rsc 466 lib/pacemaker/pcmk_sched_recurring.c pcmk__rsc_trace(rsc, "%s optional on %s: unmanaged", rsc 477 lib/pacemaker/pcmk_sched_recurring.c if (pcmk_is_set(rsc->flags, pcmk_rsc_managed)) { rsc 478 lib/pacemaker/pcmk_sched_recurring.c pcmk__new_ordering(rsc, stop_key(rsc), stop, rsc 482 lib/pacemaker/pcmk_sched_recurring.c rsc->cluster); rsc 497 lib/pacemaker/pcmk_sched_recurring.c recurring_op_for_inactive(pcmk_resource_t *rsc, const pcmk_node_t *node, rsc 507 lib/pacemaker/pcmk_sched_recurring.c if (!pcmk_is_set(rsc->flags, pcmk_rsc_unique)) { rsc 513 lib/pacemaker/pcmk_sched_recurring.c pcmk__rsc_trace(rsc, rsc 515 lib/pacemaker/pcmk_sched_recurring.c "where it should not be running", op->id, rsc->id); rsc 517 lib/pacemaker/pcmk_sched_recurring.c for (GList *iter = rsc->cluster->nodes; iter != NULL; iter = iter->next) { rsc 527 lib/pacemaker/pcmk_sched_recurring.c cancel_if_running(rsc, node, op->key, op->name, op->interval_ms); rsc 532 lib/pacemaker/pcmk_sched_recurring.c possible_matches = find_actions_exact(rsc->actions, op->key, stop_node); rsc 536 lib/pacemaker/pcmk_sched_recurring.c pcmk__rsc_trace(rsc, rsc 540 lib/pacemaker/pcmk_sched_recurring.c op->key, op->id, rsc->id, pcmk__node_name(stop_node)); rsc 542 lib/pacemaker/pcmk_sched_recurring.c stopped_mon = custom_action(rsc, strdup(op->key), op->name, stop_node, rsc 543 lib/pacemaker/pcmk_sched_recurring.c is_optional, rsc->cluster); rsc 547 lib/pacemaker/pcmk_sched_recurring.c if (pcmk_is_set(rsc->flags, pcmk_rsc_managed)) { rsc 548 lib/pacemaker/pcmk_sched_recurring.c order_after_probes(rsc, stop_node, stopped_mon); rsc 554 lib/pacemaker/pcmk_sched_recurring.c order_after_stops(rsc, stop_node, stopped_mon); rsc 557 lib/pacemaker/pcmk_sched_recurring.c pcmk__rsc_debug(rsc, "%s unrunnable on %s: node unavailable)", rsc 567 lib/pacemaker/pcmk_sched_recurring.c stopped_mon->task, rsc->id, pcmk__node_name(stop_node)); rsc 579 lib/pacemaker/pcmk_sched_recurring.c pcmk__create_recurring_actions(pcmk_resource_t *rsc) rsc 583 lib/pacemaker/pcmk_sched_recurring.c if (pcmk_is_set(rsc->flags, pcmk_rsc_blocked)) { rsc 584 lib/pacemaker/pcmk_sched_recurring.c pcmk__rsc_trace(rsc, rsc 586 lib/pacemaker/pcmk_sched_recurring.c rsc->id); rsc 590 lib/pacemaker/pcmk_sched_recurring.c if (pcmk_is_set(rsc->flags, pcmk_rsc_maintenance)) { rsc 591 lib/pacemaker/pcmk_sched_recurring.c pcmk__rsc_trace(rsc, rsc 593 lib/pacemaker/pcmk_sched_recurring.c "in maintenance mode", rsc->id); rsc 597 lib/pacemaker/pcmk_sched_recurring.c if (rsc->allocated_to == NULL) { rsc 600 lib/pacemaker/pcmk_sched_recurring.c } else if (rsc->allocated_to->details->maintenance) { rsc 601 lib/pacemaker/pcmk_sched_recurring.c pcmk__rsc_trace(rsc, rsc 604 lib/pacemaker/pcmk_sched_recurring.c rsc->id, pcmk__node_name(rsc->allocated_to)); rsc 606 lib/pacemaker/pcmk_sched_recurring.c } else if ((rsc->next_role != pcmk_role_stopped) rsc 607 lib/pacemaker/pcmk_sched_recurring.c || !pcmk_is_set(rsc->flags, pcmk_rsc_managed)) { rsc 609 lib/pacemaker/pcmk_sched_recurring.c start = start_action(rsc, rsc->allocated_to, TRUE); rsc 612 lib/pacemaker/pcmk_sched_recurring.c pcmk__rsc_trace(rsc, "Creating any recurring actions needed for %s", rsc 613 lib/pacemaker/pcmk_sched_recurring.c rsc->id); rsc 615 lib/pacemaker/pcmk_sched_recurring.c for (xmlNode *op = pcmk__xe_first_child(rsc->ops_xml, PCMK_XE_OP, NULL, rsc 621 lib/pacemaker/pcmk_sched_recurring.c if (!is_recurring_history(rsc, op, &op_history)) { rsc 626 lib/pacemaker/pcmk_sched_recurring.c recurring_op_for_active(rsc, start, rsc->allocated_to, &op_history); rsc 628 lib/pacemaker/pcmk_sched_recurring.c recurring_op_for_inactive(rsc, rsc->allocated_to, &op_history); rsc 646 lib/pacemaker/pcmk_sched_recurring.c pcmk__new_cancel_action(pcmk_resource_t *rsc, const char *task, rsc 653 lib/pacemaker/pcmk_sched_recurring.c pcmk__assert((rsc != NULL) && (task != NULL) && (node != NULL)); rsc 655 lib/pacemaker/pcmk_sched_recurring.c key = pcmk__op_key(rsc->id, task, interval_ms); rsc 660 lib/pacemaker/pcmk_sched_recurring.c cancel_op = custom_action(rsc, key, PCMK_ACTION_CANCEL, node, FALSE, rsc 661 lib/pacemaker/pcmk_sched_recurring.c rsc->cluster); rsc 686 lib/pacemaker/pcmk_sched_recurring.c pcmk__schedule_cancel(pcmk_resource_t *rsc, const char *call_id, rsc 692 lib/pacemaker/pcmk_sched_recurring.c CRM_CHECK((rsc != NULL) && (task != NULL) rsc 697 lib/pacemaker/pcmk_sched_recurring.c pcmk__readable_interval(interval_ms), task, rsc->id, rsc 699 lib/pacemaker/pcmk_sched_recurring.c cancel = pcmk__new_cancel_action(rsc, task, interval_ms, node); rsc 703 lib/pacemaker/pcmk_sched_recurring.c pcmk__new_ordering(rsc, stop_key(rsc), NULL, rsc, NULL, cancel, rsc 704 lib/pacemaker/pcmk_sched_recurring.c pcmk__ar_ordered, rsc->cluster); rsc 717 lib/pacemaker/pcmk_sched_recurring.c pcmk__reschedule_recurring(pcmk_resource_t *rsc, const char *task, rsc 722 lib/pacemaker/pcmk_sched_recurring.c trigger_unfencing(rsc, node, "Device parameters changed (reschedule)", rsc 723 lib/pacemaker/pcmk_sched_recurring.c NULL, rsc->cluster); rsc 724 lib/pacemaker/pcmk_sched_recurring.c op = custom_action(rsc, pcmk__op_key(rsc->id, task, interval_ms), rsc 725 lib/pacemaker/pcmk_sched_recurring.c task, node, TRUE, rsc->cluster); rsc 66 lib/pacemaker/pcmk_sched_remote.c then_action->rsc, NULL, then_action, rsc 79 lib/pacemaker/pcmk_sched_remote.c pcmk__new_ordering(first_action->rsc, NULL, first_action, rsc 176 lib/pacemaker/pcmk_sched_remote.c if (action->rsc == NULL) { rsc 311 lib/pacemaker/pcmk_sched_remote.c pcmk__assert(action->rsc != NULL); rsc 322 lib/pacemaker/pcmk_sched_remote.c pe_fence_node(action->rsc->cluster, action->node, "container failed", rsc 412 lib/pacemaker/pcmk_sched_remote.c if (action->rsc == NULL) { rsc 420 lib/pacemaker/pcmk_sched_remote.c if (action->rsc->is_remote_node && rsc 424 lib/pacemaker/pcmk_sched_remote.c pcmk__new_ordering(action->rsc, NULL, action, action->rsc, rsc 425 lib/pacemaker/pcmk_sched_remote.c pcmk__op_key(action->rsc->id, PCMK_ACTION_START, rsc 463 lib/pacemaker/pcmk_sched_remote.c for (GList *item = action->rsc->actions; item != NULL; rsc 471 lib/pacemaker/pcmk_sched_remote.c action->rsc, NULL, rsc_action, rsc 523 lib/pacemaker/pcmk_sched_remote.c pcmk__rsc_corresponds_to_guest(const pcmk_resource_t *rsc, rsc 526 lib/pacemaker/pcmk_sched_remote.c return (rsc != NULL) && (rsc->fillers != NULL) && (node != NULL) rsc 528 lib/pacemaker/pcmk_sched_remote.c && (node->details->remote_rsc->container == rsc); rsc 571 lib/pacemaker/pcmk_sched_remote.c action->task, (action->rsc? action->rsc->id : "no resource"), rsc 580 lib/pacemaker/pcmk_sched_remote.c action->task, (action->rsc? action->rsc->id : "no resource"), rsc 589 lib/pacemaker/pcmk_sched_remote.c action->task, (action->rsc? action->rsc->id : "no resource"), rsc 624 lib/pacemaker/pcmk_sched_remote.c action->task, (action->rsc? action->rsc->id : "no resource"), rsc 636 lib/pacemaker/pcmk_sched_remote.c action->task, (action->rsc? action->rsc->id : "no resource"), rsc 655 lib/pacemaker/pcmk_sched_remote.c pcmk__substitute_remote_addr(pcmk_resource_t *rsc, GHashTable *params) rsc 660 lib/pacemaker/pcmk_sched_remote.c GHashTable *base = pe_rsc_params(rsc, NULL, rsc->cluster); rsc 725 lib/pacemaker/pcmk_sched_remote.c g_hash_table_lookup(action->rsc->meta, rsc 111 lib/pacemaker/pcmk_sched_resource.c pcmk__rsc_agent_changed(pcmk_resource_t *rsc, pcmk_node_t *node, rsc 122 lib/pacemaker/pcmk_sched_resource.c const char *value = crm_element_value(rsc->xml, attr_list[i]); rsc 127 lib/pacemaker/pcmk_sched_resource.c trigger_unfencing(rsc, node, "Device definition changed", NULL, rsc 128 lib/pacemaker/pcmk_sched_resource.c rsc->cluster); rsc 132 lib/pacemaker/pcmk_sched_resource.c rsc->id, pcmk__node_name(node), attr_list[i], rsc 139 lib/pacemaker/pcmk_sched_resource.c custom_action(rsc, stop_key(rsc), PCMK_ACTION_STOP, node, FALSE, rsc 140 lib/pacemaker/pcmk_sched_resource.c rsc->cluster); rsc 141 lib/pacemaker/pcmk_sched_resource.c pcmk__set_rsc_flags(rsc, pcmk_rsc_start_pending); rsc 157 lib/pacemaker/pcmk_sched_resource.c add_rsc_if_matching(GList *result, pcmk_resource_t *rsc, const char *id) rsc 159 lib/pacemaker/pcmk_sched_resource.c if ((strcmp(rsc->id, id) == 0) rsc 160 lib/pacemaker/pcmk_sched_resource.c || ((rsc->clone_name != NULL) && (strcmp(rsc->clone_name, id) == 0))) { rsc 161 lib/pacemaker/pcmk_sched_resource.c result = g_list_prepend(result, rsc); rsc 163 lib/pacemaker/pcmk_sched_resource.c for (GList *iter = rsc->children; iter != NULL; iter = iter->next) { rsc 205 lib/pacemaker/pcmk_sched_resource.c pcmk_resource_t *rsc = data; rsc 207 lib/pacemaker/pcmk_sched_resource.c rsc->cmds = &assignment_methods[rsc->variant]; rsc 208 lib/pacemaker/pcmk_sched_resource.c g_list_foreach(rsc->children, set_assignment_methods_for_rsc, NULL); rsc 234 lib/pacemaker/pcmk_sched_resource.c add_colocated_resources(const pcmk_resource_t *rsc, rsc 237 lib/pacemaker/pcmk_sched_resource.c *list = rsc->cmds->colocated_resources(rsc, orig_rsc, *list); rsc 242 lib/pacemaker/pcmk_sched_resource.c pcmk__colocated_resources(const pcmk_resource_t *rsc, rsc 250 lib/pacemaker/pcmk_sched_resource.c orig_rsc = rsc; rsc 253 lib/pacemaker/pcmk_sched_resource.c if ((rsc == NULL) || (g_list_find(colocated_rscs, rsc) != NULL)) { rsc 258 lib/pacemaker/pcmk_sched_resource.c rsc->id, orig_rsc->id); rsc 259 lib/pacemaker/pcmk_sched_resource.c colocated_rscs = g_list_prepend(colocated_rscs, (gpointer) rsc); rsc 262 lib/pacemaker/pcmk_sched_resource.c colocations = pcmk__this_with_colocations(rsc); rsc 272 lib/pacemaker/pcmk_sched_resource.c (pcmk__colocation_affects(rsc, primary, constraint, rsc 280 lib/pacemaker/pcmk_sched_resource.c colocations = pcmk__with_this_colocations(rsc); rsc 289 lib/pacemaker/pcmk_sched_resource.c if (pcmk__is_clone(rsc) && !pcmk__is_clone(dependent)) { rsc 294 lib/pacemaker/pcmk_sched_resource.c (pcmk__colocation_affects(dependent, rsc, constraint, rsc 306 lib/pacemaker/pcmk_sched_resource.c pcmk__noop_add_graph_meta(const pcmk_resource_t *rsc, xmlNode *xml) rsc 317 lib/pacemaker/pcmk_sched_resource.c pcmk__output_resource_actions(pcmk_resource_t *rsc) rsc 323 lib/pacemaker/pcmk_sched_resource.c pcmk__assert(rsc != NULL); rsc 325 lib/pacemaker/pcmk_sched_resource.c out = rsc->cluster->priv; rsc 326 lib/pacemaker/pcmk_sched_resource.c if (rsc->children != NULL) { rsc 327 lib/pacemaker/pcmk_sched_resource.c for (GList *iter = rsc->children; iter != NULL; iter = iter->next) { rsc 335 lib/pacemaker/pcmk_sched_resource.c next = rsc->allocated_to; rsc 336 lib/pacemaker/pcmk_sched_resource.c if (rsc->running_on) { rsc 337 lib/pacemaker/pcmk_sched_resource.c current = pcmk__current_node(rsc); rsc 338 lib/pacemaker/pcmk_sched_resource.c if (rsc->role == pcmk_role_stopped) { rsc 342 lib/pacemaker/pcmk_sched_resource.c rsc->role = pcmk_role_started; rsc 346 lib/pacemaker/pcmk_sched_resource.c if ((current == NULL) && pcmk_is_set(rsc->flags, pcmk_rsc_removed)) { rsc 351 lib/pacemaker/pcmk_sched_resource.c out->message(out, "rsc-action", rsc, current, next); rsc 362 lib/pacemaker/pcmk_sched_resource.c add_assigned_resource(pcmk_node_t *node, pcmk_resource_t *rsc) rsc 365 lib/pacemaker/pcmk_sched_resource.c rsc); rsc 404 lib/pacemaker/pcmk_sched_resource.c pcmk__assign_resource(pcmk_resource_t *rsc, pcmk_node_t *node, bool force, rsc 409 lib/pacemaker/pcmk_sched_resource.c pcmk__assert(rsc != NULL); rsc 411 lib/pacemaker/pcmk_sched_resource.c if (rsc->children != NULL) { rsc 412 lib/pacemaker/pcmk_sched_resource.c for (GList *iter = rsc->children; iter != NULL; iter = iter->next) { rsc 429 lib/pacemaker/pcmk_sched_resource.c pcmk__rsc_debug(rsc, rsc 432 lib/pacemaker/pcmk_sched_resource.c rsc->id, pcmk__node_name(node), rsc 437 lib/pacemaker/pcmk_sched_resource.c pe__set_next_role(rsc, pcmk_role_stopped, "node availability"); rsc 442 lib/pacemaker/pcmk_sched_resource.c if (rsc->allocated_to != NULL) { rsc 443 lib/pacemaker/pcmk_sched_resource.c changed = !pcmk__same_node(rsc->allocated_to, node); rsc 447 lib/pacemaker/pcmk_sched_resource.c pcmk__unassign_resource(rsc); rsc 448 lib/pacemaker/pcmk_sched_resource.c pcmk__clear_rsc_flags(rsc, pcmk_rsc_unassigned); rsc 453 lib/pacemaker/pcmk_sched_resource.c pcmk__rsc_debug(rsc, "Could not assign %s to a node", rsc->id); rsc 458 lib/pacemaker/pcmk_sched_resource.c pe__set_next_role(rsc, pcmk_role_stopped, "unable to assign"); rsc 460 lib/pacemaker/pcmk_sched_resource.c for (GList *iter = rsc->actions; iter != NULL; iter = iter->next) { rsc 463 lib/pacemaker/pcmk_sched_resource.c pcmk__rsc_debug(rsc, "Updating %s for %s assignment failure", rsc 464 lib/pacemaker/pcmk_sched_resource.c op->uuid, rsc->id); rsc 497 lib/pacemaker/pcmk_sched_resource.c pcmk__rsc_debug(rsc, "Assigning %s to %s", rsc->id, pcmk__node_name(node)); rsc 498 lib/pacemaker/pcmk_sched_resource.c rsc->allocated_to = pe__copy_node(node); rsc 500 lib/pacemaker/pcmk_sched_resource.c add_assigned_resource(node, rsc); rsc 503 lib/pacemaker/pcmk_sched_resource.c pcmk__consume_node_capacity(node->details->utilization, rsc); rsc 505 lib/pacemaker/pcmk_sched_resource.c if (pcmk_is_set(rsc->cluster->flags, pcmk_sched_show_utilization)) { rsc 506 lib/pacemaker/pcmk_sched_resource.c pcmk__output_t *out = rsc->cluster->priv; rsc 508 lib/pacemaker/pcmk_sched_resource.c out->message(out, "resource-util", rsc, node, __func__); rsc 525 lib/pacemaker/pcmk_sched_resource.c pcmk__unassign_resource(pcmk_resource_t *rsc) rsc 527 lib/pacemaker/pcmk_sched_resource.c pcmk_node_t *old = rsc->allocated_to; rsc 530 lib/pacemaker/pcmk_sched_resource.c crm_info("Unassigning %s", rsc->id); rsc 532 lib/pacemaker/pcmk_sched_resource.c crm_info("Unassigning %s from %s", rsc->id, pcmk__node_name(old)); rsc 535 lib/pacemaker/pcmk_sched_resource.c pcmk__set_rsc_flags(rsc, pcmk_rsc_unassigned); rsc 537 lib/pacemaker/pcmk_sched_resource.c if (rsc->children == NULL) { rsc 541 lib/pacemaker/pcmk_sched_resource.c rsc->allocated_to = NULL; rsc 547 lib/pacemaker/pcmk_sched_resource.c rsc); rsc 549 lib/pacemaker/pcmk_sched_resource.c pcmk__release_node_capacity(old->details->utilization, rsc); rsc 554 lib/pacemaker/pcmk_sched_resource.c for (GList *iter = rsc->children; iter != NULL; iter = iter->next) { rsc 571 lib/pacemaker/pcmk_sched_resource.c pcmk__threshold_reached(pcmk_resource_t *rsc, const pcmk_node_t *node, rsc 575 lib/pacemaker/pcmk_sched_resource.c pcmk_resource_t *rsc_to_ban = rsc; rsc 578 lib/pacemaker/pcmk_sched_resource.c if (rsc->migration_threshold == 0) { rsc 583 lib/pacemaker/pcmk_sched_resource.c if (pcmk_is_set(rsc->flags, pcmk_rsc_ignore_failure)) { rsc 588 lib/pacemaker/pcmk_sched_resource.c fail_count = pe_get_failcount(node, rsc, NULL, rsc 595 lib/pacemaker/pcmk_sched_resource.c if (!pcmk_is_set(rsc->flags, pcmk_rsc_unique)) { rsc 596 lib/pacemaker/pcmk_sched_resource.c rsc_to_ban = uber_parent(rsc); rsc 600 lib/pacemaker/pcmk_sched_resource.c remaining_tries = rsc->migration_threshold - fail_count; rsc 608 lib/pacemaker/pcmk_sched_resource.c rsc->migration_threshold); rsc 618 lib/pacemaker/pcmk_sched_resource.c pcmk__node_name(node), rsc->migration_threshold); rsc 31 lib/pacemaker/pcmk_sched_tickets.c pcmk_resource_t *rsc; rsc 47 lib/pacemaker/pcmk_sched_tickets.c ticket_role_matches(const pcmk_resource_t *rsc, const rsc_ticket_t *rsc_ticket) rsc 50 lib/pacemaker/pcmk_sched_tickets.c || (rsc_ticket->role == rsc->role)) { rsc 53 lib/pacemaker/pcmk_sched_tickets.c pcmk__rsc_trace(rsc, "Skipping constraint: \"%s\" state filter", rsc 65 lib/pacemaker/pcmk_sched_tickets.c constraints_for_ticket(pcmk_resource_t *rsc, const rsc_ticket_t *rsc_ticket) rsc 69 lib/pacemaker/pcmk_sched_tickets.c CRM_CHECK((rsc != NULL) && (rsc_ticket != NULL), return); rsc 75 lib/pacemaker/pcmk_sched_tickets.c if (rsc->children) { rsc 76 lib/pacemaker/pcmk_sched_tickets.c pcmk__rsc_trace(rsc, "Processing ticket dependencies from %s", rsc->id); rsc 77 lib/pacemaker/pcmk_sched_tickets.c for (iter = rsc->children; iter != NULL; iter = iter->next) { rsc 83 lib/pacemaker/pcmk_sched_tickets.c pcmk__rsc_trace(rsc, "%s: Processing ticket dependency on %s (%s, %s)", rsc 84 lib/pacemaker/pcmk_sched_tickets.c rsc->id, rsc_ticket->ticket->id, rsc_ticket->id, rsc 87 lib/pacemaker/pcmk_sched_tickets.c if (!rsc_ticket->ticket->granted && (rsc->running_on != NULL)) { rsc 91 lib/pacemaker/pcmk_sched_tickets.c resource_location(rsc, NULL, -PCMK_SCORE_INFINITY, rsc 92 lib/pacemaker/pcmk_sched_tickets.c "__loss_of_ticket__", rsc->cluster); rsc 98 lib/pacemaker/pcmk_sched_tickets.c resource_location(rsc, NULL, -PCMK_SCORE_INFINITY, rsc 99 lib/pacemaker/pcmk_sched_tickets.c "__loss_of_ticket__", rsc->cluster); rsc 104 lib/pacemaker/pcmk_sched_tickets.c if (!ticket_role_matches(rsc, rsc_ticket)) { rsc 108 lib/pacemaker/pcmk_sched_tickets.c resource_location(rsc, NULL, -PCMK_SCORE_INFINITY, rsc 109 lib/pacemaker/pcmk_sched_tickets.c "__loss_of_ticket__", rsc->cluster); rsc 111 lib/pacemaker/pcmk_sched_tickets.c for (iter = rsc->running_on; iter != NULL; iter = iter->next) { rsc 112 lib/pacemaker/pcmk_sched_tickets.c pe_fence_node(rsc->cluster, (pcmk_node_t *) iter->data, rsc 118 lib/pacemaker/pcmk_sched_tickets.c if (!ticket_role_matches(rsc, rsc_ticket)) { rsc 121 lib/pacemaker/pcmk_sched_tickets.c if (rsc->running_on != NULL) { rsc 122 lib/pacemaker/pcmk_sched_tickets.c pcmk__clear_rsc_flags(rsc, pcmk_rsc_managed); rsc 123 lib/pacemaker/pcmk_sched_tickets.c pcmk__set_rsc_flags(rsc, pcmk_rsc_blocked); rsc 132 lib/pacemaker/pcmk_sched_tickets.c resource_location(rsc, NULL, -PCMK_SCORE_INFINITY, rsc 133 lib/pacemaker/pcmk_sched_tickets.c "__no_ticket__", rsc->cluster); rsc 140 lib/pacemaker/pcmk_sched_tickets.c resource_location(rsc, NULL, -PCMK_SCORE_INFINITY, rsc 141 lib/pacemaker/pcmk_sched_tickets.c "__ticket_standby__", rsc->cluster); rsc 147 lib/pacemaker/pcmk_sched_tickets.c rsc_ticket_new(const char *id, pcmk_resource_t *rsc, pcmk_ticket_t *ticket, rsc 152 lib/pacemaker/pcmk_sched_tickets.c if (rsc == NULL) { rsc 170 lib/pacemaker/pcmk_sched_tickets.c new_rsc_ticket->rsc = rsc; rsc 174 lib/pacemaker/pcmk_sched_tickets.c if (pcmk_is_set(rsc->cluster->flags, pcmk_sched_fencing_enabled)) { rsc 186 lib/pacemaker/pcmk_sched_tickets.c new_rsc_ticket->ticket->id, new_rsc_ticket->rsc->id, rsc 191 lib/pacemaker/pcmk_sched_tickets.c new_rsc_ticket->ticket->id, new_rsc_ticket->rsc->id, rsc 197 lib/pacemaker/pcmk_sched_tickets.c new_rsc_ticket->ticket->id, new_rsc_ticket->rsc->id, rsc 203 lib/pacemaker/pcmk_sched_tickets.c new_rsc_ticket->ticket->id, new_rsc_ticket->rsc->id, rsc 210 lib/pacemaker/pcmk_sched_tickets.c new_rsc_ticket->ticket->id, new_rsc_ticket->rsc->id, rsc 216 lib/pacemaker/pcmk_sched_tickets.c new_rsc_ticket->ticket->id, new_rsc_ticket->rsc->id, rsc 222 lib/pacemaker/pcmk_sched_tickets.c pcmk__rsc_trace(rsc, "%s (%s) ==> %s", rsc 223 lib/pacemaker/pcmk_sched_tickets.c rsc->id, pcmk_role_text(new_rsc_ticket->role), ticket->id); rsc 225 lib/pacemaker/pcmk_sched_tickets.c rsc->rsc_tickets = g_list_append(rsc->rsc_tickets, new_rsc_ticket); rsc 227 lib/pacemaker/pcmk_sched_tickets.c rsc->cluster->ticket_constraints = g_list_append( rsc 228 lib/pacemaker/pcmk_sched_tickets.c rsc->cluster->ticket_constraints, new_rsc_ticket); rsc 231 lib/pacemaker/pcmk_sched_tickets.c constraints_for_ticket(rsc, new_rsc_ticket); rsc 291 lib/pacemaker/pcmk_sched_tickets.c pcmk_resource_t *rsc = NULL; rsc 326 lib/pacemaker/pcmk_sched_tickets.c rsc = pcmk__find_constraint_resource(scheduler->resources, rsc_id); rsc 329 lib/pacemaker/pcmk_sched_tickets.c if (rsc == NULL) { rsc 334 lib/pacemaker/pcmk_sched_tickets.c } else if ((instance != NULL) && !pcmk__is_clone(rsc)) { rsc 342 lib/pacemaker/pcmk_sched_tickets.c rsc = find_clone_instance(rsc, instance); rsc 343 lib/pacemaker/pcmk_sched_tickets.c if (rsc == NULL) { rsc 351 lib/pacemaker/pcmk_sched_tickets.c rsc_ticket_new(id, rsc, ticket, state, loss_policy); rsc 363 lib/pacemaker/pcmk_sched_tickets.c pcmk_resource_t *rsc = NULL; rsc 391 lib/pacemaker/pcmk_sched_tickets.c if (!pcmk__valid_resource_or_tag(scheduler, rsc_id, &rsc, &tag)) { rsc 396 lib/pacemaker/pcmk_sched_tickets.c } else if (rsc != NULL) { rsc 522 lib/pacemaker/pcmk_sched_tickets.c pcmk__require_promotion_tickets(pcmk_resource_t *rsc) rsc 524 lib/pacemaker/pcmk_sched_tickets.c for (GList *item = rsc->rsc_tickets; item != NULL; item = item->next) { rsc 529 lib/pacemaker/pcmk_sched_tickets.c resource_location(rsc, NULL, -PCMK_SCORE_INFINITY, rsc 530 lib/pacemaker/pcmk_sched_tickets.c "__stateful_without_ticket__", rsc->cluster); rsc 172 lib/pacemaker/pcmk_sched_utilization.c const pcmk_resource_t *rsc) rsc 179 lib/pacemaker/pcmk_sched_utilization.c g_hash_table_foreach(rsc->utilization, update_utilization_value, &data); rsc 191 lib/pacemaker/pcmk_sched_utilization.c const pcmk_resource_t *rsc) rsc 198 lib/pacemaker/pcmk_sched_utilization.c g_hash_table_foreach(rsc->utilization, update_utilization_value, &data); rsc 283 lib/pacemaker/pcmk_sched_utilization.c pcmk_resource_t *rsc = (pcmk_resource_t *) iter->data; rsc 285 lib/pacemaker/pcmk_sched_utilization.c rsc->cmds->add_utilization(rsc, orig_rsc, rscs, utilization); rsc 300 lib/pacemaker/pcmk_sched_utilization.c pcmk__ban_insufficient_capacity(pcmk_resource_t *rsc) rsc 310 lib/pacemaker/pcmk_sched_utilization.c CRM_CHECK(rsc != NULL, return NULL); rsc 313 lib/pacemaker/pcmk_sched_utilization.c if (pcmk__str_eq(rsc->cluster->placement_strategy, PCMK_VALUE_DEFAULT, rsc 319 lib/pacemaker/pcmk_sched_utilization.c colocated_rscs = rsc->cmds->colocated_resources(rsc, NULL, NULL); rsc 324 lib/pacemaker/pcmk_sched_utilization.c rscs_id = crm_strdup_printf("%s and its colocated resources", rsc->id); rsc 327 lib/pacemaker/pcmk_sched_utilization.c if (g_list_find(colocated_rscs, rsc) == NULL) { rsc 328 lib/pacemaker/pcmk_sched_utilization.c colocated_rscs = g_list_append(colocated_rscs, rsc); rsc 332 lib/pacemaker/pcmk_sched_utilization.c unassigned_utilization = sum_resource_utilization(rsc, colocated_rscs); rsc 335 lib/pacemaker/pcmk_sched_utilization.c g_hash_table_iter_init(&iter, rsc->allowed_nodes); rsc 354 lib/pacemaker/pcmk_sched_utilization.c g_hash_table_iter_init(&iter, rsc->allowed_nodes); rsc 359 lib/pacemaker/pcmk_sched_utilization.c pcmk__rsc_debug(rsc, "%s does not have enough capacity for %s", rsc 361 lib/pacemaker/pcmk_sched_utilization.c resource_location(rsc, node, -PCMK_SCORE_INFINITY, rsc 362 lib/pacemaker/pcmk_sched_utilization.c "__limit_utilization__", rsc->cluster); rsc 369 lib/pacemaker/pcmk_sched_utilization.c g_hash_table_iter_init(&iter, rsc->allowed_nodes); rsc 372 lib/pacemaker/pcmk_sched_utilization.c && !have_enough_capacity(node, rsc->id, rsc->utilization)) { rsc 373 lib/pacemaker/pcmk_sched_utilization.c pcmk__rsc_debug(rsc, "%s does not have enough capacity for %s", rsc 374 lib/pacemaker/pcmk_sched_utilization.c pcmk__node_name(node), rsc->id); rsc 375 lib/pacemaker/pcmk_sched_utilization.c resource_location(rsc, node, -PCMK_SCORE_INFINITY, rsc 376 lib/pacemaker/pcmk_sched_utilization.c "__limit_utilization__", rsc->cluster); rsc 385 lib/pacemaker/pcmk_sched_utilization.c pe__show_node_scores(true, rsc, "Post-utilization", rsc->allowed_nodes, rsc 386 lib/pacemaker/pcmk_sched_utilization.c rsc->cluster); rsc 422 lib/pacemaker/pcmk_sched_utilization.c pcmk__create_utilization_constraints(pcmk_resource_t *rsc, rsc 428 lib/pacemaker/pcmk_sched_utilization.c pcmk__rsc_trace(rsc, rsc 430 lib/pacemaker/pcmk_sched_utilization.c rsc->id, rsc->cluster->placement_strategy); rsc 433 lib/pacemaker/pcmk_sched_utilization.c for (iter = rsc->running_on; iter != NULL; iter = iter->next) { rsc 435 lib/pacemaker/pcmk_sched_utilization.c pcmk__new_ordering(rsc, stop_key(rsc), NULL, NULL, NULL, load_stopped, rsc 436 lib/pacemaker/pcmk_sched_utilization.c pcmk__ar_if_on_same_node_or_target, rsc->cluster); rsc 442 lib/pacemaker/pcmk_sched_utilization.c pcmk__new_ordering(NULL, NULL, load_stopped, rsc, start_key(rsc), NULL, rsc 443 lib/pacemaker/pcmk_sched_utilization.c pcmk__ar_if_on_same_node_or_target, rsc->cluster); rsc 445 lib/pacemaker/pcmk_sched_utilization.c rsc, rsc 446 lib/pacemaker/pcmk_sched_utilization.c pcmk__op_key(rsc->id, PCMK_ACTION_MIGRATE_TO, 0), rsc 448 lib/pacemaker/pcmk_sched_utilization.c pcmk__ar_if_on_same_node_or_target, rsc->cluster); rsc 43 lib/pacemaker/pcmk_scheduler.c check_params(pcmk_resource_t *rsc, pcmk_node_t *node, const xmlNode *rsc_op, rsc 51 lib/pacemaker/pcmk_scheduler.c if (pcmk__check_action_config(rsc, node, rsc_op) rsc 52 lib/pacemaker/pcmk_scheduler.c && pe_get_failcount(node, rsc, NULL, pcmk__fc_effective, rsc 59 lib/pacemaker/pcmk_scheduler.c digest_data = rsc_action_digest_cmp(rsc, rsc_op, node, rsc 60 lib/pacemaker/pcmk_scheduler.c rsc->cluster); rsc 65 lib/pacemaker/pcmk_scheduler.c rsc->id, pcmk__xe_id(rsc_op), node->details->id); rsc 76 lib/pacemaker/pcmk_scheduler.c pe__clear_failcount(rsc, node, reason, rsc->cluster); rsc 92 lib/pacemaker/pcmk_scheduler.c const pcmk_resource_t *rsc) rsc 94 lib/pacemaker/pcmk_scheduler.c GList *list = pe__resource_actions(rsc, node, PCMK_ACTION_CLEAR_FAILCOUNT, rsc 114 lib/pacemaker/pcmk_scheduler.c pcmk_resource_t *rsc = data; rsc 118 lib/pacemaker/pcmk_scheduler.c if (rsc->children != NULL) { rsc 119 lib/pacemaker/pcmk_scheduler.c g_list_foreach(rsc->children, check_failure_threshold, user_data); rsc 123 lib/pacemaker/pcmk_scheduler.c if (!failcount_clear_action_exists(node, rsc)) { rsc 136 lib/pacemaker/pcmk_scheduler.c if (pcmk__threshold_reached(rsc, node, &failed)) { rsc 138 lib/pacemaker/pcmk_scheduler.c "__fail_limit__", rsc->cluster); rsc 159 lib/pacemaker/pcmk_scheduler.c pcmk_resource_t *rsc = data; rsc 162 lib/pacemaker/pcmk_scheduler.c if (rsc->exclusive_discover rsc 163 lib/pacemaker/pcmk_scheduler.c || pe__const_top_resource(rsc, false)->exclusive_discover) { rsc 167 lib/pacemaker/pcmk_scheduler.c g_list_foreach(rsc->children, apply_exclusive_discovery, user_data); rsc 169 lib/pacemaker/pcmk_scheduler.c match = g_hash_table_lookup(rsc->allowed_nodes, node->details->id); rsc 187 lib/pacemaker/pcmk_scheduler.c pcmk_resource_t *rsc = data; rsc 191 lib/pacemaker/pcmk_scheduler.c if (rsc->children != NULL) { rsc 192 lib/pacemaker/pcmk_scheduler.c g_list_foreach(rsc->children, apply_stickiness, NULL); rsc 199 lib/pacemaker/pcmk_scheduler.c if (!pcmk_is_set(rsc->flags, pcmk_rsc_managed) rsc 200 lib/pacemaker/pcmk_scheduler.c || (rsc->stickiness < 1) || !pcmk__list_of_1(rsc->running_on)) { rsc 204 lib/pacemaker/pcmk_scheduler.c node = rsc->running_on->data; rsc 211 lib/pacemaker/pcmk_scheduler.c if (!pcmk_is_set(rsc->cluster->flags, pcmk_sched_symmetric_cluster) rsc 212 lib/pacemaker/pcmk_scheduler.c && (g_hash_table_lookup(rsc->allowed_nodes, rsc 214 lib/pacemaker/pcmk_scheduler.c pcmk__rsc_debug(rsc, rsc 217 lib/pacemaker/pcmk_scheduler.c rsc->id, pcmk__node_name(node)); rsc 221 lib/pacemaker/pcmk_scheduler.c pcmk__rsc_debug(rsc, "Resource %s has %d stickiness on %s", rsc 222 lib/pacemaker/pcmk_scheduler.c rsc->id, rsc->stickiness, pcmk__node_name(node)); rsc 223 lib/pacemaker/pcmk_scheduler.c resource_location(rsc, node, rsc->stickiness, "stickiness", rsc->cluster); rsc 239 lib/pacemaker/pcmk_scheduler.c pcmk_resource_t *rsc = (pcmk_resource_t *) iter->data; rsc 241 lib/pacemaker/pcmk_scheduler.c rsc->cmds->shutdown_lock(rsc); rsc 322 lib/pacemaker/pcmk_scheduler.c pcmk_resource_t *rsc = (pcmk_resource_t *) iter->data; rsc 324 lib/pacemaker/pcmk_scheduler.c if (rsc->is_remote_node) { rsc 325 lib/pacemaker/pcmk_scheduler.c pcmk__rsc_trace(rsc, "Assigning remote connection resource '%s'", rsc 326 lib/pacemaker/pcmk_scheduler.c rsc->id); rsc 327 lib/pacemaker/pcmk_scheduler.c rsc->cmds->assign(rsc, rsc->partial_migration_target, true); rsc 334 lib/pacemaker/pcmk_scheduler.c pcmk_resource_t *rsc = (pcmk_resource_t *) iter->data; rsc 336 lib/pacemaker/pcmk_scheduler.c if (!rsc->is_remote_node) { rsc 337 lib/pacemaker/pcmk_scheduler.c pcmk__rsc_trace(rsc, "Assigning %s resource '%s'", rsc 338 lib/pacemaker/pcmk_scheduler.c rsc->xml->name, rsc->id); rsc 339 lib/pacemaker/pcmk_scheduler.c rsc->cmds->assign(rsc, NULL, true); rsc 356 lib/pacemaker/pcmk_scheduler.c pcmk_resource_t *rsc = data; rsc 358 lib/pacemaker/pcmk_scheduler.c if (!pcmk_is_set(rsc->flags, pcmk_rsc_removed)) { rsc 361 lib/pacemaker/pcmk_scheduler.c crm_trace("Clear fail counts for orphaned resource %s", rsc->id); rsc 367 lib/pacemaker/pcmk_scheduler.c for (GList *iter = rsc->cluster->nodes; iter != NULL; iter = iter->next) { rsc 374 lib/pacemaker/pcmk_scheduler.c if (pe_get_failcount(node, rsc, NULL, pcmk__fc_effective, NULL) == 0) { rsc 378 lib/pacemaker/pcmk_scheduler.c clear_op = pe__clear_failcount(rsc, node, "it is orphaned", rsc 379 lib/pacemaker/pcmk_scheduler.c rsc->cluster); rsc 384 lib/pacemaker/pcmk_scheduler.c pcmk__new_ordering(clear_op->rsc, NULL, clear_op, rsc, stop_key(rsc), rsc 385 lib/pacemaker/pcmk_scheduler.c NULL, pcmk__ar_ordered, rsc->cluster); rsc 414 lib/pacemaker/pcmk_scheduler.c pcmk_resource_t *rsc = (pcmk_resource_t *) iter->data; rsc 416 lib/pacemaker/pcmk_scheduler.c rsc->cmds->create_actions(rsc); rsc 429 lib/pacemaker/pcmk_scheduler.c is_managed(const pcmk_resource_t *rsc) rsc 431 lib/pacemaker/pcmk_scheduler.c if (pcmk_is_set(rsc->flags, pcmk_rsc_managed)) { rsc 434 lib/pacemaker/pcmk_scheduler.c for (GList *iter = rsc->children; iter != NULL; iter = iter->next) { rsc 667 lib/pacemaker/pcmk_scheduler.c pcmk_resource_t *rsc = (pcmk_resource_t *) item->data; rsc 670 lib/pacemaker/pcmk_scheduler.c if (!pcmk_is_set(rsc->flags, pcmk_rsc_removed) rsc 671 lib/pacemaker/pcmk_scheduler.c || (rsc->role != pcmk_role_stopped)) { rsc 672 lib/pacemaker/pcmk_scheduler.c out->message(out, pcmk__map_element_name(rsc->xml), 0UL, rsc, all, rsc 63 lib/pacemaker/pcmk_simulate.c if (action->rsc != NULL) { rsc 64 lib/pacemaker/pcmk_simulate.c clone_name = action->rsc->clone_name; rsc 106 lib/pacemaker/pcmk_simulate.c } else if (action->rsc && action_host) { rsc 249 lib/pacemaker/pcmk_simulate.c } else if ((action->rsc != NULL) rsc 250 lib/pacemaker/pcmk_simulate.c && !pcmk_is_set(action->rsc->flags, pcmk_rsc_managed)) { rsc 673 lib/pacemaker/pcmk_simulate.c xmlNode *rsc = pcmk__xe_first_child(action->xml, PCMK_XE_PRIMITIVE, NULL, rsc 677 lib/pacemaker/pcmk_simulate.c out->message(out, "inject-cluster-action", node, task, rsc); rsc 72 lib/pacemaker/tests/pcmk_resource/pcmk_resource_delete_test.c find_rsc(const char *rsc) rsc 83 lib/pacemaker/tests/pcmk_resource/pcmk_resource_delete_test.c "//*[@" PCMK_XA_ID "=\"", rsc, "\"]", NULL); rsc 81 lib/pengine/bundle.c #define get_bundle_variant_data(data, rsc) \ rsc 82 lib/pengine/bundle.c pcmk__assert(pcmk__is_bundle(rsc) && (rsc->variant_opaque != NULL)); \ rsc 83 lib/pengine/bundle.c data = (pe__bundle_variant_data_t *) rsc->variant_opaque; rsc 94 lib/pengine/bundle.c pe__bundle_max(const pcmk_resource_t *rsc) rsc 98 lib/pengine/bundle.c get_bundle_variant_data(bundle_data, pe__const_top_resource(rsc, true)); rsc 111 lib/pengine/bundle.c pe__bundled_resource(const pcmk_resource_t *rsc) rsc 115 lib/pengine/bundle.c get_bundle_variant_data(bundle_data, pe__const_top_resource(rsc, true)); rsc 319 lib/pengine/bundle.c xmlNode *rsc = pcmk__xe_create(NULL, PCMK_XE_PRIMITIVE); rsc 321 lib/pengine/bundle.c crm_xml_add(rsc, PCMK_XA_ID, name); rsc 322 lib/pengine/bundle.c crm_xml_add(rsc, PCMK_XA_CLASS, PCMK_RESOURCE_CLASS_OCF); rsc 323 lib/pengine/bundle.c crm_xml_add(rsc, PCMK_XA_PROVIDER, provider); rsc 324 lib/pengine/bundle.c crm_xml_add(rsc, PCMK_XA_TYPE, kind); rsc 326 lib/pengine/bundle.c return rsc; rsc 666 lib/pengine/bundle.c disallow_node(pcmk_resource_t *rsc, const char *uname) rsc 668 lib/pengine/bundle.c gpointer match = g_hash_table_lookup(rsc->allowed_nodes, uname); rsc 674 lib/pengine/bundle.c if (rsc->children) { rsc 675 lib/pengine/bundle.c g_list_foreach(rsc->children, (GFunc) disallow_node, (gpointer) uname); rsc 920 lib/pengine/bundle.c pe__bundle_needs_remote_name(pcmk_resource_t *rsc) rsc 925 lib/pengine/bundle.c if (rsc == NULL) { rsc 930 lib/pengine/bundle.c params = pe_rsc_params(rsc, NULL, rsc->cluster); rsc 934 lib/pengine/bundle.c && xml_contains_remote_node(rsc->xml); rsc 938 lib/pengine/bundle.c pe__add_bundle_remote_name(pcmk_resource_t *rsc, xmlNode *xml, rsc 946 lib/pengine/bundle.c if (!pe__bundle_needs_remote_name(rsc)) { rsc 950 lib/pengine/bundle.c replica = replica_for_remote(rsc); rsc 964 lib/pengine/bundle.c crm_trace("Cannot determine address for bundle connection %s", rsc->id); rsc 969 lib/pengine/bundle.c rsc->id, pcmk__node_name(node)); rsc 984 lib/pengine/bundle.c pe__unpack_bundle(pcmk_resource_t *rsc, pcmk_scheduler_t *scheduler) rsc 993 lib/pengine/bundle.c pcmk__assert(rsc != NULL); rsc 994 lib/pengine/bundle.c pcmk__rsc_trace(rsc, "Processing resource %s...", rsc->id); rsc 997 lib/pengine/bundle.c rsc->variant_opaque = bundle_data; rsc 998 lib/pengine/bundle.c bundle_data->prefix = strdup(rsc->id); rsc 1000 lib/pengine/bundle.c xml_obj = pcmk__xe_first_child(rsc->xml, PCMK_XE_DOCKER, NULL, NULL); rsc 1004 lib/pengine/bundle.c xml_obj = pcmk__xe_first_child(rsc->xml, PCMK__XE_RKT, NULL, NULL); rsc 1009 lib/pengine/bundle.c "removed in a future release", rsc->id); rsc 1012 lib/pengine/bundle.c xml_obj = pcmk__xe_first_child(rsc->xml, PCMK_XE_PODMAN, NULL, rsc 1034 lib/pengine/bundle.c rsc->id); rsc 1057 lib/pengine/bundle.c pcmk__clear_rsc_flags(rsc, pcmk_rsc_unique); rsc 1068 lib/pengine/bundle.c xml_obj = pcmk__xe_first_child(rsc->xml, PCMK_XE_NETWORK, NULL, NULL); rsc 1113 lib/pengine/bundle.c xml_obj = pcmk__xe_first_child(rsc->xml, PCMK_XE_STORAGE, NULL, NULL); rsc 1140 lib/pengine/bundle.c xml_obj = pcmk__xe_first_child(rsc->xml, PCMK_XE_PRIMITIVE, NULL, NULL); rsc 1187 lib/pengine/bundle.c rsc->id, pcmk__xe_id(xml_obj)); rsc 1197 lib/pengine/bundle.c if (pe__unpack_resource(xml_resource, &(bundle_data->child), rsc, rsc 1275 lib/pengine/bundle.c pcmk__insert_dup(rsc->meta, PCMK_META_CONTAINER_ATTRIBUTE_TARGET, rsc 1302 lib/pengine/bundle.c if (create_replica_resources(rsc, bundle_data, replica) != pcmk_rc_ok) { rsc 1303 lib/pengine/bundle.c pcmk__config_err("Failed unpacking resource %s", rsc->id); rsc 1304 lib/pengine/bundle.c rsc->fns->free(rsc); rsc 1333 lib/pengine/bundle.c rsc->children = g_list_append(rsc->children, bundle_data->child); rsc 1339 lib/pengine/bundle.c replica_resource_active(pcmk_resource_t *rsc, gboolean all) rsc 1341 lib/pengine/bundle.c if (rsc) { rsc 1342 lib/pengine/bundle.c gboolean child_active = rsc->fns->active(rsc, all); rsc 1354 lib/pengine/bundle.c pe__bundle_active(pcmk_resource_t *rsc, gboolean all) rsc 1359 lib/pengine/bundle.c get_bundle_variant_data(bundle_data, rsc); rsc 1426 lib/pengine/bundle.c print_rsc_in_list(pcmk_resource_t *rsc, const char *pre_text, long options, rsc 1429 lib/pengine/bundle.c if (rsc != NULL) { rsc 1433 lib/pengine/bundle.c rsc->fns->print(rsc, pre_text, options, print_data); rsc 1445 lib/pengine/bundle.c bundle_print_xml(pcmk_resource_t *rsc, const char *pre_text, long options, rsc 1450 lib/pengine/bundle.c CRM_CHECK(rsc != NULL, return); rsc 1457 lib/pengine/bundle.c get_bundle_variant_data(bundle_data, rsc); rsc 1460 lib/pengine/bundle.c status_print(PCMK_XA_ID "=\"%s\" ", rsc->id); rsc 1464 lib/pengine/bundle.c pcmk__flag_text(rsc->flags, pcmk_rsc_unique)); rsc 1466 lib/pengine/bundle.c pcmk__flag_text(rsc->flags, pcmk_rsc_managed)); rsc 1468 lib/pengine/bundle.c pcmk__flag_text(rsc->flags, pcmk_rsc_failed)); rsc 1494 lib/pengine/bundle.c pcmk_resource_t *rsc = va_arg(args, pcmk_resource_t *); rsc 1505 lib/pengine/bundle.c pcmk__assert(rsc != NULL); rsc 1507 lib/pengine/bundle.c get_bundle_variant_data(bundle_data, rsc); rsc 1509 lib/pengine/bundle.c if (rsc->fns->is_filtered(rsc, only_rsc, TRUE)) { rsc 1513 lib/pengine/bundle.c print_everything = pcmk__str_in_list(rsc->id, only_rsc, pcmk__str_star_matches); rsc 1541 lib/pengine/bundle.c const char *unique = pcmk__flag_text(rsc->flags, pcmk_rsc_unique); rsc 1542 lib/pengine/bundle.c const char *maintenance = pcmk__flag_text(rsc->flags, rsc 1544 lib/pengine/bundle.c const char *managed = pcmk__flag_text(rsc->flags, pcmk_rsc_managed); rsc 1545 lib/pengine/bundle.c const char *failed = pcmk__flag_text(rsc->flags, pcmk_rsc_failed); rsc 1549 lib/pengine/bundle.c desc = pe__resource_description(rsc, show_opts); rsc 1552 lib/pengine/bundle.c PCMK_XA_ID, rsc->id, rsc 1606 lib/pengine/bundle.c pcmk_resource_t *rsc = replica->child; rsc 1611 lib/pengine/bundle.c if(rsc == NULL) { rsc 1612 lib/pengine/bundle.c rsc = replica->container; rsc 1627 lib/pengine/bundle.c pe__common_output_html(out, rsc, buffer, node, show_opts); rsc 1640 lib/pengine/bundle.c get_unmanaged_str(const pcmk_resource_t *rsc) rsc 1642 lib/pengine/bundle.c if (pcmk_is_set(rsc->flags, pcmk_rsc_maintenance)) { rsc 1645 lib/pengine/bundle.c if (!pcmk_is_set(rsc->flags, pcmk_rsc_managed)) { rsc 1657 lib/pengine/bundle.c pcmk_resource_t *rsc = va_arg(args, pcmk_resource_t *); rsc 1666 lib/pengine/bundle.c pcmk__assert(rsc != NULL); rsc 1668 lib/pengine/bundle.c get_bundle_variant_data(bundle_data, rsc); rsc 1670 lib/pengine/bundle.c desc = pe__resource_description(rsc, show_opts); rsc 1672 lib/pengine/bundle.c if (rsc->fns->is_filtered(rsc, only_rsc, TRUE)) { rsc 1676 lib/pengine/bundle.c print_everything = pcmk__str_in_list(rsc->id, only_rsc, pcmk__str_star_matches); rsc 1706 lib/pengine/bundle.c rsc->id, bundle_data->image, rsc 1707 lib/pengine/bundle.c pcmk_is_set(rsc->flags, pcmk_rsc_unique)? " (unique)" : "", rsc 1709 lib/pengine/bundle.c get_unmanaged_str(rsc)); rsc 1746 lib/pengine/bundle.c rsc->id, bundle_data->image, rsc 1747 lib/pengine/bundle.c pcmk_is_set(rsc->flags, pcmk_rsc_unique)? " (unique)" : "", rsc 1749 lib/pengine/bundle.c get_unmanaged_str(rsc)); rsc 1766 lib/pengine/bundle.c const pcmk_resource_t *rsc = replica->child; rsc 1771 lib/pengine/bundle.c if(rsc == NULL) { rsc 1772 lib/pengine/bundle.c rsc = replica->container; rsc 1787 lib/pengine/bundle.c pe__common_output_text(out, rsc, buffer, node, show_opts); rsc 1796 lib/pengine/bundle.c pcmk_resource_t *rsc = va_arg(args, pcmk_resource_t *); rsc 1805 lib/pengine/bundle.c desc = pe__resource_description(rsc, show_opts); rsc 1807 lib/pengine/bundle.c get_bundle_variant_data(bundle_data, rsc); rsc 1809 lib/pengine/bundle.c pcmk__assert(rsc != NULL); rsc 1811 lib/pengine/bundle.c if (rsc->fns->is_filtered(rsc, only_rsc, TRUE)) { rsc 1815 lib/pengine/bundle.c print_everything = pcmk__str_in_list(rsc->id, only_rsc, pcmk__str_star_matches); rsc 1845 lib/pengine/bundle.c rsc->id, bundle_data->image, rsc 1846 lib/pengine/bundle.c pcmk_is_set(rsc->flags, pcmk_rsc_unique)? " (unique)" : "", rsc 1848 lib/pengine/bundle.c get_unmanaged_str(rsc)); rsc 1885 lib/pengine/bundle.c rsc->id, bundle_data->image, rsc 1886 lib/pengine/bundle.c pcmk_is_set(rsc->flags, pcmk_rsc_unique)? " (unique)" : "", rsc 1888 lib/pengine/bundle.c get_unmanaged_str(rsc)); rsc 1909 lib/pengine/bundle.c pcmk_resource_t *rsc = replica->child; rsc 1914 lib/pengine/bundle.c if(rsc == NULL) { rsc 1915 lib/pengine/bundle.c rsc = replica->container; rsc 1931 lib/pengine/bundle.c common_print(rsc, pre_text, buffer, node, options, print_data); rsc 1939 lib/pengine/bundle.c pe__print_bundle(pcmk_resource_t *rsc, const char *pre_text, long options, rsc 1944 lib/pengine/bundle.c CRM_CHECK(rsc != NULL, return); rsc 1947 lib/pengine/bundle.c bundle_print_xml(rsc, pre_text, options, print_data); rsc 1951 lib/pengine/bundle.c get_bundle_variant_data(bundle_data, rsc); rsc 1959 lib/pengine/bundle.c rsc->id, bundle_data->image, rsc 1960 lib/pengine/bundle.c pcmk_is_set(rsc->flags, pcmk_rsc_unique)? " (unique)" : "", rsc 1961 lib/pengine/bundle.c pcmk_is_set(rsc->flags, pcmk_rsc_managed)? "" : " (unmanaged)"); rsc 2041 lib/pengine/bundle.c pe__free_bundle(pcmk_resource_t *rsc) rsc 2044 lib/pengine/bundle.c CRM_CHECK(rsc != NULL, return); rsc 2046 lib/pengine/bundle.c get_bundle_variant_data(bundle_data, rsc); rsc 2047 lib/pengine/bundle.c pcmk__rsc_trace(rsc, "Freeing %s", rsc->id); rsc 2064 lib/pengine/bundle.c g_list_free(rsc->children); rsc 2071 lib/pengine/bundle.c common_free(rsc); rsc 2075 lib/pengine/bundle.c pe__bundle_resource_state(const pcmk_resource_t *rsc, gboolean current) rsc 2089 lib/pengine/bundle.c pe_bundle_replicas(const pcmk_resource_t *rsc) rsc 2091 lib/pengine/bundle.c if (pcmk__is_bundle(rsc)) { rsc 2094 lib/pengine/bundle.c get_bundle_variant_data(bundle_data, rsc); rsc 2101 lib/pengine/bundle.c pe__count_bundle(pcmk_resource_t *rsc) rsc 2105 lib/pengine/bundle.c get_bundle_variant_data(bundle_data, rsc); rsc 2125 lib/pengine/bundle.c pe__bundle_is_filtered(const pcmk_resource_t *rsc, GList *only_rsc, rsc 2131 lib/pengine/bundle.c if (pcmk__str_in_list(rsc_printable_id(rsc), only_rsc, pcmk__str_star_matches)) { rsc 2134 lib/pengine/bundle.c get_bundle_variant_data(bundle_data, rsc); rsc 2185 lib/pengine/bundle.c pe__bundle_active_node(const pcmk_resource_t *rsc, unsigned int *count_all, rsc 2202 lib/pengine/bundle.c if (rsc == NULL) { rsc 2209 lib/pengine/bundle.c get_bundle_variant_data(data, rsc); rsc 2246 lib/pengine/bundle.c && !pe__count_active_node(rsc, node, &active, count_all, rsc 2268 lib/pengine/bundle.c pe__bundle_max_per_node(const pcmk_resource_t *rsc) rsc 2272 lib/pengine/bundle.c get_bundle_variant_data(bundle_data, rsc); rsc 50 lib/pengine/clone.c #define get_clone_variant_data(data, rsc) \ rsc 51 lib/pengine/clone.c pcmk__assert(pcmk__is_clone(rsc) && (rsc->variant_opaque != NULL)); \ rsc 52 lib/pengine/clone.c data = (clone_variant_data_t *) rsc->variant_opaque; rsc 171 lib/pengine/clone.c clone_header(pcmk__output_t *out, int *rc, const pcmk_resource_t *rsc, rsc 176 lib/pengine/clone.c if (pcmk_is_set(rsc->flags, pcmk_rsc_promotable)) { rsc 180 lib/pengine/clone.c if (pcmk_is_set(rsc->flags, pcmk_rsc_unique)) { rsc 184 lib/pengine/clone.c if (pe__resource_is_disabled(rsc)) { rsc 188 lib/pengine/clone.c if (pcmk_is_set(rsc->flags, pcmk_rsc_maintenance)) { rsc 191 lib/pengine/clone.c } else if (!pcmk_is_set(rsc->flags, pcmk_rsc_managed)) { rsc 197 lib/pengine/clone.c rsc->id, rsc 204 lib/pengine/clone.c rsc->id, rsc 212 lib/pengine/clone.c pe__force_anon(const char *standard, pcmk_resource_t *rsc, const char *rid, rsc 215 lib/pengine/clone.c if (pcmk__is_clone(rsc)) { rsc 216 lib/pengine/clone.c clone_variant_data_t *clone_data = rsc->variant_opaque; rsc 220 lib/pengine/clone.c "anonymous clones", rsc->id, standard, rid); rsc 229 lib/pengine/clone.c find_clone_instance(const pcmk_resource_t *rsc, const char *sub_id) rsc 236 lib/pengine/clone.c get_clone_variant_data(clone_data, rsc); rsc 240 lib/pengine/clone.c child = pe_find_resource(rsc->children, child_id); rsc 247 lib/pengine/clone.c pe__create_clone_child(pcmk_resource_t *rsc, pcmk_scheduler_t *scheduler) rsc 256 lib/pengine/clone.c get_clone_variant_data(clone_data, rsc); rsc 273 lib/pengine/clone.c if (pe__unpack_resource(child_copy, &child_rsc, rsc, rsc 283 lib/pengine/clone.c rsc->children = g_list_append(rsc->children, child_rsc); rsc 289 lib/pengine/clone.c pcmk__rsc_trace(rsc, "Added %s instance %s", rsc->id, child_rsc->id); rsc 312 lib/pengine/clone.c unpack_meta_int(const pcmk_resource_t *rsc, const char *meta_name, rsc 316 lib/pengine/clone.c const char *value = g_hash_table_lookup(rsc->meta, meta_name); rsc 319 lib/pengine/clone.c value = g_hash_table_lookup(rsc->meta, deprecated_name); rsc 329 lib/pengine/clone.c rsc->id); rsc 337 lib/pengine/clone.c rsc->id); rsc 348 lib/pengine/clone.c clone_unpack(pcmk_resource_t *rsc, pcmk_scheduler_t *scheduler) rsc 352 lib/pengine/clone.c xmlNode *xml_obj = rsc->xml; rsc 355 lib/pengine/clone.c pcmk__rsc_trace(rsc, "Processing resource %s...", rsc->id); rsc 358 lib/pengine/clone.c rsc->variant_opaque = clone_data; rsc 360 lib/pengine/clone.c if (pcmk_is_set(rsc->flags, pcmk_rsc_promotable)) { rsc 364 lib/pengine/clone.c unpack_meta_int(rsc, PCMK_META_PROMOTED_MAX, rsc 370 lib/pengine/clone.c unpack_meta_int(rsc, PCMK_META_PROMOTED_NODE_MAX, rsc 375 lib/pengine/clone.c clone_data->clone_node_max = unpack_meta_int(rsc, PCMK_META_CLONE_NODE_MAX, rsc 381 lib/pengine/clone.c clone_data->clone_max = unpack_meta_int(rsc, PCMK_META_CLONE_MAX, NULL, rsc 384 lib/pengine/clone.c if (crm_is_true(g_hash_table_lookup(rsc->meta, PCMK_META_ORDERED))) { rsc 386 lib/pengine/clone.c "Clone", rsc->id, rsc 392 lib/pengine/clone.c if (!pcmk_is_set(rsc->flags, pcmk_rsc_unique) rsc 397 lib/pengine/clone.c "per node", clone_data->clone_node_max, rsc->id); rsc 401 lib/pengine/clone.c pcmk__rsc_trace(rsc, "Options for %s", rsc->id); rsc 402 lib/pengine/clone.c pcmk__rsc_trace(rsc, "\tClone max: %d", clone_data->clone_max); rsc 403 lib/pengine/clone.c pcmk__rsc_trace(rsc, "\tClone node max: %d", clone_data->clone_node_max); rsc 404 lib/pengine/clone.c pcmk__rsc_trace(rsc, "\tClone is unique: %s", rsc 405 lib/pengine/clone.c pcmk__flag_text(rsc->flags, pcmk_rsc_unique)); rsc 406 lib/pengine/clone.c pcmk__rsc_trace(rsc, "\tClone is promotable: %s", rsc 407 lib/pengine/clone.c pcmk__flag_text(rsc->flags, pcmk_rsc_promotable)); rsc 421 lib/pengine/clone.c pcmk__config_err("%s has nothing to clone", rsc->id); rsc 431 lib/pengine/clone.c if (g_hash_table_lookup(rsc->meta, PCMK_META_RESOURCE_STICKINESS) == NULL) { rsc 432 lib/pengine/clone.c pcmk__insert_meta(rsc, PCMK_META_RESOURCE_STICKINESS, "1"); rsc 439 lib/pengine/clone.c pcmk__insert_meta(rsc, PCMK_META_GLOBALLY_UNIQUE, rsc 440 lib/pengine/clone.c pcmk__flag_text(rsc->flags, pcmk_rsc_unique)); rsc 446 lib/pengine/clone.c if (pe__create_clone_child(rsc, scheduler) == NULL) { rsc 453 lib/pengine/clone.c if (pe__create_clone_child(rsc, scheduler) == NULL) { rsc 459 lib/pengine/clone.c pcmk__rsc_trace(rsc, "Added %d children to resource %s...", rsc 460 lib/pengine/clone.c clone_data->clone_max, rsc->id); rsc 465 lib/pengine/clone.c clone_active(pcmk_resource_t * rsc, gboolean all) rsc 467 lib/pengine/clone.c GList *gIter = rsc->children; rsc 518 lib/pengine/clone.c configured_role_str(pcmk_resource_t * rsc) rsc 520 lib/pengine/clone.c const char *target_role = g_hash_table_lookup(rsc->meta, rsc 523 lib/pengine/clone.c if ((target_role == NULL) && rsc->children && rsc->children->data) { rsc 524 lib/pengine/clone.c pcmk_resource_t *instance = rsc->children->data; // Any instance will do rsc 533 lib/pengine/clone.c configured_role(pcmk_resource_t *rsc) rsc 536 lib/pengine/clone.c const char *target_role = configured_role_str(rsc); rsc 542 lib/pengine/clone.c " for resource %s", rsc->id); rsc 553 lib/pengine/clone.c clone_print_xml(pcmk_resource_t *rsc, const char *pre_text, long options, rsc 557 lib/pengine/clone.c const char *target_role = configured_role_str(rsc); rsc 558 lib/pengine/clone.c GList *gIter = rsc->children; rsc 561 lib/pengine/clone.c status_print(PCMK_XA_ID "=\"%s\" ", rsc->id); rsc 563 lib/pengine/clone.c pcmk__flag_text(rsc->flags, pcmk_rsc_promotable)); rsc 565 lib/pengine/clone.c pcmk__flag_text(rsc->flags, pcmk_rsc_unique)); rsc 567 lib/pengine/clone.c pcmk__flag_text(rsc->flags, pcmk_rsc_managed)); rsc 569 lib/pengine/clone.c pcmk__flag_text(rsc->flags, pcmk_rsc_failed)); rsc 571 lib/pengine/clone.c pcmk__flag_text(rsc->flags, pcmk_rsc_ignore_failure)); rsc 588 lib/pengine/clone.c is_set_recursive(const pcmk_resource_t *rsc, long long flag, bool any) rsc 593 lib/pengine/clone.c if (pcmk_is_set(rsc->flags, flag)) { rsc 601 lib/pengine/clone.c for (gIter = rsc->children; gIter != NULL; gIter = gIter->next) { rsc 623 lib/pengine/clone.c clone_print(pcmk_resource_t *rsc, const char *pre_text, long options, rsc 632 lib/pengine/clone.c GList *gIter = rsc->children; rsc 642 lib/pengine/clone.c clone_print_xml(rsc, pre_text, options, print_data); rsc 646 lib/pengine/clone.c get_clone_variant_data(clone_data, rsc); rsc 651 lib/pengine/clone.c pcmk__s(pre_text, ""), rsc->id, rsc 653 lib/pengine/clone.c pcmk_is_set(rsc->flags, pcmk_rsc_promotable)? " (promotable)" : "", rsc 654 lib/pengine/clone.c pcmk_is_set(rsc->flags, pcmk_rsc_unique)? " (unique)" : "", rsc 655 lib/pengine/clone.c pcmk_is_set(rsc->flags, pcmk_rsc_managed)? "" : " (unmanaged)"); rsc 673 lib/pengine/clone.c if (pcmk_is_set(rsc->flags, pcmk_rsc_unique)) { rsc 676 lib/pengine/clone.c || !pcmk_is_set(rsc->flags, pcmk_rsc_removed)) { rsc 771 lib/pengine/clone.c if (pcmk_is_set(rsc->flags, pcmk_rsc_promotable)) { rsc 772 lib/pengine/clone.c enum rsc_role_e role = configured_role(rsc); rsc 793 lib/pengine/clone.c enum rsc_role_e role = configured_role(rsc); rsc 799 lib/pengine/clone.c if (!pcmk_is_set(rsc->flags, pcmk_rsc_unique) rsc 803 lib/pengine/clone.c GList *list = g_hash_table_get_values(rsc->allowed_nodes); rsc 815 lib/pengine/clone.c list = g_hash_table_get_values(rsc->known_on); rsc 822 lib/pengine/clone.c if (pcmk__find_node_in_list(rsc->running_on, rsc 856 lib/pengine/clone.c pcmk_resource_t *rsc = va_arg(args, pcmk_resource_t *); rsc 860 lib/pengine/clone.c GList *gIter = rsc->children; rsc 866 lib/pengine/clone.c if (rsc->fns->is_filtered(rsc, only_rsc, TRUE)) { rsc 870 lib/pengine/clone.c print_everything = pcmk__str_in_list(rsc_printable_id(rsc), only_rsc, pcmk__str_star_matches) || rsc 871 lib/pengine/clone.c (strstr(rsc->id, ":") != NULL && pcmk__str_in_list(rsc->id, only_rsc, pcmk__str_star_matches)); rsc 887 lib/pengine/clone.c const char *multi_state = pcmk__flag_text(rsc->flags, rsc 889 lib/pengine/clone.c const char *unique = pcmk__flag_text(rsc->flags, pcmk_rsc_unique); rsc 890 lib/pengine/clone.c const char *maintenance = pcmk__flag_text(rsc->flags, rsc 892 lib/pengine/clone.c const char *managed = pcmk__flag_text(rsc->flags, pcmk_rsc_managed); rsc 893 lib/pengine/clone.c const char *disabled = pcmk__btoa(pe__resource_is_disabled(rsc)); rsc 894 lib/pengine/clone.c const char *failed = pcmk__flag_text(rsc->flags, pcmk_rsc_failed); rsc 895 lib/pengine/clone.c const char *ignored = pcmk__flag_text(rsc->flags, rsc 897 lib/pengine/clone.c const char *target_role = configured_role_str(rsc); rsc 898 lib/pengine/clone.c const char *desc = pe__resource_description(rsc, show_opts); rsc 903 lib/pengine/clone.c PCMK_XA_ID, rsc->id, rsc 935 lib/pengine/clone.c pcmk_resource_t *rsc = va_arg(args, pcmk_resource_t *); rsc 945 lib/pengine/clone.c GList *gIter = rsc->children; rsc 954 lib/pengine/clone.c desc = pe__resource_description(rsc, show_opts); rsc 956 lib/pengine/clone.c get_clone_variant_data(clone_data, rsc); rsc 958 lib/pengine/clone.c if (rsc->fns->is_filtered(rsc, only_rsc, TRUE)) { rsc 962 lib/pengine/clone.c print_everything = pcmk__str_in_list(rsc_printable_id(rsc), only_rsc, pcmk__str_star_matches) || rsc 963 lib/pengine/clone.c (strstr(rsc->id, ":") != NULL && pcmk__str_in_list(rsc->id, only_rsc, pcmk__str_star_matches)); rsc 982 lib/pengine/clone.c if (pcmk_is_set(rsc->flags, pcmk_rsc_unique)) { rsc 985 lib/pengine/clone.c || !pcmk_is_set(rsc->flags, pcmk_rsc_removed)) { rsc 1049 lib/pengine/clone.c clone_header(out, &rc, rsc, clone_data, desc); rsc 1080 lib/pengine/clone.c clone_header(out, &rc, rsc, clone_data, desc); rsc 1103 lib/pengine/clone.c clone_header(out, &rc, rsc, clone_data, desc); rsc 1105 lib/pengine/clone.c if (pcmk_is_set(rsc->flags, pcmk_rsc_promotable)) { rsc 1106 lib/pengine/clone.c enum rsc_role_e role = configured_role(rsc); rsc 1129 lib/pengine/clone.c if (!pcmk_is_set(rsc->flags, pcmk_rsc_unique) rsc 1133 lib/pengine/clone.c GList *list = g_hash_table_get_values(rsc->allowed_nodes); rsc 1146 lib/pengine/clone.c list = g_hash_table_get_values(rsc->known_on); rsc 1153 lib/pengine/clone.c if ((pcmk__find_node_in_list(rsc->running_on, rsc 1157 lib/pengine/clone.c xmlNode *probe_op = pe__failed_probe_for_rsc(rsc, node->details->uname); rsc 1160 lib/pengine/clone.c if (configured_role(rsc) == pcmk_role_stopped) { rsc 1186 lib/pengine/clone.c clone_header(out, &rc, rsc, clone_data, desc); rsc 1212 lib/pengine/clone.c clone_header(out, &rc, rsc, clone_data, desc); rsc 1223 lib/pengine/clone.c clone_free(pcmk_resource_t * rsc) rsc 1227 lib/pengine/clone.c get_clone_variant_data(clone_data, rsc); rsc 1229 lib/pengine/clone.c pcmk__rsc_trace(rsc, "Freeing %s", rsc->id); rsc 1231 lib/pengine/clone.c for (GList *gIter = rsc->children; gIter != NULL; gIter = gIter->next) { rsc 1244 lib/pengine/clone.c g_list_free(rsc->children); rsc 1253 lib/pengine/clone.c common_free(rsc); rsc 1257 lib/pengine/clone.c clone_resource_state(const pcmk_resource_t * rsc, gboolean current) rsc 1260 lib/pengine/clone.c GList *gIter = rsc->children; rsc 1271 lib/pengine/clone.c pcmk__rsc_trace(rsc, "%s role: %s", rsc->id, pcmk_role_text(clone_role)); rsc 1283 lib/pengine/clone.c pe__is_universal_clone(const pcmk_resource_t *rsc, rsc 1286 lib/pengine/clone.c if (pcmk__is_clone(rsc)) { rsc 1287 lib/pengine/clone.c clone_variant_data_t *clone_data = rsc->variant_opaque; rsc 1297 lib/pengine/clone.c pe__clone_is_filtered(const pcmk_resource_t *rsc, GList *only_rsc, rsc 1303 lib/pengine/clone.c if (pcmk__str_in_list(rsc_printable_id(rsc), only_rsc, pcmk__str_star_matches)) { rsc 1306 lib/pengine/clone.c get_clone_variant_data(clone_data, rsc); rsc 1311 lib/pengine/clone.c for (const GList *iter = rsc->children; rsc 1328 lib/pengine/clone.c pe__clone_child_id(const pcmk_resource_t *rsc) rsc 1331 lib/pengine/clone.c get_clone_variant_data(clone_data, rsc); rsc 1554 lib/pengine/clone.c pe__clone_max_per_node(const pcmk_resource_t *rsc) rsc 1558 lib/pengine/clone.c get_clone_variant_data(clone_data, rsc); rsc 22 lib/pengine/complex.c static pcmk_node_t *active_node(const pcmk_resource_t *rsc, rsc 138 lib/pengine/complex.c expand_parents_fixed_nvpairs(pcmk_resource_t *rsc, rsc 143 lib/pengine/complex.c pcmk_resource_t *p = rsc->parent; rsc 174 lib/pengine/complex.c get_meta_attributes(GHashTable * meta_hash, pcmk_resource_t * rsc, rsc 178 lib/pengine/complex.c .standard = crm_element_value(rsc->xml, PCMK_XA_CLASS), rsc 179 lib/pengine/complex.c .provider = crm_element_value(rsc->xml, PCMK_XA_PROVIDER), rsc 180 lib/pengine/complex.c .agent = crm_element_value(rsc->xml, PCMK_XA_TYPE) rsc 199 lib/pengine/complex.c for (xmlAttrPtr a = pcmk__xe_first_attr(rsc->xml); a != NULL; a = a->next) { rsc 206 lib/pengine/complex.c pe__unpack_dataset_nvpairs(rsc->xml, PCMK_XE_META_ATTRIBUTES, &rule_data, rsc 213 lib/pengine/complex.c if (rsc->parent != NULL) { rsc 214 lib/pengine/complex.c expand_parents_fixed_nvpairs(rsc, &rule_data, meta_hash, scheduler); rsc 225 lib/pengine/complex.c if (rsc->parent) { rsc 226 lib/pengine/complex.c g_hash_table_foreach(rsc->parent->meta, dup_attr, meta_hash); rsc 231 lib/pengine/complex.c get_rsc_attributes(GHashTable *meta_hash, const pcmk_resource_t *rsc, rsc 246 lib/pengine/complex.c pe__unpack_dataset_nvpairs(rsc->xml, PCMK_XE_INSTANCE_ATTRIBUTES, rsc 250 lib/pengine/complex.c if (rsc->parent != NULL) { rsc 251 lib/pengine/complex.c get_rsc_attributes(meta_hash, rsc->parent, node, scheduler); rsc 442 lib/pengine/complex.c detect_promotable(pcmk_resource_t *rsc) rsc 444 lib/pengine/complex.c const char *promotable = g_hash_table_lookup(rsc->meta, rsc 452 lib/pengine/complex.c if (pcmk__xe_is(rsc->xml, PCMK__XE_PROMOTABLE_LEGACY)) { rsc 458 lib/pengine/complex.c rsc->id); rsc 459 lib/pengine/complex.c pcmk__insert_dup(rsc->meta, PCMK_META_PROMOTABLE, PCMK_VALUE_TRUE); rsc 484 lib/pengine/complex.c pe_rsc_params(pcmk_resource_t *rsc, const pcmk_node_t *node, rsc 496 lib/pengine/complex.c if ((rsc == NULL) || (scheduler == NULL)) { rsc 504 lib/pengine/complex.c if (rsc->parameter_cache == NULL) { rsc 505 lib/pengine/complex.c rsc->parameter_cache = pcmk__strikey_table(free, free_params_table); rsc 507 lib/pengine/complex.c params_on_node = g_hash_table_lookup(rsc->parameter_cache, node_name); rsc 513 lib/pengine/complex.c get_rsc_attributes(params_on_node, rsc, node, scheduler); rsc 514 lib/pengine/complex.c g_hash_table_insert(rsc->parameter_cache, strdup(node_name), rsc 529 lib/pengine/complex.c unpack_requires(pcmk_resource_t *rsc, const char *value, bool is_default) rsc 534 lib/pengine/complex.c pcmk__set_rsc_flags(rsc, pcmk_rsc_needs_quorum); rsc 537 lib/pengine/complex.c pcmk__set_rsc_flags(rsc, pcmk_rsc_needs_fencing); rsc 538 lib/pengine/complex.c if (!pcmk_is_set(rsc->cluster->flags, pcmk_sched_fencing_enabled)) { rsc 540 lib/pengine/complex.c rsc->id); rsc 544 lib/pengine/complex.c if (pcmk_is_set(rsc->flags, pcmk_rsc_fence_device)) { rsc 547 lib/pengine/complex.c "devices cannot require unfencing", rsc->id); rsc 548 lib/pengine/complex.c unpack_requires(rsc, PCMK_VALUE_QUORUM, true); rsc 551 lib/pengine/complex.c } else if (!pcmk_is_set(rsc->cluster->flags, rsc 555 lib/pengine/complex.c "disabled", rsc->id); rsc 556 lib/pengine/complex.c unpack_requires(rsc, PCMK_VALUE_QUORUM, true); rsc 560 lib/pengine/complex.c pcmk__set_rsc_flags(rsc, pcmk_rsc_needs_fencing rsc 567 lib/pengine/complex.c if (pcmk_is_set(rsc->flags, pcmk_rsc_fence_device)) { rsc 570 lib/pengine/complex.c } else if (pcmk__is_primitive(rsc) rsc 571 lib/pengine/complex.c && xml_contains_remote_node(rsc->xml)) { rsc 574 lib/pengine/complex.c } else if (pcmk_is_set(rsc->cluster->flags, rsc 578 lib/pengine/complex.c } else if (pcmk_is_set(rsc->cluster->flags, rsc 582 lib/pengine/complex.c } else if (rsc->cluster->no_quorum_policy == pcmk_no_quorum_ignore) { rsc 592 lib/pengine/complex.c rsc->id, value, orig_value); rsc 594 lib/pengine/complex.c unpack_requires(rsc, value, true); rsc 598 lib/pengine/complex.c pcmk__rsc_trace(rsc, "\tRequired to start: %s%s", value, rsc 603 lib/pengine/complex.c warn_about_deprecated_classes(pcmk_resource_t *rsc) rsc 605 lib/pengine/complex.c const char *std = crm_element_value(rsc->xml, PCMK_XA_CLASS); rsc 611 lib/pengine/complex.c rsc->id); rsc 617 lib/pengine/complex.c rsc->id); rsc 628 lib/pengine/complex.c unpack_priority(pcmk_resource_t *rsc) rsc 630 lib/pengine/complex.c const char *value = g_hash_table_lookup(rsc->meta, rsc 632 lib/pengine/complex.c int rc = pcmk_parse_score(value, &(rsc->priority), 0); rsc 638 lib/pengine/complex.c rsc->id, value, pcmk_rc_str(rc)); rsc 649 lib/pengine/complex.c unpack_stickiness(pcmk_resource_t *rsc) rsc 651 lib/pengine/complex.c const char *value = g_hash_table_lookup(rsc->meta, rsc 662 lib/pengine/complex.c int rc = pcmk_parse_score(value, &(rsc->stickiness), 0); rsc 668 lib/pengine/complex.c rsc->id, value, pcmk_rc_str(rc)); rsc 691 lib/pengine/complex.c pe__unpack_resource(xmlNode *xml_obj, pcmk_resource_t **rsc, rsc 709 lib/pengine/complex.c CRM_CHECK(rsc != NULL, return EINVAL); rsc 711 lib/pengine/complex.c *rsc = NULL; rsc 729 lib/pengine/complex.c *rsc = calloc(1, sizeof(pcmk_resource_t)); rsc 730 lib/pengine/complex.c if (*rsc == NULL) { rsc 734 lib/pengine/complex.c (*rsc)->cluster = scheduler; rsc 738 lib/pengine/complex.c (*rsc)->xml = expanded_xml; rsc 739 lib/pengine/complex.c (*rsc)->orig_xml = xml_obj; rsc 742 lib/pengine/complex.c (*rsc)->xml = xml_obj; rsc 743 lib/pengine/complex.c (*rsc)->orig_xml = NULL; rsc 748 lib/pengine/complex.c (*rsc)->parent = parent; rsc 750 lib/pengine/complex.c ops = pcmk__xe_first_child((*rsc)->xml, PCMK_XE_OPERATIONS, NULL, NULL); rsc 751 lib/pengine/complex.c (*rsc)->ops_xml = expand_idref(ops, scheduler->input); rsc 753 lib/pengine/complex.c (*rsc)->variant = get_resource_type((const char *) (*rsc)->xml->name); rsc 754 lib/pengine/complex.c if ((*rsc)->variant == pcmk_rsc_variant_unknown) { rsc 756 lib/pengine/complex.c id, (*rsc)->xml->name); rsc 757 lib/pengine/complex.c common_free(*rsc); rsc 758 lib/pengine/complex.c *rsc = NULL; rsc 762 lib/pengine/complex.c (*rsc)->meta = pcmk__strkey_table(free, free); rsc 763 lib/pengine/complex.c (*rsc)->allowed_nodes = pcmk__strkey_table(NULL, free); rsc 764 lib/pengine/complex.c (*rsc)->known_on = pcmk__strkey_table(NULL, free); rsc 766 lib/pengine/complex.c value = crm_element_value((*rsc)->xml, PCMK__META_CLONE); rsc 768 lib/pengine/complex.c (*rsc)->id = crm_strdup_printf("%s:%s", id, value); rsc 769 lib/pengine/complex.c pcmk__insert_meta(*rsc, PCMK__META_CLONE, value); rsc 772 lib/pengine/complex.c (*rsc)->id = strdup(id); rsc 775 lib/pengine/complex.c warn_about_deprecated_classes(*rsc); rsc 777 lib/pengine/complex.c (*rsc)->fns = &resource_class_functions[(*rsc)->variant]; rsc 779 lib/pengine/complex.c get_meta_attributes((*rsc)->meta, *rsc, NULL, scheduler); rsc 780 lib/pengine/complex.c (*rsc)->parameters = pe_rsc_params(*rsc, NULL, scheduler); // \deprecated rsc 782 lib/pengine/complex.c (*rsc)->flags = 0; rsc 783 lib/pengine/complex.c pcmk__set_rsc_flags(*rsc, pcmk_rsc_runnable|pcmk_rsc_unassigned); rsc 786 lib/pengine/complex.c pcmk__set_rsc_flags(*rsc, pcmk_rsc_managed); rsc 789 lib/pengine/complex.c (*rsc)->rsc_cons = NULL; rsc 790 lib/pengine/complex.c (*rsc)->rsc_tickets = NULL; rsc 791 lib/pengine/complex.c (*rsc)->actions = NULL; rsc 792 lib/pengine/complex.c (*rsc)->role = pcmk_role_stopped; rsc 793 lib/pengine/complex.c (*rsc)->next_role = pcmk_role_unknown; rsc 795 lib/pengine/complex.c (*rsc)->recovery_type = pcmk_multiply_active_restart; rsc 796 lib/pengine/complex.c (*rsc)->stickiness = 0; rsc 797 lib/pengine/complex.c (*rsc)->migration_threshold = PCMK_SCORE_INFINITY; rsc 798 lib/pengine/complex.c (*rsc)->failure_timeout = 0; rsc 800 lib/pengine/complex.c unpack_priority(*rsc); rsc 802 lib/pengine/complex.c value = g_hash_table_lookup((*rsc)->meta, PCMK_META_CRITICAL); rsc 804 lib/pengine/complex.c pcmk__set_rsc_flags(*rsc, pcmk_rsc_critical); rsc 807 lib/pengine/complex.c value = g_hash_table_lookup((*rsc)->meta, PCMK_META_NOTIFY); rsc 809 lib/pengine/complex.c pcmk__set_rsc_flags(*rsc, pcmk_rsc_notify); rsc 812 lib/pengine/complex.c if (xml_contains_remote_node((*rsc)->xml)) { rsc 813 lib/pengine/complex.c (*rsc)->is_remote_node = TRUE; rsc 814 lib/pengine/complex.c if (g_hash_table_lookup((*rsc)->meta, PCMK__META_CONTAINER)) { rsc 821 lib/pengine/complex.c value = g_hash_table_lookup((*rsc)->meta, PCMK_META_ALLOW_MIGRATE); rsc 823 lib/pengine/complex.c pcmk__set_rsc_flags(*rsc, pcmk_rsc_migratable); rsc 832 lib/pengine/complex.c pcmk__set_rsc_flags(*rsc, pcmk_rsc_migratable); rsc 835 lib/pengine/complex.c value = g_hash_table_lookup((*rsc)->meta, PCMK_META_IS_MANAGED); rsc 844 lib/pengine/complex.c pcmk__set_rsc_flags(*rsc, pcmk_rsc_managed); rsc 846 lib/pengine/complex.c pcmk__clear_rsc_flags(*rsc, pcmk_rsc_managed); rsc 850 lib/pengine/complex.c value = g_hash_table_lookup((*rsc)->meta, PCMK_META_MAINTENANCE); rsc 852 lib/pengine/complex.c pcmk__clear_rsc_flags(*rsc, pcmk_rsc_managed); rsc 853 lib/pengine/complex.c pcmk__set_rsc_flags(*rsc, pcmk_rsc_maintenance); rsc 856 lib/pengine/complex.c pcmk__clear_rsc_flags(*rsc, pcmk_rsc_managed); rsc 857 lib/pengine/complex.c pcmk__set_rsc_flags(*rsc, pcmk_rsc_maintenance); rsc 860 lib/pengine/complex.c if (pcmk__is_clone(pe__const_top_resource(*rsc, false))) { rsc 861 lib/pengine/complex.c value = g_hash_table_lookup((*rsc)->meta, PCMK_META_GLOBALLY_UNIQUE); rsc 863 lib/pengine/complex.c pcmk__set_rsc_flags(*rsc, pcmk_rsc_unique); rsc 865 lib/pengine/complex.c if (detect_promotable(*rsc)) { rsc 866 lib/pengine/complex.c pcmk__set_rsc_flags(*rsc, pcmk_rsc_promotable); rsc 869 lib/pengine/complex.c pcmk__set_rsc_flags(*rsc, pcmk_rsc_unique); rsc 873 lib/pengine/complex.c value = g_hash_table_lookup((*rsc)->meta, PCMK__META_RESTART_TYPE); rsc 875 lib/pengine/complex.c (*rsc)->restart_type = pe_restart_restart; rsc 876 lib/pengine/complex.c pcmk__rsc_trace(*rsc, "%s dependency restart handling: restart", rsc 877 lib/pengine/complex.c (*rsc)->id); rsc 883 lib/pengine/complex.c (*rsc)->restart_type = pe_restart_ignore; rsc 884 lib/pengine/complex.c pcmk__rsc_trace(*rsc, "%s dependency restart handling: ignore", rsc 885 lib/pengine/complex.c (*rsc)->id); rsc 888 lib/pengine/complex.c value = g_hash_table_lookup((*rsc)->meta, PCMK_META_MULTIPLE_ACTIVE); rsc 890 lib/pengine/complex.c (*rsc)->recovery_type = pcmk_multiply_active_stop; rsc 891 lib/pengine/complex.c pcmk__rsc_trace(*rsc, "%s multiple running resource recovery: stop only", rsc 892 lib/pengine/complex.c (*rsc)->id); rsc 895 lib/pengine/complex.c (*rsc)->recovery_type = pcmk_multiply_active_block; rsc 896 lib/pengine/complex.c pcmk__rsc_trace(*rsc, "%s multiple running resource recovery: block", rsc 897 lib/pengine/complex.c (*rsc)->id); rsc 901 lib/pengine/complex.c (*rsc)->recovery_type = pcmk_multiply_active_unexpected; rsc 902 lib/pengine/complex.c pcmk__rsc_trace(*rsc, rsc 905 lib/pengine/complex.c (*rsc)->id); rsc 916 lib/pengine/complex.c (*rsc)->recovery_type = pcmk_multiply_active_restart; rsc 917 lib/pengine/complex.c pcmk__rsc_trace(*rsc, rsc 919 lib/pengine/complex.c (*rsc)->id); rsc 922 lib/pengine/complex.c unpack_stickiness(*rsc); rsc 924 lib/pengine/complex.c value = g_hash_table_lookup((*rsc)->meta, PCMK_META_MIGRATION_THRESHOLD); rsc 934 lib/pengine/complex.c (*rsc)->migration_threshold = char2score(value); rsc 935 lib/pengine/complex.c if ((*rsc)->migration_threshold < 0) { rsc 943 lib/pengine/complex.c (*rsc)->migration_threshold = 1; rsc 948 lib/pengine/complex.c if (pcmk__str_eq(crm_element_value((*rsc)->xml, PCMK_XA_CLASS), rsc 951 lib/pengine/complex.c pcmk__set_rsc_flags(*rsc, pcmk_rsc_fence_device); rsc 954 lib/pengine/complex.c value = g_hash_table_lookup((*rsc)->meta, PCMK_META_REQUIRES); rsc 955 lib/pengine/complex.c unpack_requires(*rsc, value, false); rsc 957 lib/pengine/complex.c value = g_hash_table_lookup((*rsc)->meta, PCMK_META_FAILURE_TIMEOUT); rsc 963 lib/pengine/complex.c (*rsc)->failure_timeout = (int) (interval_ms / 1000); rsc 967 lib/pengine/complex.c GHashTable *params = pe_rsc_params(*rsc, NULL, scheduler); rsc 979 lib/pengine/complex.c pcmk_parse_interval_spec(value, &((*rsc)->remote_reconnect_ms)); rsc 984 lib/pengine/complex.c (*rsc)->failure_timeout = (*rsc)->remote_reconnect_ms / 1000; rsc 988 lib/pengine/complex.c get_target_role(*rsc, &((*rsc)->next_role)); rsc 989 lib/pengine/complex.c pcmk__rsc_trace(*rsc, "%s desired next state: %s", (*rsc)->id, rsc 990 lib/pengine/complex.c ((*rsc)->next_role == pcmk_role_unknown)? rsc 991 lib/pengine/complex.c "default" : pcmk_role_text((*rsc)->next_role)); rsc 993 lib/pengine/complex.c if ((*rsc)->fns->unpack(*rsc, scheduler) == FALSE) { rsc 994 lib/pengine/complex.c (*rsc)->fns->free(*rsc); rsc 995 lib/pengine/complex.c *rsc = NULL; rsc 1001 lib/pengine/complex.c resource_location(*rsc, NULL, 0, "symmetric_default", scheduler); rsc 1006 lib/pengine/complex.c resource_location(*rsc, NULL, 0, "remote_connection_default", rsc 1010 lib/pengine/complex.c pcmk__rsc_trace(*rsc, "%s action notification: %s", (*rsc)->id, rsc 1011 lib/pengine/complex.c pcmk_is_set((*rsc)->flags, pcmk_rsc_notify)? "required" : "not required"); rsc 1013 lib/pengine/complex.c (*rsc)->utilization = pcmk__strkey_table(free, free); rsc 1015 lib/pengine/complex.c pe__unpack_dataset_nvpairs((*rsc)->xml, PCMK_XE_UTILIZATION, &rule_data, rsc 1016 lib/pengine/complex.c (*rsc)->utilization, NULL, FALSE, scheduler); rsc 1020 lib/pengine/complex.c (*rsc)->fns->free(*rsc); rsc 1021 lib/pengine/complex.c *rsc = NULL; rsc 1029 lib/pengine/complex.c is_parent(pcmk_resource_t *child, pcmk_resource_t *rsc) rsc 1033 lib/pengine/complex.c if (parent == NULL || rsc == NULL) { rsc 1037 lib/pengine/complex.c if (parent->parent == rsc) { rsc 1046 lib/pengine/complex.c uber_parent(pcmk_resource_t *rsc) rsc 1048 lib/pengine/complex.c pcmk_resource_t *parent = rsc; rsc 1071 lib/pengine/complex.c pe__const_top_resource(const pcmk_resource_t *rsc, bool include_bundle) rsc 1073 lib/pengine/complex.c const pcmk_resource_t *parent = rsc; rsc 1088 lib/pengine/complex.c common_free(pcmk_resource_t * rsc) rsc 1090 lib/pengine/complex.c if (rsc == NULL) { rsc 1094 lib/pengine/complex.c pcmk__rsc_trace(rsc, "Freeing %s %d", rsc->id, rsc->variant); rsc 1096 lib/pengine/complex.c g_list_free(rsc->rsc_cons); rsc 1097 lib/pengine/complex.c g_list_free(rsc->rsc_cons_lhs); rsc 1098 lib/pengine/complex.c g_list_free(rsc->rsc_tickets); rsc 1099 lib/pengine/complex.c g_list_free(rsc->dangling_migrations); rsc 1101 lib/pengine/complex.c if (rsc->parameter_cache != NULL) { rsc 1102 lib/pengine/complex.c g_hash_table_destroy(rsc->parameter_cache); rsc 1104 lib/pengine/complex.c if (rsc->meta != NULL) { rsc 1105 lib/pengine/complex.c g_hash_table_destroy(rsc->meta); rsc 1107 lib/pengine/complex.c if (rsc->utilization != NULL) { rsc 1108 lib/pengine/complex.c g_hash_table_destroy(rsc->utilization); rsc 1111 lib/pengine/complex.c if ((rsc->parent == NULL) rsc 1112 lib/pengine/complex.c && pcmk_is_set(rsc->flags, pcmk_rsc_removed)) { rsc 1114 lib/pengine/complex.c free_xml(rsc->xml); rsc 1115 lib/pengine/complex.c rsc->xml = NULL; rsc 1116 lib/pengine/complex.c free_xml(rsc->orig_xml); rsc 1117 lib/pengine/complex.c rsc->orig_xml = NULL; rsc 1120 lib/pengine/complex.c } else if (rsc->orig_xml) { rsc 1121 lib/pengine/complex.c free_xml(rsc->xml); rsc 1122 lib/pengine/complex.c rsc->xml = NULL; rsc 1124 lib/pengine/complex.c if (rsc->running_on) { rsc 1125 lib/pengine/complex.c g_list_free(rsc->running_on); rsc 1126 lib/pengine/complex.c rsc->running_on = NULL; rsc 1128 lib/pengine/complex.c if (rsc->known_on) { rsc 1129 lib/pengine/complex.c g_hash_table_destroy(rsc->known_on); rsc 1130 lib/pengine/complex.c rsc->known_on = NULL; rsc 1132 lib/pengine/complex.c if (rsc->actions) { rsc 1133 lib/pengine/complex.c g_list_free(rsc->actions); rsc 1134 lib/pengine/complex.c rsc->actions = NULL; rsc 1136 lib/pengine/complex.c if (rsc->allowed_nodes) { rsc 1137 lib/pengine/complex.c g_hash_table_destroy(rsc->allowed_nodes); rsc 1138 lib/pengine/complex.c rsc->allowed_nodes = NULL; rsc 1140 lib/pengine/complex.c g_list_free(rsc->fillers); rsc 1141 lib/pengine/complex.c g_list_free(rsc->rsc_location); rsc 1142 lib/pengine/complex.c pcmk__rsc_trace(rsc, "Resource freed"); rsc 1143 lib/pengine/complex.c free(rsc->id); rsc 1144 lib/pengine/complex.c free(rsc->clone_name); rsc 1145 lib/pengine/complex.c free(rsc->allocated_to); rsc 1146 lib/pengine/complex.c free(rsc->variant_opaque); rsc 1147 lib/pengine/complex.c free(rsc->pending_task); rsc 1148 lib/pengine/complex.c free(rsc); rsc 1166 lib/pengine/complex.c pe__count_active_node(const pcmk_resource_t *rsc, pcmk_node_t *node, rsc 1173 lib/pengine/complex.c CRM_CHECK((rsc != NULL) && (node != NULL) && (active != NULL), rsc 1188 lib/pengine/complex.c if (rsc->partial_migration_source != NULL) { rsc 1189 lib/pengine/complex.c if (pcmk__same_node(node, rsc->partial_migration_source)) { rsc 1194 lib/pengine/complex.c } else if (!pcmk_is_set(rsc->flags, pcmk_rsc_needs_fencing)) { rsc 1210 lib/pengine/complex.c active_node(const pcmk_resource_t *rsc, unsigned int *count_all, rsc 1221 lib/pengine/complex.c if (rsc == NULL) { rsc 1224 lib/pengine/complex.c for (GList *iter = rsc->running_on; iter != NULL; iter = iter->next) { rsc 1225 lib/pengine/complex.c if (!pe__count_active_node(rsc, (pcmk_node_t *) iter->data, &active, rsc 1247 lib/pengine/complex.c pe__find_active_requires(const pcmk_resource_t *rsc, unsigned int *count) rsc 1249 lib/pengine/complex.c if (rsc == NULL) { rsc 1255 lib/pengine/complex.c } else if (pcmk_is_set(rsc->flags, pcmk_rsc_needs_fencing)) { rsc 1256 lib/pengine/complex.c return rsc->fns->active_node(rsc, count, NULL); rsc 1259 lib/pengine/complex.c return rsc->fns->active_node(rsc, NULL, count); rsc 1264 lib/pengine/complex.c pe__count_common(pcmk_resource_t *rsc) rsc 1266 lib/pengine/complex.c if (rsc->children != NULL) { rsc 1267 lib/pengine/complex.c for (GList *item = rsc->children; item != NULL; item = item->next) { rsc 1271 lib/pengine/complex.c } else if (!pcmk_is_set(rsc->flags, pcmk_rsc_removed) rsc 1272 lib/pengine/complex.c || (rsc->role > pcmk_role_stopped)) { rsc 1273 lib/pengine/complex.c rsc->cluster->ninstances++; rsc 1274 lib/pengine/complex.c if (pe__resource_is_disabled(rsc)) { rsc 1275 lib/pengine/complex.c rsc->cluster->disabled_resources++; rsc 1277 lib/pengine/complex.c if (pcmk_is_set(rsc->flags, pcmk_rsc_blocked)) { rsc 1278 lib/pengine/complex.c rsc->cluster->blocked_resources++; rsc 1292 lib/pengine/complex.c pe__set_next_role(pcmk_resource_t *rsc, enum rsc_role_e role, const char *why) rsc 1294 lib/pengine/complex.c pcmk__assert((rsc != NULL) && (why != NULL)); rsc 1295 lib/pengine/complex.c if (rsc->next_role != role) { rsc 1296 lib/pengine/complex.c pcmk__rsc_trace(rsc, "Resetting next role for %s from %s to %s (%s)", rsc 1297 lib/pengine/complex.c rsc->id, pcmk_role_text(rsc->next_role), rsc 1299 lib/pengine/complex.c rsc->next_role = role; rsc 77 lib/pengine/failcounts.c block_failure(const pcmk_node_t *node, pcmk_resource_t *rsc, rsc 80 lib/pengine/failcounts.c char *xml_name = clone_strip(rsc->id); rsc 99 lib/pengine/failcounts.c xmlXPathObject *xpathObj = xpath_search(rsc->xml, xpath); rsc 140 lib/pengine/failcounts.c lrm_op_xpathObj = xpath_search(rsc->cluster->input, lrm_op_xpath); rsc 184 lib/pengine/failcounts.c rsc_fail_name(const pcmk_resource_t *rsc) rsc 186 lib/pengine/failcounts.c const char *name = (rsc->clone_name? rsc->clone_name : rsc->id); rsc 188 lib/pengine/failcounts.c return pcmk_is_set(rsc->flags, pcmk_rsc_unique)? strdup(name) : clone_strip(name); rsc 248 lib/pengine/failcounts.c generate_fail_regexes(const pcmk_resource_t *rsc, rsc 252 lib/pengine/failcounts.c char *rsc_name = rsc_fail_name(rsc); rsc 253 lib/pengine/failcounts.c const char *version = crm_element_value(rsc->cluster->input, rsc 260 lib/pengine/failcounts.c pcmk_is_set(rsc->flags, pcmk_rsc_unique), rsc 266 lib/pengine/failcounts.c pcmk_is_set(rsc->flags, pcmk_rsc_unique), rsc 279 lib/pengine/failcounts.c pcmk_resource_t *rsc; // Resource to check for fail count rsc 314 lib/pengine/failcounts.c pcmk__rsc_trace(fc_data->rsc, "Added %s (%s) to %s fail count (now %s)", rsc 316 lib/pengine/failcounts.c fc_data->rsc->id, rsc 373 lib/pengine/failcounts.c pe_get_failcount(const pcmk_node_t *node, pcmk_resource_t *rsc, rsc 378 lib/pengine/failcounts.c .rsc = rsc, rsc 386 lib/pengine/failcounts.c CRM_CHECK(generate_fail_regexes(rsc, &fc_data.failcount_re, rsc 395 lib/pengine/failcounts.c if ((fc_data.failcount > 0) && (rsc->failure_timeout > 0) rsc 396 lib/pengine/failcounts.c && block_failure(node, rsc, xml_op)) { rsc 401 lib/pengine/failcounts.c rsc->failure_timeout, rsc->id); rsc 402 lib/pengine/failcounts.c rsc->failure_timeout = 0; rsc 407 lib/pengine/failcounts.c && (fc_data.last_failure > 0) && (rsc->failure_timeout != 0)) { rsc 409 lib/pengine/failcounts.c time_t now = get_effective_time(rsc->cluster); rsc 411 lib/pengine/failcounts.c if (now > (fc_data.last_failure + rsc->failure_timeout)) { rsc 412 lib/pengine/failcounts.c pcmk__rsc_debug(rsc, "Failcount for %s on %s expired after %ds", rsc 413 lib/pengine/failcounts.c rsc->id, pcmk__node_name(node), rsc 414 lib/pengine/failcounts.c rsc->failure_timeout); rsc 429 lib/pengine/failcounts.c if (pcmk_is_set(flags, pcmk__fc_fillers) && (rsc->fillers != NULL) rsc 430 lib/pengine/failcounts.c && !pcmk__is_bundled(rsc)) { rsc 432 lib/pengine/failcounts.c g_list_foreach(rsc->fillers, update_failcount_for_filler, &fc_data); rsc 434 lib/pengine/failcounts.c pcmk__rsc_info(rsc, rsc 437 lib/pengine/failcounts.c rsc->id, pcmk_readable_score(fc_data.failcount), rsc 443 lib/pengine/failcounts.c pcmk__rsc_info(rsc, "%s has failed %s time%s on %s", rsc 444 lib/pengine/failcounts.c rsc->id, pcmk_readable_score(fc_data.failcount), rsc 470 lib/pengine/failcounts.c pe__clear_failcount(pcmk_resource_t *rsc, const pcmk_node_t *node, rsc 476 lib/pengine/failcounts.c CRM_CHECK(rsc && node && reason && scheduler, return NULL); rsc 478 lib/pengine/failcounts.c key = pcmk__op_key(rsc->id, PCMK_ACTION_CLEAR_FAILCOUNT, 0); rsc 479 lib/pengine/failcounts.c clear = custom_action(rsc, key, PCMK_ACTION_CLEAR_FAILCOUNT, node, FALSE, rsc 483 lib/pengine/failcounts.c rsc->id, pcmk__node_name(node), reason, clear->uuid); rsc 100 lib/pengine/group.c inactive_resources(pcmk_resource_t *rsc) rsc 104 lib/pengine/group.c for (GList *gIter = rsc->children; gIter != NULL; gIter = gIter->next) { rsc 116 lib/pengine/group.c group_header(pcmk__output_t *out, int *rc, const pcmk_resource_t *rsc, rsc 127 lib/pengine/group.c if (pe__resource_is_disabled(rsc)) { rsc 131 lib/pengine/group.c if (pcmk_is_set(rsc->flags, pcmk_rsc_maintenance)) { rsc 134 lib/pengine/group.c } else if (!pcmk_is_set(rsc->flags, pcmk_rsc_managed)) { rsc 140 lib/pengine/group.c rsc->id, rsc 146 lib/pengine/group.c rsc->id, rsc 153 lib/pengine/group.c skip_child_rsc(pcmk_resource_t *rsc, pcmk_resource_t *child, rsc 180 lib/pengine/group.c group_unpack(pcmk_resource_t *rsc, pcmk_scheduler_t *scheduler) rsc 182 lib/pengine/group.c xmlNode *xml_obj = rsc->xml; rsc 187 lib/pengine/group.c pcmk__rsc_trace(rsc, "Processing resource %s...", rsc->id); rsc 191 lib/pengine/group.c rsc->variant_opaque = group_data; rsc 194 lib/pengine/group.c set_group_flag(rsc, PCMK_META_ORDERED, pcmk__group_ordered, rsc 196 lib/pengine/group.c set_group_flag(rsc, "collocated", pcmk__group_colocated, rsc 199 lib/pengine/group.c clone_id = crm_element_value(rsc->xml, PCMK__META_CLONE); rsc 209 lib/pengine/group.c if (pe__unpack_resource(xml_native_rsc, &new_rsc, rsc, rsc 214 lib/pengine/group.c rsc->children = g_list_append(rsc->children, new_rsc); rsc 216 lib/pengine/group.c pcmk__rsc_trace(rsc, "Added %s member %s", rsc->id, new_rsc->id); rsc 220 lib/pengine/group.c if (rsc->children == NULL) { rsc 230 lib/pengine/group.c "any members", rsc->id); rsc 236 lib/pengine/group.c group_active(pcmk_resource_t *rsc, gboolean all) rsc 240 lib/pengine/group.c GList *gIter = rsc->children; rsc 265 lib/pengine/group.c group_print_xml(pcmk_resource_t *rsc, const char *pre_text, long options, rsc 268 lib/pengine/group.c GList *gIter = rsc->children; rsc 271 lib/pengine/group.c status_print("%s<group " PCMK_XA_ID "=\"%s\" ", pre_text, rsc->id); rsc 272 lib/pengine/group.c status_print("number_resources=\"%d\" ", g_list_length(rsc->children)); rsc 290 lib/pengine/group.c group_print(pcmk_resource_t *rsc, const char *pre_text, long options, rsc 294 lib/pengine/group.c GList *gIter = rsc->children; rsc 301 lib/pengine/group.c group_print_xml(rsc, pre_text, options, print_data); rsc 307 lib/pengine/group.c status_print("%sResource Group: %s", pre_text ? pre_text : "", rsc->id); rsc 317 lib/pengine/group.c print_rscs_brief(rsc->children, child_text, options, print_data, TRUE); rsc 345 lib/pengine/group.c pcmk_resource_t *rsc = va_arg(args, pcmk_resource_t *); rsc 350 lib/pengine/group.c GList *gIter = rsc->children; rsc 354 lib/pengine/group.c gboolean parent_passes = pcmk__str_in_list(rsc_printable_id(rsc), only_rsc, pcmk__str_star_matches) || rsc 355 lib/pengine/group.c (strstr(rsc->id, ":") != NULL && pcmk__str_in_list(rsc->id, only_rsc, pcmk__str_star_matches)); rsc 357 lib/pengine/group.c desc = pe__resource_description(rsc, show_opts); rsc 359 lib/pengine/group.c if (rsc->fns->is_filtered(rsc, only_rsc, TRUE)) { rsc 366 lib/pengine/group.c if (skip_child_rsc(rsc, child_rsc, parent_passes, only_rsc, show_opts)) { rsc 372 lib/pengine/group.c const char *maintenance = pcmk__flag_text(rsc->flags, rsc 374 lib/pengine/group.c const char *managed = pcmk__flag_text(rsc->flags, pcmk_rsc_managed); rsc 375 lib/pengine/group.c const char *disabled = pcmk__btoa(pe__resource_is_disabled(rsc)); rsc 378 lib/pengine/group.c PCMK_XA_ID, rsc->id, rsc 406 lib/pengine/group.c pcmk_resource_t *rsc = va_arg(args, pcmk_resource_t *); rsc 413 lib/pengine/group.c gboolean parent_passes = pcmk__str_in_list(rsc_printable_id(rsc), only_rsc, pcmk__str_star_matches) || rsc 414 lib/pengine/group.c (strstr(rsc->id, ":") != NULL && pcmk__str_in_list(rsc->id, only_rsc, pcmk__str_star_matches)); rsc 416 lib/pengine/group.c gboolean active = rsc->fns->active(rsc, TRUE); rsc 417 lib/pengine/group.c gboolean partially_active = rsc->fns->active(rsc, FALSE); rsc 419 lib/pengine/group.c desc = pe__resource_description(rsc, show_opts); rsc 421 lib/pengine/group.c if (rsc->fns->is_filtered(rsc, only_rsc, TRUE)) { rsc 426 lib/pengine/group.c GList *rscs = pe__filter_rsc_list(rsc->children, only_rsc); rsc 429 lib/pengine/group.c group_header(out, &rc, rsc, !active && partially_active ? inactive_resources(rsc) : 0, rsc 438 lib/pengine/group.c for (GList *gIter = rsc->children; gIter; gIter = gIter->next) { rsc 441 lib/pengine/group.c if (skip_child_rsc(rsc, child_rsc, parent_passes, only_rsc, show_opts)) { rsc 445 lib/pengine/group.c group_header(out, &rc, rsc, !active && partially_active ? inactive_resources(rsc) : 0, rsc 458 lib/pengine/group.c group_free(pcmk_resource_t * rsc) rsc 460 lib/pengine/group.c CRM_CHECK(rsc != NULL, return); rsc 462 lib/pengine/group.c pcmk__rsc_trace(rsc, "Freeing %s", rsc->id); rsc 464 lib/pengine/group.c for (GList *gIter = rsc->children; gIter != NULL; gIter = gIter->next) { rsc 472 lib/pengine/group.c pcmk__rsc_trace(rsc, "Freeing child list"); rsc 473 lib/pengine/group.c g_list_free(rsc->children); rsc 475 lib/pengine/group.c common_free(rsc); rsc 479 lib/pengine/group.c group_resource_state(const pcmk_resource_t * rsc, gboolean current) rsc 482 lib/pengine/group.c GList *gIter = rsc->children; rsc 493 lib/pengine/group.c pcmk__rsc_trace(rsc, "%s role: %s", rsc->id, pcmk_role_text(group_role)); rsc 498 lib/pengine/group.c pe__group_is_filtered(const pcmk_resource_t *rsc, GList *only_rsc, rsc 504 lib/pengine/group.c && pcmk__str_in_list(rsc_printable_id(pe__const_top_resource(rsc, rsc 508 lib/pengine/group.c } else if (pcmk__str_in_list(rsc_printable_id(rsc), only_rsc, pcmk__str_star_matches)) { rsc 510 lib/pengine/group.c } else if (strstr(rsc->id, ":") != NULL && pcmk__str_in_list(rsc->id, only_rsc, pcmk__str_star_matches)) { rsc 513 lib/pengine/group.c for (const GList *iter = rsc->children; rsc 537 lib/pengine/group.c pe__group_max_per_node(const pcmk_resource_t *rsc) rsc 539 lib/pengine/group.c pcmk__assert(pcmk__is_group(rsc)); rsc 33 lib/pengine/native.c is_multiply_active(const pcmk_resource_t *rsc) rsc 37 lib/pengine/native.c if (pcmk__is_primitive(rsc)) { rsc 38 lib/pengine/native.c pe__find_active_requires(rsc, &count); rsc 44 lib/pengine/native.c native_priority_to_node(pcmk_resource_t *rsc, pcmk_node_t *node, rsc 49 lib/pengine/native.c if ((rsc->priority == 0) || (failed == TRUE)) { rsc 53 lib/pengine/native.c if (rsc->role == pcmk_role_promoted) { rsc 55 lib/pengine/native.c priority = rsc->priority + 1; rsc 58 lib/pengine/native.c priority = rsc->priority; rsc 62 lib/pengine/native.c pcmk__rsc_trace(rsc, "%s now has priority %d with %s'%s' (priority: %d%s)", rsc 64 lib/pengine/native.c (rsc->role == pcmk_role_promoted)? "promoted " : "", rsc 65 lib/pengine/native.c rsc->id, rsc->priority, rsc 66 lib/pengine/native.c (rsc->role == pcmk_role_promoted)? " + 1" : ""); rsc 78 lib/pengine/native.c pcmk__rsc_trace(rsc, rsc 82 lib/pengine/native.c (rsc->role == pcmk_role_promoted)? "promoted " : "", rsc 83 lib/pengine/native.c rsc->id, rsc->priority, rsc 84 lib/pengine/native.c (rsc->role == pcmk_role_promoted)? " + 1" : "", rsc 91 lib/pengine/native.c native_add_running(pcmk_resource_t *rsc, pcmk_node_t *node, rsc 94 lib/pengine/native.c GList *gIter = rsc->running_on; rsc 106 lib/pengine/native.c pcmk__rsc_trace(rsc, "Adding %s to %s %s", rsc->id, pcmk__node_name(node), rsc 107 lib/pengine/native.c pcmk_is_set(rsc->flags, pcmk_rsc_managed)? "" : "(unmanaged)"); rsc 109 lib/pengine/native.c rsc->running_on = g_list_append(rsc->running_on, node); rsc 110 lib/pengine/native.c if (pcmk__is_primitive(rsc)) { rsc 111 lib/pengine/native.c node->details->running_rsc = g_list_append(node->details->running_rsc, rsc); rsc 112 lib/pengine/native.c native_priority_to_node(rsc, node, failed); rsc 114 lib/pengine/native.c pcmk__clear_rsc_flags(rsc, pcmk_rsc_managed); rsc 115 lib/pengine/native.c pcmk__set_rsc_flags(rsc, pcmk_rsc_maintenance); rsc 119 lib/pengine/native.c if (!pcmk_is_set(rsc->flags, pcmk_rsc_managed)) { rsc 120 lib/pengine/native.c pcmk_resource_t *p = rsc->parent; rsc 122 lib/pengine/native.c pcmk__rsc_info(rsc, "resource %s isn't managed", rsc->id); rsc 123 lib/pengine/native.c resource_location(rsc, node, PCMK_SCORE_INFINITY, rsc 134 lib/pengine/native.c if (is_multiply_active(rsc)) { rsc 135 lib/pengine/native.c switch (rsc->recovery_type) { rsc 142 lib/pengine/native.c if (rsc->allowed_nodes != NULL) { rsc 143 lib/pengine/native.c g_hash_table_destroy(rsc->allowed_nodes); rsc 145 lib/pengine/native.c rsc->allowed_nodes = pe__node_list2table(scheduler->nodes); rsc 146 lib/pengine/native.c g_hash_table_iter_init(&gIter, rsc->allowed_nodes); rsc 153 lib/pengine/native.c pcmk__clear_rsc_flags(rsc, pcmk_rsc_managed); rsc 154 lib/pengine/native.c pcmk__set_rsc_flags(rsc, pcmk_rsc_blocked); rsc 160 lib/pengine/native.c if ((pcmk__is_group(rsc->parent) rsc 161 lib/pengine/native.c || pcmk__is_bundle(rsc->parent)) rsc 162 lib/pengine/native.c && (rsc->parent->recovery_type == pcmk_multiply_active_block)) { rsc 163 lib/pengine/native.c GList *gIter = rsc->parent->children; rsc 182 lib/pengine/native.c rsc->id, pcmk__node_name(node), rsc 183 lib/pengine/native.c pcmk__multiply_active_text(rsc->recovery_type)); rsc 186 lib/pengine/native.c pcmk__rsc_trace(rsc, "Resource %s is active on %s", rsc 187 lib/pengine/native.c rsc->id, pcmk__node_name(node)); rsc 190 lib/pengine/native.c if (rsc->parent != NULL) { rsc 191 lib/pengine/native.c native_add_running(rsc->parent, node, scheduler, FALSE); rsc 196 lib/pengine/native.c recursive_clear_unique(pcmk_resource_t *rsc, gpointer user_data) rsc 198 lib/pengine/native.c pcmk__clear_rsc_flags(rsc, pcmk_rsc_unique); rsc 199 lib/pengine/native.c pcmk__insert_meta(rsc, PCMK_META_GLOBALLY_UNIQUE, PCMK_VALUE_FALSE); rsc 200 lib/pengine/native.c g_list_foreach(rsc->children, (GFunc) recursive_clear_unique, NULL); rsc 204 lib/pengine/native.c native_unpack(pcmk_resource_t *rsc, pcmk_scheduler_t *scheduler) rsc 206 lib/pengine/native.c pcmk_resource_t *parent = uber_parent(rsc); rsc 207 lib/pengine/native.c const char *standard = crm_element_value(rsc->xml, PCMK_XA_CLASS); rsc 210 lib/pengine/native.c pcmk__rsc_trace(rsc, "Processing resource %s...", rsc->id); rsc 214 lib/pengine/native.c && pcmk_is_set(rsc->flags, pcmk_rsc_unique) rsc 222 lib/pengine/native.c pe__force_anon(standard, parent, rsc->id, scheduler); rsc 230 lib/pengine/native.c recursive_clear_unique(rsc, NULL); rsc 237 lib/pengine/native.c rsc->id, standard); rsc 244 lib/pengine/native.c rsc_is_on_node(pcmk_resource_t *rsc, const pcmk_node_t *node, int flags) rsc 246 lib/pengine/native.c pcmk__rsc_trace(rsc, "Checking whether %s is on %s", rsc 247 lib/pengine/native.c rsc->id, pcmk__node_name(node)); rsc 250 lib/pengine/native.c && (rsc->running_on != NULL)) { rsc 252 lib/pengine/native.c for (GList *iter = rsc->running_on; iter; iter = iter->next) { rsc 259 lib/pengine/native.c && (rsc->running_on == NULL)) { rsc 263 lib/pengine/native.c && (rsc->allocated_to != NULL) rsc 264 lib/pengine/native.c && pcmk__same_node(rsc->allocated_to, node)) { rsc 271 lib/pengine/native.c native_find_rsc(pcmk_resource_t *rsc, const char *id, rsc 277 lib/pengine/native.c CRM_CHECK(id && rsc && rsc->id, return NULL); rsc 280 lib/pengine/native.c const char *rid = pcmk__xe_id(rsc->xml); rsc 282 lib/pengine/native.c if (!pcmk__is_clone(pe__const_top_resource(rsc, false))) { rsc 285 lib/pengine/native.c } else if (!strcmp(id, rsc->id) || pcmk__str_eq(id, rid, pcmk__str_none)) { rsc 289 lib/pengine/native.c } else if (!strcmp(id, rsc->id)) { rsc 293 lib/pengine/native.c && rsc->clone_name && strcmp(rsc->clone_name, id) == 0) { rsc 298 lib/pengine/native.c && !pcmk_is_set(rsc->flags, pcmk_rsc_unique))) { rsc 299 lib/pengine/native.c match = pe_base_name_eq(rsc, id); rsc 303 lib/pengine/native.c if (!rsc_is_on_node(rsc, on_node, flags)) { rsc 309 lib/pengine/native.c return rsc; rsc 312 lib/pengine/native.c for (GList *gIter = rsc->children; gIter != NULL; gIter = gIter->next) { rsc 315 lib/pengine/native.c result = rsc->fns->find_rsc(child, id, on_node, flags); rsc 325 lib/pengine/native.c native_parameter(pcmk_resource_t *rsc, pcmk_node_t *node, gboolean create, rsc 331 lib/pengine/native.c CRM_CHECK(rsc != NULL, return NULL); rsc 334 lib/pengine/native.c pcmk__rsc_trace(rsc, "Looking up %s in %s", name, rsc->id); rsc 335 lib/pengine/native.c params = pe_rsc_params(rsc, node, scheduler); rsc 339 lib/pengine/native.c value = g_hash_table_lookup(rsc->meta, name); rsc 345 lib/pengine/native.c native_active(pcmk_resource_t * rsc, gboolean all) rsc 347 lib/pengine/native.c for (GList *gIter = rsc->running_on; gIter != NULL; gIter = gIter->next) { rsc 351 lib/pengine/native.c pcmk__rsc_trace(rsc, "Resource %s: %s is unclean", rsc 352 lib/pengine/native.c rsc->id, pcmk__node_name(a_node)); rsc 355 lib/pengine/native.c && pcmk_is_set(rsc->flags, pcmk_rsc_managed)) { rsc 356 lib/pengine/native.c pcmk__rsc_trace(rsc, "Resource %s: %s is offline", rsc 357 lib/pengine/native.c rsc->id, pcmk__node_name(a_node)); rsc 359 lib/pengine/native.c pcmk__rsc_trace(rsc, "Resource %s active on %s", rsc 360 lib/pengine/native.c rsc->id, pcmk__node_name(a_node)); rsc 373 lib/pengine/native.c native_pending_state(const pcmk_resource_t *rsc) rsc 377 lib/pengine/native.c if (pcmk__str_eq(rsc->pending_task, PCMK_ACTION_START, pcmk__str_casei)) { rsc 380 lib/pengine/native.c } else if (pcmk__str_eq(rsc->pending_task, PCMK_ACTION_STOP, rsc 384 lib/pengine/native.c } else if (pcmk__str_eq(rsc->pending_task, PCMK_ACTION_MIGRATE_TO, rsc 388 lib/pengine/native.c } else if (pcmk__str_eq(rsc->pending_task, PCMK_ACTION_MIGRATE_FROM, rsc 393 lib/pengine/native.c } else if (pcmk__str_eq(rsc->pending_task, PCMK_ACTION_PROMOTE, rsc 397 lib/pengine/native.c } else if (pcmk__str_eq(rsc->pending_task, PCMK_ACTION_DEMOTE, rsc 406 lib/pengine/native.c native_pending_task(const pcmk_resource_t *rsc) rsc 410 lib/pengine/native.c if (pcmk__str_eq(rsc->pending_task, PCMK_ACTION_MONITOR, pcmk__str_casei)) { rsc 428 lib/pengine/native.c native_displayable_role(const pcmk_resource_t *rsc) rsc 430 lib/pengine/native.c enum rsc_role_e role = rsc->role; rsc 433 lib/pengine/native.c && pcmk_is_set(pe__const_top_resource(rsc, false)->flags, rsc 442 lib/pengine/native.c native_displayable_state(const pcmk_resource_t *rsc, bool print_pending) rsc 447 lib/pengine/native.c rsc_state = native_pending_state(rsc); rsc 450 lib/pengine/native.c rsc_state = pcmk_role_text(native_displayable_role(rsc)); rsc 460 lib/pengine/native.c native_print_xml(pcmk_resource_t *rsc, const char *pre_text, long options, rsc 463 lib/pengine/native.c const char *class = crm_element_value(rsc->xml, PCMK_XA_CLASS); rsc 464 lib/pengine/native.c const char *prov = crm_element_value(rsc->xml, PCMK_XA_PROVIDER); rsc 465 lib/pengine/native.c const char *rsc_state = native_displayable_state(rsc, pcmk_is_set(options, pe_print_pending)); rsc 470 lib/pengine/native.c status_print(PCMK_XA_ID "=\"%s\" ", rsc_printable_id(rsc)); rsc 474 lib/pengine/native.c crm_element_value(rsc->xml, PCMK_XA_TYPE)); rsc 477 lib/pengine/native.c if (rsc->meta) { rsc 478 lib/pengine/native.c target_role = g_hash_table_lookup(rsc->meta, PCMK_META_TARGET_ROLE); rsc 483 lib/pengine/native.c status_print("active=\"%s\" ", pcmk__btoa(rsc->fns->active(rsc, TRUE))); rsc 485 lib/pengine/native.c pcmk__flag_text(rsc->flags, pcmk_rsc_removed)); rsc 487 lib/pengine/native.c pcmk__flag_text(rsc->flags, pcmk_rsc_blocked)); rsc 489 lib/pengine/native.c pcmk__flag_text(rsc->flags, pcmk_rsc_managed)); rsc 491 lib/pengine/native.c pcmk__flag_text(rsc->flags, pcmk_rsc_failed)); rsc 493 lib/pengine/native.c pcmk__flag_text(rsc->flags, pcmk_rsc_ignore_failure)); rsc 494 lib/pengine/native.c status_print("nodes_running_on=\"%d\" ", g_list_length(rsc->running_on)); rsc 497 lib/pengine/native.c const char *pending_task = native_pending_task(rsc); rsc 508 lib/pengine/native.c } else if (rsc->running_on != NULL) { rsc 509 lib/pengine/native.c GList *gIter = rsc->running_on; rsc 559 lib/pengine/native.c pcmk__native_output_string(const pcmk_resource_t *rsc, const char *name, rsc 563 lib/pengine/native.c const char *class = crm_element_value(rsc->xml, PCMK_XA_CLASS); rsc 565 lib/pengine/native.c const char *kind = crm_element_value(rsc->xml, PCMK_XA_TYPE); rsc 569 lib/pengine/native.c if (!pcmk__is_primitive(rsc)) { rsc 578 lib/pengine/native.c provider = crm_element_value(rsc->xml, PCMK_XA_PROVIDER); rsc 581 lib/pengine/native.c if ((node == NULL) && (rsc->lock_node != NULL)) { rsc 582 lib/pengine/native.c node = rsc->lock_node; rsc 585 lib/pengine/native.c || pcmk__list_of_multiple(rsc->running_on)) { rsc 597 lib/pengine/native.c if (pcmk_is_set(rsc->flags, pcmk_rsc_removed)) { rsc 600 lib/pengine/native.c if (pcmk_is_set(rsc->flags, pcmk_rsc_failed)) { rsc 601 lib/pengine/native.c enum rsc_role_e role = native_displayable_role(rsc); rsc 610 lib/pengine/native.c pcmk__add_word(&outstr, 0, native_displayable_state(rsc, show_pending)); rsc 617 lib/pengine/native.c if (native_displayable_role(rsc) == pcmk_role_stopped) { rsc 618 lib/pengine/native.c xmlNode *probe_op = pe__failed_probe_for_rsc(rsc, node ? node->details->uname : NULL); rsc 633 lib/pengine/native.c if (node && (node == rsc->lock_node)) { rsc 637 lib/pengine/native.c const char *pending_task = native_pending_task(rsc); rsc 647 lib/pengine/native.c " %s for resource %s", target_role, rsc->id); rsc 655 lib/pengine/native.c if (pcmk_is_set(pe__const_top_resource(rsc, false)->flags, rsc 674 lib/pengine/native.c if (pcmk_any_flags_set(rsc->flags, rsc 676 lib/pengine/native.c if (pcmk_is_set(rsc->flags, pcmk_rsc_blocked)) { rsc 679 lib/pengine/native.c } else if (pcmk_is_set(rsc->flags, pcmk_rsc_maintenance)) { rsc 682 lib/pengine/native.c } else if (!pcmk_is_set(rsc->flags, pcmk_rsc_managed)) { rsc 686 lib/pengine/native.c if (pcmk_is_set(rsc->flags, pcmk_rsc_ignore_failure)) { rsc 697 lib/pengine/native.c || pcmk__list_of_multiple(rsc->running_on)) { rsc 698 lib/pengine/native.c const char *desc = crm_element_value(rsc->xml, PCMK_XA_DESCRIPTION); rsc 709 lib/pengine/native.c && pcmk__list_of_multiple(rsc->running_on)) { rsc 712 lib/pengine/native.c for (GList *iter = rsc->running_on; iter != NULL; iter = iter->next) { rsc 726 lib/pengine/native.c pe__common_output_html(pcmk__output_t *out, const pcmk_resource_t *rsc, rsc 730 lib/pengine/native.c const char *kind = crm_element_value(rsc->xml, PCMK_XA_TYPE); rsc 737 lib/pengine/native.c pcmk__assert((kind != NULL) && pcmk__is_primitive(rsc)); rsc 739 lib/pengine/native.c if (rsc->meta) { rsc 740 lib/pengine/native.c const char *is_internal = g_hash_table_lookup(rsc->meta, rsc 746 lib/pengine/native.c crm_trace("skipping print of internal resource %s", rsc->id); rsc 749 lib/pengine/native.c target_role = g_hash_table_lookup(rsc->meta, PCMK_META_TARGET_ROLE); rsc 752 lib/pengine/native.c if (!pcmk_is_set(rsc->flags, pcmk_rsc_managed)) { rsc 755 lib/pengine/native.c } else if (pcmk_is_set(rsc->flags, pcmk_rsc_failed)) { rsc 758 lib/pengine/native.c } else if (pcmk__is_primitive(rsc) && (rsc->running_on == NULL)) { rsc 761 lib/pengine/native.c } else if (pcmk__list_of_multiple(rsc->running_on)) { rsc 764 lib/pengine/native.c } else if (pcmk_is_set(rsc->flags, pcmk_rsc_ignore_failure)) { rsc 773 lib/pengine/native.c content = pcmk__native_output_string(rsc, name, node, show_opts, rsc 782 lib/pengine/native.c pe__common_output_text(pcmk__output_t *out, const pcmk_resource_t *rsc, rsc 788 lib/pengine/native.c pcmk__assert(pcmk__is_primitive(rsc)); rsc 790 lib/pengine/native.c if (rsc->meta) { rsc 791 lib/pengine/native.c const char *is_internal = g_hash_table_lookup(rsc->meta, rsc 797 lib/pengine/native.c crm_trace("skipping print of internal resource %s", rsc->id); rsc 800 lib/pengine/native.c target_role = g_hash_table_lookup(rsc->meta, PCMK_META_TARGET_ROLE); rsc 804 lib/pengine/native.c gchar *s = pcmk__native_output_string(rsc, name, node, show_opts, rsc 819 lib/pengine/native.c common_print(pcmk_resource_t *rsc, const char *pre_text, const char *name, rsc 824 lib/pengine/native.c pcmk__assert(pcmk__is_primitive(rsc)); rsc 826 lib/pengine/native.c if (rsc->meta) { rsc 827 lib/pengine/native.c const char *is_internal = g_hash_table_lookup(rsc->meta, rsc 833 lib/pengine/native.c crm_trace("skipping print of internal resource %s", rsc->id); rsc 836 lib/pengine/native.c target_role = g_hash_table_lookup(rsc->meta, PCMK_META_TARGET_ROLE); rsc 840 lib/pengine/native.c native_print_xml(rsc, pre_text, options, print_data); rsc 849 lib/pengine/native.c if (!pcmk_is_set(rsc->flags, pcmk_rsc_managed)) { rsc 852 lib/pengine/native.c } else if (pcmk_is_set(rsc->flags, pcmk_rsc_failed)) { rsc 855 lib/pengine/native.c } else if (rsc->running_on == NULL) { rsc 858 lib/pengine/native.c } else if (pcmk__list_of_multiple(rsc->running_on)) { rsc 861 lib/pengine/native.c } else if (pcmk_is_set(rsc->flags, pcmk_rsc_ignore_failure)) { rsc 870 lib/pengine/native.c gchar *resource_s = pcmk__native_output_string(rsc, name, node, options, rsc 881 lib/pengine/native.c && pcmk__list_of_multiple(rsc->running_on)) { rsc 883 lib/pengine/native.c GList *gIter = rsc->running_on; rsc 939 lib/pengine/native.c native_print(pcmk_resource_t *rsc, const char *pre_text, long options, rsc 944 lib/pengine/native.c pcmk__assert(pcmk__is_primitive(rsc)); rsc 947 lib/pengine/native.c native_print_xml(rsc, pre_text, options, print_data); rsc 951 lib/pengine/native.c node = pcmk__current_node(rsc); rsc 955 lib/pengine/native.c node = rsc->pending_node; rsc 958 lib/pengine/native.c common_print(rsc, pre_text, rsc_printable_id(rsc), node, options, print_data); rsc 967 lib/pengine/native.c pcmk_resource_t *rsc = va_arg(args, pcmk_resource_t *); rsc 973 lib/pengine/native.c const char *class = crm_element_value(rsc->xml, PCMK_XA_CLASS); rsc 974 lib/pengine/native.c const char *prov = crm_element_value(rsc->xml, PCMK_XA_PROVIDER); rsc 977 lib/pengine/native.c const char *rsc_state = native_displayable_state(rsc, print_pending); rsc 979 lib/pengine/native.c const char *active = pcmk__btoa(rsc->fns->active(rsc, TRUE)); rsc 980 lib/pengine/native.c const char *orphaned = pcmk__flag_text(rsc->flags, pcmk_rsc_removed); rsc 981 lib/pengine/native.c const char *blocked = pcmk__flag_text(rsc->flags, pcmk_rsc_blocked); rsc 982 lib/pengine/native.c const char *maintenance = pcmk__flag_text(rsc->flags, pcmk_rsc_maintenance); rsc 983 lib/pengine/native.c const char *managed = pcmk__flag_text(rsc->flags, pcmk_rsc_managed); rsc 984 lib/pengine/native.c const char *failed = pcmk__flag_text(rsc->flags, pcmk_rsc_failed); rsc 985 lib/pengine/native.c const char *ignored = pcmk__flag_text(rsc->flags, pcmk_rsc_ignore_failure); rsc 987 lib/pengine/native.c const char *pending = print_pending? native_pending_task(rsc) : NULL; rsc 989 lib/pengine/native.c const char *desc = pe__resource_description(rsc, show_opts); rsc 991 lib/pengine/native.c pcmk__assert(pcmk__is_primitive(rsc)); rsc 993 lib/pengine/native.c if (rsc->fns->is_filtered(rsc, only_rsc, TRUE)) { rsc 1000 lib/pengine/native.c crm_element_value(rsc->xml, PCMK_XA_TYPE)); rsc 1002 lib/pengine/native.c if (rsc->meta != NULL) { rsc 1003 lib/pengine/native.c target_role = g_hash_table_lookup(rsc->meta, PCMK_META_TARGET_ROLE); rsc 1006 lib/pengine/native.c nodes_running_on = pcmk__itoa(g_list_length(rsc->running_on)); rsc 1008 lib/pengine/native.c if (rsc->lock_node != NULL) { rsc 1009 lib/pengine/native.c locked_to = rsc->lock_node->details->uname; rsc 1013 lib/pengine/native.c PCMK_XA_ID, rsc_printable_id(rsc), rsc 1033 lib/pengine/native.c if (rsc->running_on != NULL) { rsc 1034 lib/pengine/native.c GList *gIter = rsc->running_on; rsc 1059 lib/pengine/native.c pcmk_resource_t *rsc = va_arg(args, pcmk_resource_t *); rsc 1063 lib/pengine/native.c const pcmk_node_t *node = pcmk__current_node(rsc); rsc 1065 lib/pengine/native.c if (rsc->fns->is_filtered(rsc, only_rsc, TRUE)) { rsc 1069 lib/pengine/native.c pcmk__assert(pcmk__is_primitive(rsc)); rsc 1073 lib/pengine/native.c node = rsc->pending_node; rsc 1075 lib/pengine/native.c return pe__common_output_html(out, rsc, rsc_printable_id(rsc), node, show_opts); rsc 1084 lib/pengine/native.c pcmk_resource_t *rsc = va_arg(args, pcmk_resource_t *); rsc 1088 lib/pengine/native.c const pcmk_node_t *node = pcmk__current_node(rsc); rsc 1090 lib/pengine/native.c pcmk__assert(pcmk__is_primitive(rsc)); rsc 1092 lib/pengine/native.c if (rsc->fns->is_filtered(rsc, only_rsc, TRUE)) { rsc 1098 lib/pengine/native.c node = rsc->pending_node; rsc 1100 lib/pengine/native.c return pe__common_output_text(out, rsc, rsc_printable_id(rsc), node, show_opts); rsc 1104 lib/pengine/native.c native_free(pcmk_resource_t * rsc) rsc 1106 lib/pengine/native.c pcmk__rsc_trace(rsc, "Freeing resource action list (not the data)"); rsc 1107 lib/pengine/native.c common_free(rsc); rsc 1111 lib/pengine/native.c native_resource_state(const pcmk_resource_t * rsc, gboolean current) rsc 1113 lib/pengine/native.c enum rsc_role_e role = rsc->next_role; rsc 1116 lib/pengine/native.c role = rsc->role; rsc 1118 lib/pengine/native.c pcmk__rsc_trace(rsc, "%s state: %s", rsc->id, pcmk_role_text(role)); rsc 1134 lib/pengine/native.c native_location(const pcmk_resource_t *rsc, GList **list, int current) rsc 1140 lib/pengine/native.c if (rsc->children) { rsc 1141 lib/pengine/native.c GList *gIter = rsc->children; rsc 1151 lib/pengine/native.c if (rsc->running_on) { rsc 1152 lib/pengine/native.c result = g_list_copy(rsc->running_on); rsc 1154 lib/pengine/native.c if ((current == 2) && rsc->pending_node rsc 1155 lib/pengine/native.c && !pe_find_node_id(result, rsc->pending_node->details->id)) { rsc 1156 lib/pengine/native.c result = g_list_append(result, rsc->pending_node); rsc 1159 lib/pengine/native.c } else if (current == FALSE && rsc->allocated_to) { rsc 1160 lib/pengine/native.c result = g_list_append(NULL, rsc->allocated_to); rsc 1189 lib/pengine/native.c pcmk_resource_t *rsc = (pcmk_resource_t *) gIter->data; rsc 1191 lib/pengine/native.c const char *class = crm_element_value(rsc->xml, PCMK_XA_CLASS); rsc 1192 lib/pengine/native.c const char *kind = crm_element_value(rsc->xml, PCMK_XA_TYPE); rsc 1200 lib/pengine/native.c if (!pcmk__is_primitive(rsc)) { rsc 1206 lib/pengine/native.c const char *prov = crm_element_value(rsc->xml, PCMK_XA_PROVIDER); rsc 1227 lib/pengine/native.c GList *gIter2 = rsc->running_on; rsc 1234 lib/pengine/native.c pcmk_is_set(rsc->flags, pcmk_rsc_managed)) { rsc 1443 lib/pengine/native.c pe__native_is_filtered(const pcmk_resource_t *rsc, GList *only_rsc, rsc 1446 lib/pengine/native.c if (pcmk__str_in_list(rsc_printable_id(rsc), only_rsc, pcmk__str_star_matches) || rsc 1447 lib/pengine/native.c pcmk__str_in_list(rsc->id, only_rsc, pcmk__str_star_matches)) { rsc 1449 lib/pengine/native.c } else if (check_parent && rsc->parent) { rsc 1450 lib/pengine/native.c const pcmk_resource_t *up = pe__const_top_resource(rsc, true); rsc 1467 lib/pengine/native.c pe__primitive_max_per_node(const pcmk_resource_t *rsc) rsc 1469 lib/pengine/native.c pcmk__assert(pcmk__is_primitive(rsc)); rsc 55 lib/pengine/pe_actions.c find_existing_action(const char *key, const pcmk_resource_t *rsc, rsc 64 lib/pengine/pe_actions.c matches = find_actions(((rsc == NULL)? scheduler->actions : rsc->actions), rsc 87 lib/pengine/pe_actions.c find_exact_action_config(const pcmk_resource_t *rsc, const char *action_name, rsc 90 lib/pengine/pe_actions.c for (xmlNode *operation = pcmk__xe_first_child(rsc->ops_xml, PCMK_XE_OP, rsc 132 lib/pengine/pe_actions.c pcmk__find_action_config(const pcmk_resource_t *rsc, const char *action_name, rsc 138 lib/pengine/pe_actions.c action_config = find_exact_action_config(rsc, action_name, interval_ms, rsc 146 lib/pengine/pe_actions.c action_config = find_exact_action_config(rsc, "migrate", 0, rsc 169 lib/pengine/pe_actions.c new_action(char *key, const char *task, pcmk_resource_t *rsc, rsc 174 lib/pengine/pe_actions.c action->rsc = rsc; rsc 194 lib/pengine/pe_actions.c if (rsc == NULL) { rsc 200 lib/pengine/pe_actions.c action->op_entry = pcmk__find_action_config(rsc, task, interval_ms, rsc 207 lib/pengine/pe_actions.c action->op_entry = find_exact_action_config(rsc, PCMK_ACTION_NOTIFY, rsc 214 lib/pengine/pe_actions.c pcmk__rsc_trace(rsc, "Created %s action %d (%s): %s for %s on %s", rsc 217 lib/pengine/pe_actions.c ((rsc == NULL)? "no resource" : rsc->id), rsc 222 lib/pengine/pe_actions.c if (rsc == NULL) { rsc 225 lib/pengine/pe_actions.c rsc->actions = g_list_prepend(rsc->actions, action); rsc 272 lib/pengine/pe_actions.c if ((action->rsc != NULL) && (action->node != NULL) rsc 274 lib/pengine/pe_actions.c && !pcmk_is_set(action->rsc->flags, pcmk_rsc_managed) rsc 276 lib/pengine/pe_actions.c pcmk__rsc_debug(action->rsc, rsc 279 lib/pengine/pe_actions.c action->rsc->id); rsc 290 lib/pengine/pe_actions.c effective_quorum_policy(pcmk_resource_t *rsc, pcmk_scheduler_t *scheduler) rsc 298 lib/pengine/pe_actions.c switch (rsc->role) { rsc 301 lib/pengine/pe_actions.c if (rsc->next_role > pcmk_role_unpromoted) { rsc 302 lib/pengine/pe_actions.c pe__set_next_role(rsc, pcmk_role_unpromoted, rsc 333 lib/pengine/pe_actions.c pcmk__rsc_trace(action->rsc, "%s is unrunnable (unallocated)", rsc 344 lib/pengine/pe_actions.c if (pcmk_is_set(action->rsc->flags, pcmk_rsc_managed) rsc 366 lib/pengine/pe_actions.c pcmk__rsc_debug(action->rsc, rsc 372 lib/pengine/pe_actions.c pcmk__rsc_trace(action->rsc, rsc 379 lib/pengine/pe_actions.c switch (effective_quorum_policy(action->rsc, scheduler)) { rsc 381 lib/pengine/pe_actions.c pcmk__rsc_debug(action->rsc, rsc 389 lib/pengine/pe_actions.c if (!action->rsc->fns->active(action->rsc, TRUE) rsc 390 lib/pengine/pe_actions.c || (action->rsc->next_role > action->rsc->role)) { rsc 391 lib/pengine/pe_actions.c pcmk__rsc_debug(action->rsc, rsc 416 lib/pengine/pe_actions.c update_resource_flags_for_action(pcmk_resource_t *rsc, rsc 423 lib/pengine/pe_actions.c pcmk__set_rsc_flags(rsc, pcmk_rsc_stopping); rsc 427 lib/pengine/pe_actions.c pcmk__set_rsc_flags(rsc, pcmk_rsc_starting); rsc 429 lib/pengine/pe_actions.c pcmk__clear_rsc_flags(rsc, pcmk_rsc_starting); rsc 452 lib/pengine/pe_actions.c validate_on_fail(const pcmk_resource_t *rsc, const char *action_name, rsc 467 lib/pengine/pe_actions.c "allowed for stop", rsc->id, value); rsc 482 lib/pengine/pe_actions.c for (xmlNode *operation = pcmk__xe_first_child(rsc->ops_xml, PCMK_XE_OP, rsc 553 lib/pengine/pe_actions.c "allowed for it", rsc->id, name); rsc 646 lib/pengine/pe_actions.c most_frequent_monitor(const pcmk_resource_t *rsc) rsc 651 lib/pengine/pe_actions.c for (xmlNode *operation = pcmk__xe_first_child(rsc->ops_xml, PCMK_XE_OP, rsc 702 lib/pengine/pe_actions.c pcmk__unpack_action_meta(pcmk_resource_t *rsc, const pcmk_node_t *node, rsc 711 lib/pengine/pe_actions.c .standard = crm_element_value(rsc->xml, PCMK_XA_CLASS), rsc 712 lib/pengine/pe_actions.c .provider = crm_element_value(rsc->xml, PCMK_XA_PROVIDER), rsc 713 lib/pengine/pe_actions.c .agent = crm_element_value(rsc->xml, PCMK_XA_TYPE), rsc 729 lib/pengine/pe_actions.c .now = rsc->cluster->now, rsc 738 lib/pengine/pe_actions.c pe__unpack_dataset_nvpairs(rsc->cluster->op_defaults, rsc 740 lib/pengine/pe_actions.c FALSE, rsc->cluster); rsc 744 lib/pengine/pe_actions.c xmlNode *min_interval_mon = most_frequent_monitor(rsc); rsc 754 lib/pengine/pe_actions.c pcmk__rsc_trace(rsc, rsc 757 lib/pengine/pe_actions.c rsc->id, timeout_spec); rsc 766 lib/pengine/pe_actions.c &rule_data, meta, NULL, TRUE, rsc->cluster); rsc 805 lib/pengine/pe_actions.c GHashTable *params = pe_rsc_params(rsc, node, rsc->cluster); rsc 809 lib/pengine/pe_actions.c pcmk__rsc_trace(rsc, rsc 812 lib/pengine/pe_actions.c rsc->id, action_name, timeout_spec); rsc 823 lib/pengine/pe_actions.c validate_on_fail(rsc, action_name, action_config, meta); rsc 834 lib/pengine/pe_actions.c rsc->cluster->now, &start_delay)) { rsc 852 lib/pengine/pe_actions.c pcmk__action_requires(const pcmk_resource_t *rsc, const char *action_name) rsc 857 lib/pengine/pe_actions.c CRM_CHECK((rsc != NULL) && (action_name != NULL), return requires); rsc 863 lib/pengine/pe_actions.c } else if (pcmk_is_set(rsc->flags, pcmk_rsc_needs_fencing)) { rsc 867 lib/pengine/pe_actions.c } else if (pcmk_is_set(rsc->flags, pcmk_rsc_needs_quorum)) { rsc 874 lib/pengine/pe_actions.c pcmk__rsc_trace(rsc, "%s of %s requires %s", action_name, rsc->id, value); rsc 890 lib/pengine/pe_actions.c pcmk__parse_on_fail(const pcmk_resource_t *rsc, const char *action_name, rsc 898 lib/pengine/pe_actions.c pcmk__assert((rsc != NULL) && (action_name != NULL)); rsc 908 lib/pengine/pe_actions.c if (pcmk_is_set(rsc->cluster->flags, pcmk_sched_fencing_enabled)) { rsc 915 lib/pengine/pe_actions.c action_name, rsc->id); rsc 943 lib/pengine/pe_actions.c if (rsc->container == NULL) { rsc 944 lib/pengine/pe_actions.c pcmk__rsc_debug(rsc, rsc 947 lib/pengine/pe_actions.c action_name, rsc->id); rsc 960 lib/pengine/pe_actions.c action_name, rsc->id, value); rsc 968 lib/pengine/pe_actions.c if (rsc->is_remote_node rsc 969 lib/pengine/pe_actions.c && pcmk__is_remote_node(pcmk_find_node(rsc->cluster, rsc->id)) rsc 973 lib/pengine/pe_actions.c if (!pcmk_is_set(rsc->flags, pcmk_rsc_managed)) { rsc 981 lib/pengine/pe_actions.c } else if (rsc->container != NULL) { rsc 986 lib/pengine/pe_actions.c if (pcmk_is_set(rsc->flags, pcmk_rsc_managed)) { rsc 987 lib/pengine/pe_actions.c if (pcmk_is_set(rsc->cluster->flags, rsc 1000 lib/pengine/pe_actions.c if (pcmk_is_set(rsc->cluster->flags, pcmk_sched_fencing_enabled)) { rsc 1013 lib/pengine/pe_actions.c pcmk__rsc_trace(rsc, "Failure handling for %s-interval %s of %s: %s", rsc 1015 lib/pengine/pe_actions.c rsc->id, desc); rsc 1031 lib/pengine/pe_actions.c pcmk__role_after_failure(const pcmk_resource_t *rsc, const char *action_name, rsc 1044 lib/pengine/pe_actions.c if (rsc->remote_reconnect_ms != 0) { rsc 1077 lib/pengine/pe_actions.c pcmk__rsc_trace(rsc, "Role after %s %s failure is: %s", rsc 1078 lib/pengine/pe_actions.c rsc->id, action_name, pcmk_role_text(role)); rsc 1100 lib/pengine/pe_actions.c action->meta = pcmk__unpack_action_meta(action->rsc, action->node, rsc 1102 lib/pengine/pe_actions.c action->needs = pcmk__action_requires(action->rsc, action->task); rsc 1105 lib/pengine/pe_actions.c action->on_fail = pcmk__parse_on_fail(action->rsc, action->task, rsc 1108 lib/pengine/pe_actions.c action->fail_role = pcmk__role_after_failure(action->rsc, action->task, rsc 1129 lib/pengine/pe_actions.c custom_action(pcmk_resource_t *rsc, char *key, const char *task, rsc 1137 lib/pengine/pe_actions.c action = find_existing_action(key, rsc, on_node, scheduler); rsc 1139 lib/pengine/pe_actions.c action = new_action(key, task, rsc, on_node, optional, scheduler); rsc 1146 lib/pengine/pe_actions.c if (rsc != NULL) { rsc 1166 lib/pengine/pe_actions.c update_resource_flags_for_action(rsc, action); rsc 1418 lib/pengine/pe_actions.c get_complex_task(const pcmk_resource_t *rsc, const char *name) rsc 1422 lib/pengine/pe_actions.c if (pcmk__is_primitive(rsc)) { rsc 1429 lib/pengine/pe_actions.c name, rsc->id); rsc 1553 lib/pengine/pe_actions.c pe__resource_actions(const pcmk_resource_t *rsc, const pcmk_node_t *node, rsc 1557 lib/pengine/pe_actions.c char *key = pcmk__op_key(rsc->id, task, 0); rsc 1560 lib/pengine/pe_actions.c result = find_actions_exact(rsc->actions, key, node); rsc 1562 lib/pengine/pe_actions.c result = find_actions(rsc->actions, key, node); rsc 1599 lib/pengine/pe_actions.c (action->rsc == NULL)? "" : " ", rsc 1600 lib/pengine/pe_actions.c (action->rsc == NULL)? "" : action->rsc->id, rsc 1608 lib/pengine/pe_actions.c pcmk__rsc_trace(action->rsc, "Changing %s reason from '%s' to '%s'", rsc 1612 lib/pengine/pe_actions.c pcmk__rsc_trace(action->rsc, "Set %s reason to '%s'", rsc 1630 lib/pengine/pe_actions.c pe__clear_resource_history(pcmk_resource_t *rsc, const pcmk_node_t *node) rsc 1632 lib/pengine/pe_actions.c pcmk__assert((rsc != NULL) && (node != NULL)); rsc 1634 lib/pengine/pe_actions.c custom_action(rsc, pcmk__op_key(rsc->id, PCMK_ACTION_LRM_DELETE, 0), rsc 1635 lib/pengine/pe_actions.c PCMK_ACTION_LRM_DELETE, node, FALSE, rsc->cluster); rsc 1804 lib/pengine/pe_actions.c pe__new_rsc_pseudo_action(pcmk_resource_t *rsc, const char *task, bool optional, rsc 1809 lib/pengine/pe_actions.c pcmk__assert((rsc != NULL) && (task != NULL)); rsc 1811 lib/pengine/pe_actions.c action = custom_action(rsc, pcmk__op_key(rsc->id, task, 0), task, NULL, rsc 1812 lib/pengine/pe_actions.c optional, rsc->cluster); rsc 98 lib/pengine/pe_digest.c calculate_main_digest(pcmk__op_digest_t *data, pcmk_resource_t *rsc, rsc 111 lib/pengine/pe_digest.c (void) pe__add_bundle_remote_name(rsc, data->params_all, rsc 136 lib/pengine/pe_digest.c action_config = pcmk__find_action_config(rsc, task, *interval_ms, true); rsc 157 lib/pengine/pe_digest.c params = pcmk__unpack_action_meta(rsc, node, task, *interval_ms, rsc 187 lib/pengine/pe_digest.c calculate_secure_digest(pcmk__op_digest_t *data, const pcmk_resource_t *rsc, rsc 191 lib/pengine/pe_digest.c const char *class = crm_element_value(rsc->xml, PCMK_XA_CLASS); rsc 306 lib/pengine/pe_digest.c pe__calculate_digests(pcmk_resource_t *rsc, const char *task, rsc 338 lib/pengine/pe_digest.c params = pe_rsc_params(rsc, node, scheduler); rsc 339 lib/pengine/pe_digest.c calculate_main_digest(data, rsc, node, params, task, interval_ms, xml_op, rsc 342 lib/pengine/pe_digest.c calculate_secure_digest(data, rsc, params, xml_op, op_version, rsc 364 lib/pengine/pe_digest.c rsc_action_digest(pcmk_resource_t *rsc, const char *task, guint interval_ms, rsc 369 lib/pengine/pe_digest.c char *key = pcmk__op_key(rsc->id, task, interval_ms); rsc 373 lib/pengine/pe_digest.c data = pe__calculate_digests(rsc, task, &interval_ms, node, xml_op, rsc 394 lib/pengine/pe_digest.c rsc_action_digest_cmp(pcmk_resource_t *rsc, const xmlNode *xml_op, rsc 412 lib/pengine/pe_digest.c data = rsc_action_digest(rsc, task, interval_ms, node, xml_op, rsc 418 lib/pengine/pe_digest.c pcmk__rsc_info(rsc, rsc 421 lib/pengine/pe_digest.c interval_ms, task, rsc->id, pcmk__node_name(node), rsc 442 lib/pengine/pe_digest.c pcmk__rsc_info(rsc, rsc 446 lib/pengine/pe_digest.c interval_ms, task, rsc->id, pcmk__node_name(node), rsc 453 lib/pengine/pe_digest.c pcmk__rsc_info(rsc, rsc 456 lib/pengine/pe_digest.c interval_ms, task, rsc->id, pcmk__node_name(node), rsc 551 lib/pengine/pe_digest.c pe__compare_fencing_digest(pcmk_resource_t *rsc, const char *agent, rsc 557 lib/pengine/pe_digest.c pcmk__op_digest_t *data = rsc_action_digest(rsc, STONITH_DIGEST_TASK, 0U, rsc 569 lib/pengine/pe_digest.c if (unfencing_digest_matches(rsc->id, agent, data->digest_all_calc, rsc 578 lib/pengine/pe_digest.c if (unfencing_digest_matches(rsc->id, agent, data->digest_secure_calc, rsc 584 lib/pengine/pe_digest.c "for unfencing %s changed", rsc->id, rsc 597 lib/pengine/pe_digest.c char *digest = create_unfencing_summary(rsc->id, agent, rsc 601 lib/pengine/pe_digest.c "%s changed, try '%s'", rsc->id, rsc 605 lib/pengine/pe_digest.c char *digest = create_unfencing_summary(rsc->id, agent, rsc 609 lib/pengine/pe_digest.c rsc->id, pcmk__node_name(node), digest); rsc 19 lib/pengine/pe_notif.c const pcmk_resource_t *rsc; rsc 55 lib/pengine/pe_notif.c if ((entry_a->rsc == NULL) && (entry_b->rsc == NULL)) { rsc 58 lib/pengine/pe_notif.c if (entry_a->rsc == NULL) { rsc 61 lib/pengine/pe_notif.c if (entry_b->rsc == NULL) { rsc 66 lib/pengine/pe_notif.c tmp = strcmp(entry_a->rsc->id, entry_b->rsc->id); rsc 100 lib/pengine/pe_notif.c dup->rsc = entry->rsc; rsc 197 lib/pengine/pe_notif.c CRM_LOG_ASSERT((entry != NULL) && (entry->rsc != NULL) rsc 198 lib/pengine/pe_notif.c && (entry->rsc->id != NULL)); rsc 199 lib/pengine/pe_notif.c if ((entry == NULL) || (entry->rsc == NULL) rsc 200 lib/pengine/pe_notif.c || (entry->rsc->id == NULL)) { rsc 211 lib/pengine/pe_notif.c if (pcmk__str_eq(entry->rsc->id, last_rsc_id, pcmk__str_none)) { rsc 214 lib/pengine/pe_notif.c last_rsc_id = entry->rsc->id; rsc 217 lib/pengine/pe_notif.c pcmk__add_word(rsc_names, 1024, entry->rsc->id); rsc 281 lib/pengine/pe_notif.c new_notify_pseudo_action(pcmk_resource_t *rsc, const pcmk_action_t *action, rsc 286 lib/pengine/pe_notif.c notify = custom_action(rsc, rsc 287 lib/pengine/pe_notif.c pcmk__notify_key(rsc->id, notif_type, action->task), rsc 290 lib/pengine/pe_notif.c rsc->cluster); rsc 310 lib/pengine/pe_notif.c new_notify_action(pcmk_resource_t *rsc, const pcmk_node_t *node, rsc 320 lib/pengine/pe_notif.c CRM_CHECK((rsc != NULL) && (node != NULL), return NULL); rsc 333 lib/pengine/pe_notif.c pcmk__rsc_trace(rsc, "Skipping notify action for %s on %s: %s", rsc 334 lib/pengine/pe_notif.c rsc->id, pcmk__node_name(node), skip_reason); rsc 341 lib/pengine/pe_notif.c pcmk__rsc_trace(rsc, "Creating notify action for %s on %s (%s-%s)", rsc 342 lib/pengine/pe_notif.c rsc->id, pcmk__node_name(node), value, task); rsc 345 lib/pengine/pe_notif.c key = pcmk__notify_key(rsc->id, value, task); rsc 346 lib/pengine/pe_notif.c notify_action = custom_action(rsc, key, op->task, node, rsc 348 lib/pengine/pe_notif.c rsc->cluster); rsc 369 lib/pengine/pe_notif.c new_post_notify_action(pcmk_resource_t *rsc, const pcmk_node_t *node, rsc 377 lib/pengine/pe_notif.c notify = new_notify_action(rsc, node, n_data->post, n_data->post_done, rsc 387 lib/pengine/pe_notif.c for (GList *iter = rsc->actions; iter != NULL; iter = iter->next) { rsc 432 lib/pengine/pe_notif.c pe__action_notif_pseudo_ops(pcmk_resource_t *rsc, const char *task, rsc 437 lib/pengine/pe_notif.c if (!pcmk_is_set(rsc->flags, pcmk_rsc_notify)) { rsc 448 lib/pengine/pe_notif.c n_data->pre = new_notify_pseudo_action(rsc, action, PCMK_ACTION_NOTIFY, rsc 455 lib/pengine/pe_notif.c n_data->pre_done = new_notify_pseudo_action(rsc, action, rsc 470 lib/pengine/pe_notif.c n_data->post = new_notify_pseudo_action(rsc, complete, rsc 482 lib/pengine/pe_notif.c n_data->post_done = new_notify_pseudo_action(rsc, complete, rsc 519 lib/pengine/pe_notif.c new_notify_entry(const pcmk_resource_t *rsc, const pcmk_node_t *node) rsc 523 lib/pengine/pe_notif.c entry->rsc = rsc; rsc 537 lib/pengine/pe_notif.c collect_resource_data(const pcmk_resource_t *rsc, bool activity, rsc 549 lib/pengine/pe_notif.c n_data->allowed_nodes = rsc->allowed_nodes; rsc 553 lib/pengine/pe_notif.c if (rsc->children != NULL) { rsc 554 lib/pengine/pe_notif.c for (iter = rsc->children; iter != NULL; iter = iter->next) { rsc 564 lib/pengine/pe_notif.c if (rsc->running_on != NULL) { rsc 565 lib/pengine/pe_notif.c node = rsc->running_on->data; // First is sufficient rsc 567 lib/pengine/pe_notif.c entry = new_notify_entry(rsc, node); rsc 570 lib/pengine/pe_notif.c switch (rsc->role) { rsc 594 lib/pengine/pe_notif.c rsc->id, pcmk__node_name(node), rsc 595 lib/pengine/pe_notif.c pcmk_role_text(rsc->role)); rsc 605 lib/pengine/pe_notif.c for (iter = rsc->actions; iter != NULL; iter = iter->next) { rsc 618 lib/pengine/pe_notif.c entry = new_notify_entry(rsc, op->node); rsc 667 lib/pengine/pe_notif.c add_notif_keys(const pcmk_resource_t *rsc, notify_data_t *n_data) rsc 751 lib/pengine/pe_notif.c source = g_hash_table_lookup(rsc->meta, rsc 754 lib/pengine/pe_notif.c get_node_names(rsc->cluster->nodes, &node_list, &metal_list); rsc 757 lib/pengine/pe_notif.c get_node_names(rsc->cluster->nodes, &node_list, NULL); rsc 803 lib/pengine/pe_notif.c create_notify_actions(pcmk_resource_t *rsc, notify_data_t *n_data) rsc 811 lib/pengine/pe_notif.c if (rsc->children != NULL) { rsc 812 lib/pengine/pe_notif.c g_list_foreach(rsc->children, (GFunc) create_notify_actions, n_data); rsc 817 lib/pengine/pe_notif.c for (iter = rsc->actions; iter != NULL; iter = iter->next) { rsc 839 lib/pengine/pe_notif.c pcmk__rsc_trace(rsc, "No notify action needed for %s %s", rsc 840 lib/pengine/pe_notif.c rsc->id, n_data->action); rsc 847 lib/pengine/pe_notif.c pcmk__rsc_trace(rsc, "No notify action needed for %s %s", rsc 848 lib/pengine/pe_notif.c rsc->id, n_data->action); rsc 855 lib/pengine/pe_notif.c pcmk__rsc_trace(rsc, "No notify action needed for %s %s", rsc 856 lib/pengine/pe_notif.c rsc->id, n_data->action); rsc 866 lib/pengine/pe_notif.c pcmk__rsc_trace(rsc, "Creating notify actions for %s %s", rsc 867 lib/pengine/pe_notif.c rsc->id, n_data->action); rsc 870 lib/pengine/pe_notif.c if ((rsc->role != pcmk_role_stopped) rsc 873 lib/pengine/pe_notif.c stop = find_first_action(rsc->actions, NULL, PCMK_ACTION_STOP, NULL); rsc 875 lib/pengine/pe_notif.c for (iter = rsc->running_on; iter != NULL; iter = iter->next) { rsc 888 lib/pengine/pe_notif.c new_notify_action(rsc, current_node, n_data->pre, rsc 893 lib/pengine/pe_notif.c new_post_notify_action(rsc, current_node, n_data); rsc 899 lib/pengine/pe_notif.c if ((rsc->next_role != pcmk_role_stopped) rsc 902 lib/pengine/pe_notif.c start = find_first_action(rsc->actions, NULL, PCMK_ACTION_START, NULL); rsc 916 lib/pengine/pe_notif.c if (rsc->allocated_to == NULL) { rsc 918 lib/pengine/pe_notif.c pcmk_role_text(rsc->next_role), rsc->id); rsc 924 lib/pengine/pe_notif.c new_notify_action(rsc, rsc->allocated_to, n_data->pre, rsc 927 lib/pengine/pe_notif.c new_post_notify_action(rsc, rsc->allocated_to, n_data); rsc 939 lib/pengine/pe_notif.c pe__create_action_notifications(pcmk_resource_t *rsc, notify_data_t *n_data) rsc 941 lib/pengine/pe_notif.c if ((rsc == NULL) || (n_data == NULL)) { rsc 944 lib/pengine/pe_notif.c collect_resource_data(rsc, true, n_data); rsc 945 lib/pengine/pe_notif.c add_notif_keys(rsc, n_data); rsc 946 lib/pengine/pe_notif.c create_notify_actions(rsc, n_data); rsc 988 lib/pengine/pe_notif.c pe__order_notifs_after_fencing(const pcmk_action_t *stop, pcmk_resource_t *rsc, rsc 994 lib/pengine/pe_notif.c n_data = pe__action_notif_pseudo_ops(rsc, PCMK_ACTION_STOP, NULL, rsc 998 lib/pengine/pe_notif.c collect_resource_data(rsc, false, n_data); rsc 999 lib/pengine/pe_notif.c add_notify_env(n_data, "notify_stop_resource", rsc->id); rsc 1001 lib/pengine/pe_notif.c create_notify_actions(uber_parent(rsc), n_data); rsc 22 lib/pengine/pe_output.c pe__resource_description(const pcmk_resource_t *rsc, uint32_t show_opts) rsc 27 lib/pengine/pe_output.c desc = crm_element_value(rsc->xml, PCMK_XA_DESCRIPTION); rsc 70 lib/pengine/pe_output.c pcmk_resource_t *rsc = (pcmk_resource_t *) gIter->data; rsc 71 lib/pengine/pe_output.c const char *type = g_hash_table_lookup(rsc->meta, PCMK_XA_TYPE); rsc 75 lib/pengine/pe_output.c if (rsc->children != NULL) { rsc 76 lib/pengine/pe_output.c if (add_extra_info(node, rsc->children, scheduler, attrname, rsc 86 lib/pengine/pe_output.c params = pe_rsc_params(rsc, node, scheduler); rsc 310 lib/pengine/pe_output.c resource_history_string(pcmk_resource_t *rsc, const char *rsc_id, bool all, rsc 314 lib/pengine/pe_output.c if (rsc == NULL) { rsc 334 lib/pengine/pe_output.c rsc_id, rsc->migration_threshold, failcount_s, rsc 391 lib/pengine/pe_output.c formatted_xml_buf(const pcmk_resource_t *rsc, GString *xml_buf, bool raw) rsc 393 lib/pengine/pe_output.c if (raw && (rsc->orig_xml != NULL)) { rsc 394 lib/pengine/pe_output.c pcmk__xml_string(rsc->orig_xml, pcmk__xml_fmt_pretty, xml_buf, 0); rsc 396 lib/pengine/pe_output.c pcmk__xml_string(rsc->xml, pcmk__xml_fmt_pretty, xml_buf, 0); rsc 656 lib/pengine/pe_output.c location->id, location->rsc->id, rsc 676 lib/pengine/pe_output.c location->id, location->rsc->id, rsc 695 lib/pengine/pe_output.c PCMK_XA_RESOURCE, location->rsc->id, rsc 729 lib/pengine/pe_output.c const pcmk_resource_t *rsc = location->rsc; rsc 735 lib/pengine/pe_output.c if (!pcmk__str_in_list(rsc_printable_id(rsc), only_rsc, rsc 737 lib/pengine/pe_output.c && !pcmk__str_in_list(rsc_printable_id(pe__const_top_resource(rsc, false)), rsc 1674 lib/pengine/pe_output.c char *rsc = NULL; rsc 1686 lib/pengine/pe_output.c if (!parse_op_key(pcmk__xe_history_key(xml_op), &rsc, NULL, NULL)) { rsc 1690 lib/pengine/pe_output.c if (!pcmk__str_in_list(rsc, only_rsc, pcmk__str_star_matches)) { rsc 1691 lib/pengine/pe_output.c free(rsc); rsc 1695 lib/pengine/pe_output.c free(rsc); rsc 1824 lib/pengine/pe_output.c pcmk_resource_t *rsc = (pcmk_resource_t *) lpc2->data; rsc 1828 lib/pengine/pe_output.c out->message(out, pcmk__map_element_name(rsc->xml), show_opts, rsc 1829 lib/pengine/pe_output.c rsc, only_node, only_rsc); rsc 1966 lib/pengine/pe_output.c pcmk_resource_t *rsc = (pcmk_resource_t *) gIter2->data; rsc 1969 lib/pengine/pe_output.c out->message(out, pcmk__map_element_name(rsc->xml), rsc 1970 lib/pengine/pe_output.c show_opts, rsc, only_node, only_rsc); rsc 2098 lib/pengine/pe_output.c pcmk_resource_t *rsc = (pcmk_resource_t *) lpc->data; rsc 2101 lib/pengine/pe_output.c out->message(out, pcmk__map_element_name(rsc->xml), show_opts, rsc 2102 lib/pengine/pe_output.c rsc, only_node, only_rsc); rsc 2191 lib/pengine/pe_output.c pcmk_resource_t *rsc = NULL; rsc 2202 lib/pengine/pe_output.c rsc = pe_find_resource(scheduler->resources, op_rsc); rsc 2204 lib/pengine/pe_output.c if (rsc) { rsc 2205 lib/pengine/pe_output.c const pcmk_node_t *node = pcmk__current_node(rsc); rsc 2206 lib/pengine/pe_output.c const char *target_role = g_hash_table_lookup(rsc->meta, rsc 2211 lib/pengine/pe_output.c node = rsc->pending_node; rsc 2214 lib/pengine/pe_output.c node_str = pcmk__native_output_string(rsc, rsc_printable_id(rsc), node, rsc 2249 lib/pengine/pe_output.c pcmk_resource_t *rsc = NULL; rsc 2271 lib/pengine/pe_output.c rsc = pe_find_resource(scheduler->resources, op_rsc); rsc 2273 lib/pengine/pe_output.c if (rsc) { rsc 2274 lib/pengine/pe_output.c const char *class = crm_element_value(rsc->xml, PCMK_XA_CLASS); rsc 2275 lib/pengine/pe_output.c const char *provider = crm_element_value(rsc->xml, PCMK_XA_PROVIDER); rsc 2276 lib/pengine/pe_output.c const char *kind = crm_element_value(rsc->xml, PCMK_XA_TYPE); rsc 2286 lib/pengine/pe_output.c PCMK_XA_RSC, rsc_printable_id(rsc), rsc 2453 lib/pengine/pe_output.c pcmk_resource_t *rsc = NULL; rsc 2460 lib/pengine/pe_output.c rsc = pe_find_resource(scheduler->resources, rsc_id); rsc 2461 lib/pengine/pe_output.c if (rsc == NULL) { rsc 2473 lib/pengine/pe_output.c parent = pe__const_top_resource(rsc, false); rsc 2475 lib/pengine/pe_output.c if (!pcmk__str_in_list(rsc_printable_id(rsc), only_rsc, rsc 2482 lib/pengine/pe_output.c if (rsc->fns->is_filtered(rsc, only_rsc, TRUE)) { rsc 2489 lib/pengine/pe_output.c int failcount = pe_get_failcount(node, rsc, &last_failure, rsc 2502 lib/pengine/pe_output.c out->message(out, "resource-history", rsc, rsc_id, false, rsc 2506 lib/pengine/pe_output.c pcmk_resource_t *rsc = NULL; rsc 2512 lib/pengine/pe_output.c rsc = pe_find_resource(scheduler->resources, rsc 2521 lib/pengine/pe_output.c out->message(out, "resource-operation-list", scheduler, rsc, node, rsc 2743 lib/pengine/pe_output.c const pcmk_resource_t *rsc = va_arg(args, const pcmk_resource_t *); rsc 2748 lib/pengine/pe_output.c if (rsc) { rsc 2750 lib/pengine/pe_output.c prefix, rsc->id, uname, score); rsc 2763 lib/pengine/pe_output.c const pcmk_resource_t *rsc = va_arg(args, const pcmk_resource_t *); rsc 2774 lib/pengine/pe_output.c if (rsc) { rsc 2775 lib/pengine/pe_output.c crm_xml_add(node, PCMK_XA_ID, rsc->id); rsc 2898 lib/pengine/pe_output.c const pcmk_resource_t *rsc = va_arg(args, const pcmk_resource_t *); rsc 2902 lib/pengine/pe_output.c formatted_xml_buf(rsc, xml_buf, raw); rsc 2921 lib/pengine/pe_output.c pcmk_resource_t *rsc = va_arg(args, pcmk_resource_t *); rsc 2928 lib/pengine/pe_output.c char *buf = resource_history_string(rsc, rsc_id, all, failcount, last_failure); rsc 2944 lib/pengine/pe_output.c pcmk_resource_t *rsc = va_arg(args, pcmk_resource_t *); rsc 2956 lib/pengine/pe_output.c if (rsc == NULL) { rsc 2959 lib/pengine/pe_output.c char *migration_s = pcmk__itoa(rsc->migration_threshold); rsc 3043 lib/pengine/pe_output.c pcmk_resource_t *rsc = (pcmk_resource_t *) rsc_iter->data; rsc 3047 lib/pengine/pe_output.c gboolean is_active = rsc->fns->active(rsc, TRUE); rsc 3048 lib/pengine/pe_output.c gboolean partially_active = rsc->fns->active(rsc, FALSE); rsc 3051 lib/pengine/pe_output.c if (pcmk_is_set(rsc->flags, pcmk_rsc_removed) && !is_active) { rsc 3062 lib/pengine/pe_output.c && pcmk__is_primitive(rsc)) { rsc 3071 lib/pengine/pe_output.c } else if (partially_active && !pe__rsc_running_on_any(rsc, only_node)) { rsc 3082 lib/pengine/pe_output.c x = out->message(out, pcmk__map_element_name(rsc->xml), show_opts, rsc, rsc 3119 lib/pengine/pe_output.c pcmk_resource_t *rsc = va_arg(args, pcmk_resource_t *); rsc 3147 lib/pengine/pe_output.c int failcount = pe_get_failcount(node, rsc, &last_failure, rsc 3150 lib/pengine/pe_output.c out->message(out, "resource-history", rsc, rsc_printable_id(rsc), true, rsc 3172 lib/pengine/pe_output.c pcmk_resource_t *rsc = va_arg(args, pcmk_resource_t *); rsc 3177 lib/pengine/pe_output.c fn, rsc->id, pcmk__node_name(node)); rsc 3179 lib/pengine/pe_output.c g_hash_table_foreach(rsc->utilization, append_dump_text, &dump_text); rsc 3191 lib/pengine/pe_output.c pcmk_resource_t *rsc = va_arg(args, pcmk_resource_t *); rsc 3199 lib/pengine/pe_output.c PCMK_XA_RESOURCE, rsc->id, rsc 3203 lib/pengine/pe_output.c g_hash_table_foreach(rsc->utilization, add_dump_node, xml_node); rsc 68 lib/pengine/pe_status_private.h pcmk_resource_t *pe__create_clone_child(pcmk_resource_t *rsc, rsc 72 lib/pengine/pe_status_private.h void pe__create_action_notifications(pcmk_resource_t *rsc, rsc 79 lib/pengine/pe_status_private.h notify_data_t *pe__action_notif_pseudo_ops(pcmk_resource_t *rsc, rsc 85 lib/pengine/pe_status_private.h void pe__force_anon(const char *standard, pcmk_resource_t *rsc, const char *rid, rsc 92 lib/pengine/pe_status_private.h gboolean pe__unpack_resource(xmlNode *xml_obj, pcmk_resource_t **rsc, rsc 121 lib/pengine/pe_status_private.h pcmk__op_digest_t *pe__compare_fencing_digest(pcmk_resource_t *rsc, rsc 132 lib/pengine/pe_status_private.h unsigned int pe__primitive_max_per_node(const pcmk_resource_t *rsc); rsc 137 lib/pengine/pe_status_private.h unsigned int pe__group_max_per_node(const pcmk_resource_t *rsc); rsc 142 lib/pengine/pe_status_private.h unsigned int pe__clone_max_per_node(const pcmk_resource_t *rsc); rsc 147 lib/pengine/pe_status_private.h pcmk_node_t *pe__bundle_active_node(const pcmk_resource_t *rsc, rsc 152 lib/pengine/pe_status_private.h unsigned int pe__bundle_max_per_node(const pcmk_resource_t *rsc); rsc 30 lib/pengine/remote.c const pcmk_resource_t *rsc) rsc 32 lib/pengine/remote.c if ((rsc != NULL) && (scheduler != NULL) rsc 35 lib/pengine/remote.c for (GList *gIter = rsc->fillers; gIter != NULL; gIter = gIter->next) { rsc 95 lib/pengine/remote.c pcmk_resource_t *rsc = (pcmk_resource_t *) iter->data; rsc 97 lib/pengine/remote.c if (rsc->is_remote_node && (rsc->container != NULL)) { rsc 98 lib/pengine/remote.c pcmk_node_t *guest_node = pcmk_find_node(scheduler, rsc->id); rsc 183 lib/pengine/remote.c pcmk_resource_t *rsc; // Known resource corresponding to history entry rsc 189 lib/pengine/remote.c pe__add_param_check(const xmlNode *rsc_op, pcmk_resource_t *rsc, rsc 195 lib/pengine/remote.c CRM_CHECK(scheduler && rsc_op && rsc && node, return); rsc 202 lib/pengine/remote.c check_op->rsc = rsc; rsc 226 lib/pengine/remote.c cb(check_op->rsc, check_op->node, check_op->rsc_op, rsc 204 lib/pengine/status.c pcmk_resource_t *rsc = NULL; rsc 208 lib/pengine/status.c rsc = (pcmk_resource_t *) iterator->data; rsc 210 lib/pengine/status.c rsc->fns->free(rsc); rsc 38 lib/pengine/tags.c pcmk_resource_t *rsc = pe_find_resource_with_flags(scheduler->resources, rsc 41 lib/pengine/tags.c if (!rsc) { rsc 45 lib/pengine/tags.c retval = g_list_append(retval, strdup(rsc_printable_id(rsc))); rsc 59 lib/pengine/tests/native/native_find_rsc_test.c pcmk_resource_t *rsc = (pcmk_resource_t *) iter->data; rsc 61 lib/pengine/tests/native/native_find_rsc_test.c if (strcmp(rsc->id, "exim-group") == 0) { rsc 62 lib/pengine/tests/native/native_find_rsc_test.c exim_group = rsc; rsc 63 lib/pengine/tests/native/native_find_rsc_test.c } else if (strcmp(rsc->id, "httpd-bundle") == 0) { rsc 64 lib/pengine/tests/native/native_find_rsc_test.c httpd_bundle = rsc; rsc 65 lib/pengine/tests/native/native_find_rsc_test.c } else if (strcmp(rsc->id, "inactive-clone") == 0) { rsc 66 lib/pengine/tests/native/native_find_rsc_test.c inactive_clone = rsc; rsc 67 lib/pengine/tests/native/native_find_rsc_test.c } else if (strcmp(rsc->id, "inactive-group") == 0) { rsc 68 lib/pengine/tests/native/native_find_rsc_test.c inactive_group = rsc; rsc 69 lib/pengine/tests/native/native_find_rsc_test.c } else if (strcmp(rsc->id, "mysql-clone-group") == 0) { rsc 70 lib/pengine/tests/native/native_find_rsc_test.c mysql_clone_group = rsc; rsc 71 lib/pengine/tests/native/native_find_rsc_test.c } else if (strcmp(rsc->id, "promotable-clone") == 0) { rsc 72 lib/pengine/tests/native/native_find_rsc_test.c promotable_clone = rsc; rsc 88 lib/pengine/tests/native/native_find_rsc_test.c pcmk_resource_t *rsc = g_list_first(scheduler->resources)->data; rsc 89 lib/pengine/tests/native/native_find_rsc_test.c char *id = rsc->id; rsc 92 lib/pengine/tests/native/native_find_rsc_test.c assert_non_null(rsc); rsc 95 lib/pengine/tests/native/native_find_rsc_test.c assert_null(native_find_rsc(rsc, NULL, NULL, 0)); rsc 98 lib/pengine/tests/native/native_find_rsc_test.c name = crm_strdup_printf("%sX", rsc->id); rsc 99 lib/pengine/tests/native/native_find_rsc_test.c assert_null(native_find_rsc(rsc, name, NULL, 0)); rsc 102 lib/pengine/tests/native/native_find_rsc_test.c name = crm_strdup_printf("x%s", rsc->id); rsc 103 lib/pengine/tests/native/native_find_rsc_test.c assert_null(native_find_rsc(rsc, name, NULL, 0)); rsc 106 lib/pengine/tests/native/native_find_rsc_test.c name = g_ascii_strup(rsc->id, -1); rsc 107 lib/pengine/tests/native/native_find_rsc_test.c assert_null(native_find_rsc(rsc, name, NULL, 0)); rsc 111 lib/pengine/tests/native/native_find_rsc_test.c rsc->id = NULL; rsc 112 lib/pengine/tests/native/native_find_rsc_test.c assert_null(native_find_rsc(rsc, id, NULL, 0)); rsc 113 lib/pengine/tests/native/native_find_rsc_test.c rsc->id = id; rsc 122 lib/pengine/tests/native/native_find_rsc_test.c pcmk_resource_t *rsc = (pcmk_resource_t *) iter->data; rsc 124 lib/pengine/tests/native/native_find_rsc_test.c if (strcmp(rsc->id, "dummy") == 0) { rsc 125 lib/pengine/tests/native/native_find_rsc_test.c dummy = rsc; rsc 215 lib/pengine/tests/native/native_find_rsc_test.c pcmk_resource_t *rsc = (pcmk_resource_t *) iter->data; rsc 217 lib/pengine/tests/native/native_find_rsc_test.c if (strcmp(rsc->id, "Public-IP") == 0) { rsc 218 lib/pengine/tests/native/native_find_rsc_test.c public_ip = rsc; rsc 256 lib/pengine/tests/native/native_find_rsc_test.c pcmk_resource_t *rsc = (pcmk_resource_t *) iter->data; rsc 258 lib/pengine/tests/native/native_find_rsc_test.c if (strcmp(rsc->id, "inactive-dummy-1") == 0) { rsc 259 lib/pengine/tests/native/native_find_rsc_test.c inactive_dummy_1 = rsc; rsc 356 lib/pengine/tests/native/native_find_rsc_test.c pcmk_resource_t *rsc = (pcmk_resource_t *) iter->data; rsc 358 lib/pengine/tests/native/native_find_rsc_test.c if (strcmp(rsc->id, "promotable-rsc:0") == 0) { rsc 359 lib/pengine/tests/native/native_find_rsc_test.c promotable_0 = rsc; rsc 360 lib/pengine/tests/native/native_find_rsc_test.c } else if (strcmp(rsc->id, "promotable-rsc:1") == 0) { rsc 361 lib/pengine/tests/native/native_find_rsc_test.c promotable_1 = rsc; rsc 495 lib/pengine/tests/native/native_find_rsc_test.c pcmk_resource_t *rsc = (pcmk_resource_t *) iter->data; rsc 497 lib/pengine/tests/native/native_find_rsc_test.c if (strcmp(rsc->id, "promotable-rsc:0") == 0) { rsc 498 lib/pengine/tests/native/native_find_rsc_test.c promotable_0 = rsc; rsc 499 lib/pengine/tests/native/native_find_rsc_test.c } else if (strcmp(rsc->id, "promotable-rsc:1") == 0) { rsc 500 lib/pengine/tests/native/native_find_rsc_test.c promotable_1 = rsc; rsc 666 lib/pengine/tests/native/native_find_rsc_test.c clone_group_rsc(void **rsc) { rsc 708 lib/pengine/tests/native/native_find_rsc_test.c clone_group_instance_rsc(void **rsc) { rsc 714 lib/pengine/tests/native/native_find_rsc_test.c pcmk_resource_t *rsc = (pcmk_resource_t *) iter->data; rsc 716 lib/pengine/tests/native/native_find_rsc_test.c if (strcmp(rsc->id, "mysql-group:0") == 0) { rsc 717 lib/pengine/tests/native/native_find_rsc_test.c mysql_group_0 = rsc; rsc 718 lib/pengine/tests/native/native_find_rsc_test.c } else if (strcmp(rsc->id, "mysql-group:1") == 0) { rsc 719 lib/pengine/tests/native/native_find_rsc_test.c mysql_group_1 = rsc; rsc 852 lib/pengine/tests/native/native_find_rsc_test.c pcmk_resource_t *rsc = (pcmk_resource_t *) iter->data; rsc 854 lib/pengine/tests/native/native_find_rsc_test.c if (strcmp(rsc->id, "mysql-group:0") == 0) { rsc 855 lib/pengine/tests/native/native_find_rsc_test.c for (GList *iter2 = rsc->children; iter2 != NULL; iter2 = iter2->next) { rsc 53 lib/pengine/tests/native/pe_base_name_eq_test.c pcmk_resource_t *rsc = (pcmk_resource_t *) iter->data; rsc 55 lib/pengine/tests/native/pe_base_name_eq_test.c if (strcmp(rsc->id, "dummy") == 0) { rsc 56 lib/pengine/tests/native/pe_base_name_eq_test.c dummy = rsc; rsc 57 lib/pengine/tests/native/pe_base_name_eq_test.c } else if (strcmp(rsc->id, "exim-group") == 0) { rsc 58 lib/pengine/tests/native/pe_base_name_eq_test.c exim_group = rsc; rsc 59 lib/pengine/tests/native/pe_base_name_eq_test.c } else if (strcmp(rsc->id, "httpd-bundle") == 0) { rsc 60 lib/pengine/tests/native/pe_base_name_eq_test.c httpd_bundle = rsc; rsc 61 lib/pengine/tests/native/pe_base_name_eq_test.c } else if (strcmp(rsc->id, "mysql-clone-group") == 0) { rsc 62 lib/pengine/tests/native/pe_base_name_eq_test.c for (GList *iter = rsc->children; iter != NULL; iter = iter->next) { rsc 71 lib/pengine/tests/native/pe_base_name_eq_test.c } else if (strcmp(rsc->id, "promotable-clone") == 0) { rsc 72 lib/pengine/tests/native/pe_base_name_eq_test.c for (GList *iter = rsc->children; iter != NULL; iter = iter->next) { rsc 31 lib/pengine/unpack.c pcmk_resource_t *rsc; // Resource that history is for rsc 70 lib/pengine/unpack.c static void unpack_rsc_op(pcmk_resource_t *rsc, pcmk_node_t *node, rsc 119 lib/pengine/unpack.c pcmk_resource_t *rsc = node->details->remote_rsc->container; rsc 121 lib/pengine/unpack.c if (!pcmk_is_set(rsc->flags, pcmk_rsc_failed)) { rsc 122 lib/pengine/unpack.c if (!pcmk_is_set(rsc->flags, pcmk_rsc_managed)) { rsc 126 lib/pengine/unpack.c pcmk__node_name(node), reason, rsc->id); rsc 130 lib/pengine/unpack.c pcmk__node_name(node), rsc->id, reason); rsc 137 lib/pengine/unpack.c pcmk__set_rsc_flags(rsc, rsc 151 lib/pengine/unpack.c pcmk_resource_t *rsc = node->details->remote_rsc; rsc 153 lib/pengine/unpack.c if ((rsc != NULL) && !pcmk_is_set(rsc->flags, pcmk_rsc_managed)) { rsc 699 lib/pengine/unpack.c setup_container(pcmk_resource_t *rsc, pcmk_scheduler_t *scheduler) rsc 703 lib/pengine/unpack.c if (rsc->children) { rsc 704 lib/pengine/unpack.c g_list_foreach(rsc->children, (GFunc) setup_container, scheduler); rsc 708 lib/pengine/unpack.c container_id = g_hash_table_lookup(rsc->meta, PCMK__META_CONTAINER); rsc 709 lib/pengine/unpack.c if (container_id && !pcmk__str_eq(container_id, rsc->id, pcmk__str_casei)) { rsc 714 lib/pengine/unpack.c rsc->container = container; rsc 716 lib/pengine/unpack.c container->fillers = g_list_append(container->fillers, rsc); rsc 717 lib/pengine/unpack.c pcmk__rsc_trace(rsc, "Resource %s's container is %s", rsc 718 lib/pengine/unpack.c rsc->id, container_id); rsc 721 lib/pengine/unpack.c rsc->id, container_id); rsc 913 lib/pengine/unpack.c pcmk_resource_t *rsc = (pcmk_resource_t *) gIter->data; rsc 915 lib/pengine/unpack.c setup_container(rsc, scheduler); rsc 916 lib/pengine/unpack.c link_rsc2remotenode(scheduler, rsc); rsc 1118 lib/pengine/unpack.c pcmk_resource_t *rsc = NULL; rsc 1133 lib/pengine/unpack.c rsc = this_node->details->remote_rsc; rsc 1155 lib/pengine/unpack.c || ((rsc != NULL) && !pcmk_is_set(rsc->flags, pcmk_rsc_managed))) { rsc 1377 lib/pengine/unpack.c pcmk_resource_t *rsc = this_node->details->remote_rsc; rsc 1379 lib/pengine/unpack.c if ((rsc == NULL) || (rsc->role != pcmk_role_started) rsc 1380 lib/pengine/unpack.c || (rsc->container->role != pcmk_role_started)) { rsc 1393 lib/pengine/unpack.c pcmk_resource_t *rsc = this_node->details->remote_rsc; rsc 1395 lib/pengine/unpack.c if ((rsc == NULL) rsc 1397 lib/pengine/unpack.c && (rsc->role != pcmk_role_started))) { rsc 1802 lib/pengine/unpack.c pcmk_resource_t *rsc = this_node->details->remote_rsc; rsc 1810 lib/pengine/unpack.c if (rsc == NULL) { rsc 1815 lib/pengine/unpack.c container = rsc->container; rsc 1817 lib/pengine/unpack.c if (container && pcmk__list_of_1(rsc->running_on)) { rsc 1818 lib/pengine/unpack.c host = rsc->running_on->data; rsc 1822 lib/pengine/unpack.c if (rsc->role == pcmk_role_started) { rsc 1829 lib/pengine/unpack.c if ((rsc->role == pcmk_role_started) rsc 1830 lib/pengine/unpack.c && (rsc->next_role == pcmk_role_stopped)) { rsc 1844 lib/pengine/unpack.c } else if (pcmk_is_set(rsc->flags, pcmk_rsc_failed)) { rsc 1849 lib/pengine/unpack.c } else if ((rsc->role == pcmk_role_stopped) rsc 2028 lib/pengine/unpack.c pcmk_resource_t *rsc = NULL; rsc 2035 lib/pengine/unpack.c if (pe__unpack_resource(xml_rsc, &rsc, NULL, scheduler) != pcmk_rc_ok) { rsc 2048 lib/pengine/unpack.c link_rsc2remotenode(scheduler, rsc); rsc 2059 lib/pengine/unpack.c pcmk__set_rsc_flags(rsc, pcmk_rsc_removed_filler); rsc 2061 lib/pengine/unpack.c pcmk__set_rsc_flags(rsc, pcmk_rsc_removed); rsc 2062 lib/pengine/unpack.c scheduler->resources = g_list_append(scheduler->resources, rsc); rsc 2063 lib/pengine/unpack.c return rsc; rsc 2112 lib/pengine/unpack.c pcmk_resource_t *rsc = NULL; rsc 2121 lib/pengine/unpack.c for (rIter = parent->children; rsc == NULL && rIter; rIter = rIter->next) { rsc 2156 lib/pengine/unpack.c rsc = parent->fns->find_rsc(child, rsc_id, NULL, rsc 2158 lib/pengine/unpack.c if (rsc) { rsc 2166 lib/pengine/unpack.c if (rsc->running_on) { rsc 2171 lib/pengine/unpack.c rsc = NULL; rsc 2173 lib/pengine/unpack.c pcmk__rsc_trace(parent, "Resource %s, active", rsc->id); rsc 2199 lib/pengine/unpack.c if ((rsc == NULL) && !skip_inactive && (inactive_instance != NULL)) { rsc 2202 lib/pengine/unpack.c rsc = inactive_instance; rsc 2218 lib/pengine/unpack.c if ((rsc != NULL) && !pcmk_is_set(rsc->flags, pcmk_rsc_needs_fencing) rsc 2223 lib/pengine/unpack.c rsc = NULL; rsc 2226 lib/pengine/unpack.c if (rsc == NULL) { rsc 2227 lib/pengine/unpack.c rsc = create_anonymous_orphan(parent, rsc_id, node, scheduler); rsc 2228 lib/pengine/unpack.c pcmk__rsc_trace(parent, "Resource %s, orphan", rsc->id); rsc 2230 lib/pengine/unpack.c return rsc; rsc 2237 lib/pengine/unpack.c pcmk_resource_t *rsc = NULL; rsc 2241 lib/pengine/unpack.c rsc = pe_find_resource(scheduler->resources, rsc_id); rsc 2243 lib/pengine/unpack.c if (rsc == NULL) { rsc 2253 lib/pengine/unpack.c rsc = clone0; rsc 2262 lib/pengine/unpack.c } else if (rsc->variant > pcmk_rsc_variant_primitive) { rsc 2268 lib/pengine/unpack.c parent = uber_parent(rsc); rsc 2274 lib/pengine/unpack.c rsc = pe__find_bundle_replica(parent->parent, node); rsc 2278 lib/pengine/unpack.c rsc = find_anonymous_clone(scheduler, node, parent, base); rsc 2280 lib/pengine/unpack.c pcmk__assert(rsc != NULL); rsc 2284 lib/pengine/unpack.c if (rsc && !pcmk__str_eq(rsc_id, rsc->id, pcmk__str_none) rsc 2285 lib/pengine/unpack.c && !pcmk__str_eq(rsc_id, rsc->clone_name, pcmk__str_none)) { rsc 2287 lib/pengine/unpack.c pcmk__str_update(&rsc->clone_name, rsc_id); rsc 2288 lib/pengine/unpack.c pcmk__rsc_debug(rsc, "Internally renamed %s on %s to %s%s", rsc 2289 lib/pengine/unpack.c rsc_id, pcmk__node_name(node), rsc->id, rsc 2290 lib/pengine/unpack.c pcmk_is_set(rsc->flags, pcmk_rsc_removed)? " (ORPHAN)" : ""); rsc 2292 lib/pengine/unpack.c return rsc; rsc 2299 lib/pengine/unpack.c pcmk_resource_t *rsc = NULL; rsc 2304 lib/pengine/unpack.c rsc = create_fake_resource(rsc_id, rsc_entry, scheduler); rsc 2305 lib/pengine/unpack.c if (rsc == NULL) { rsc 2310 lib/pengine/unpack.c pcmk__clear_rsc_flags(rsc, pcmk_rsc_managed); rsc 2313 lib/pengine/unpack.c CRM_CHECK(rsc != NULL, return NULL); rsc 2314 lib/pengine/unpack.c pcmk__rsc_trace(rsc, "Added orphan %s", rsc->id); rsc 2315 lib/pengine/unpack.c resource_location(rsc, NULL, -PCMK_SCORE_INFINITY, rsc 2318 lib/pengine/unpack.c return rsc; rsc 2322 lib/pengine/unpack.c process_rsc_state(pcmk_resource_t *rsc, pcmk_node_t *node, rsc 2329 lib/pengine/unpack.c pcmk__assert(rsc); rsc 2330 lib/pengine/unpack.c pcmk__rsc_trace(rsc, "Resource %s is %s on %s: on_fail=%s", rsc 2331 lib/pengine/unpack.c rsc->id, pcmk_role_text(rsc->role), pcmk__node_name(node), rsc 2335 lib/pengine/unpack.c if (rsc->role != pcmk_role_unknown) { rsc 2336 lib/pengine/unpack.c pcmk_resource_t *iter = rsc; rsc 2342 lib/pengine/unpack.c pcmk__rsc_trace(rsc, "%s%s%s known on %s", rsc 2343 lib/pengine/unpack.c rsc->id, rsc 2344 lib/pengine/unpack.c ((rsc->clone_name == NULL)? "" : " also known as "), rsc 2345 lib/pengine/unpack.c ((rsc->clone_name == NULL)? "" : rsc->clone_name), rsc 2357 lib/pengine/unpack.c if ((rsc->role > pcmk_role_stopped) rsc 2360 lib/pengine/unpack.c && pcmk_is_set(rsc->flags, pcmk_rsc_managed)) { rsc 2372 lib/pengine/unpack.c pcmk__set_rsc_flags(rsc, pcmk_rsc_failed|pcmk_rsc_stop_if_failed); rsc 2375 lib/pengine/unpack.c } else if (pcmk_is_set(rsc->cluster->flags, rsc 2392 lib/pengine/unpack.c rsc->id); rsc 2399 lib/pengine/unpack.c reason = crm_strdup_printf("%s is thought to be active there", rsc->id); rsc 2401 lib/pengine/unpack.c pe_fence_node(rsc->cluster, node, reason, FALSE); rsc 2422 lib/pengine/unpack.c pcmk__set_rsc_flags(rsc, pcmk_rsc_failed); rsc 2423 lib/pengine/unpack.c demote_action(rsc, node, FALSE); rsc 2430 lib/pengine/unpack.c reason = crm_strdup_printf("%s failed there", rsc->id); rsc 2431 lib/pengine/unpack.c pe_fence_node(rsc->cluster, node, reason, FALSE); rsc 2444 lib/pengine/unpack.c pcmk__clear_rsc_flags(rsc, pcmk_rsc_managed); rsc 2445 lib/pengine/unpack.c pcmk__set_rsc_flags(rsc, pcmk_rsc_blocked); rsc 2452 lib/pengine/unpack.c resource_location(rsc, node, -PCMK_SCORE_INFINITY, rsc 2453 lib/pengine/unpack.c "__action_migration_auto__", rsc->cluster); rsc 2457 lib/pengine/unpack.c pe__set_next_role(rsc, pcmk_role_stopped, rsc 2462 lib/pengine/unpack.c if ((rsc->role != pcmk_role_stopped) rsc 2463 lib/pengine/unpack.c && (rsc->role != pcmk_role_unknown)) { rsc 2464 lib/pengine/unpack.c pcmk__set_rsc_flags(rsc, rsc 2466 lib/pengine/unpack.c stop_action(rsc, node, FALSE); rsc 2471 lib/pengine/unpack.c pcmk__set_rsc_flags(rsc, pcmk_rsc_failed|pcmk_rsc_stop_if_failed); rsc 2472 lib/pengine/unpack.c if ((rsc->container != NULL) && pcmk__is_bundled(rsc)) { rsc 2478 lib/pengine/unpack.c rsc->cluster->stop_needed = rsc 2479 lib/pengine/unpack.c g_list_prepend(rsc->cluster->stop_needed, rsc->container); rsc 2480 lib/pengine/unpack.c } else if (rsc->container) { rsc 2481 lib/pengine/unpack.c stop_action(rsc->container, node, FALSE); rsc 2482 lib/pengine/unpack.c } else if ((rsc->role != pcmk_role_stopped) rsc 2483 lib/pengine/unpack.c && (rsc->role != pcmk_role_unknown)) { rsc 2484 lib/pengine/unpack.c stop_action(rsc, node, FALSE); rsc 2489 lib/pengine/unpack.c pcmk__set_rsc_flags(rsc, pcmk_rsc_failed|pcmk_rsc_stop_if_failed); rsc 2490 lib/pengine/unpack.c if (pcmk_is_set(rsc->cluster->flags, pcmk_sched_fencing_enabled)) { rsc 2492 lib/pengine/unpack.c if (rsc->is_remote_node) { rsc 2493 lib/pengine/unpack.c tmpnode = pcmk_find_node(rsc->cluster, rsc->id); rsc 2500 lib/pengine/unpack.c pe_fence_node(rsc->cluster, tmpnode, rsc 2506 lib/pengine/unpack.c if (rsc->role > pcmk_role_stopped) { rsc 2507 lib/pengine/unpack.c stop_action(rsc, node, FALSE); rsc 2512 lib/pengine/unpack.c if (rsc->remote_reconnect_ms) { rsc 2513 lib/pengine/unpack.c pe__set_next_role(rsc, pcmk_role_stopped, "remote reset"); rsc 2522 lib/pengine/unpack.c if (pcmk_is_set(rsc->flags, pcmk_rsc_failed) && rsc->is_remote_node) { rsc 2523 lib/pengine/unpack.c tmpnode = pcmk_find_node(rsc->cluster, rsc->id); rsc 2529 lib/pengine/unpack.c if ((rsc->role != pcmk_role_stopped) rsc 2530 lib/pengine/unpack.c && (rsc->role != pcmk_role_unknown)) { rsc 2531 lib/pengine/unpack.c if (pcmk_is_set(rsc->flags, pcmk_rsc_removed)) { rsc 2532 lib/pengine/unpack.c if (pcmk_is_set(rsc->flags, pcmk_rsc_managed)) { rsc 2535 lib/pengine/unpack.c rsc->id, pcmk__node_name(node)); rsc 2539 lib/pengine/unpack.c " is set to false", rsc->id, pcmk__node_name(node)); rsc 2543 lib/pengine/unpack.c native_add_running(rsc, node, rsc->cluster, rsc 2550 lib/pengine/unpack.c pcmk__set_rsc_flags(rsc, pcmk_rsc_failed); rsc 2553 lib/pengine/unpack.c pcmk__set_rsc_flags(rsc, rsc 2558 lib/pengine/unpack.c } else if (rsc->clone_name && strchr(rsc->clone_name, ':') != NULL) { rsc 2562 lib/pengine/unpack.c pcmk__rsc_trace(rsc, "Resetting clone_name %s for %s (stopped)", rsc 2563 lib/pengine/unpack.c rsc->clone_name, rsc->id); rsc 2564 lib/pengine/unpack.c free(rsc->clone_name); rsc 2565 lib/pengine/unpack.c rsc->clone_name = NULL; rsc 2568 lib/pengine/unpack.c GList *possible_matches = pe__resource_actions(rsc, node, rsc 2584 lib/pengine/unpack.c if ((rsc->role == pcmk_role_stopped) rsc 2585 lib/pengine/unpack.c && rsc->partial_migration_source rsc 2586 lib/pengine/unpack.c && rsc->partial_migration_source->details == node->details rsc 2587 lib/pengine/unpack.c && rsc->partial_migration_target rsc 2588 lib/pengine/unpack.c && rsc->running_on) { rsc 2590 lib/pengine/unpack.c rsc->role = pcmk_role_started; rsc 2596 lib/pengine/unpack.c process_recurring(pcmk_node_t *node, pcmk_resource_t *rsc, rsc 2605 lib/pengine/unpack.c pcmk__assert(rsc != NULL); rsc 2606 lib/pengine/unpack.c pcmk__rsc_trace(rsc, "%s: Start index %d, stop index = %d", rsc 2607 lib/pengine/unpack.c rsc->id, start_index, stop_index); rsc 2619 lib/pengine/unpack.c pcmk__rsc_trace(rsc, "Skipping %s on %s: node is offline", rsc 2620 lib/pengine/unpack.c rsc->id, pcmk__node_name(node)); rsc 2625 lib/pengine/unpack.c pcmk__rsc_trace(rsc, "Skipping %s on %s: resource is not active", rsc 2630 lib/pengine/unpack.c pcmk__rsc_trace(rsc, "Skipping %s on %s: old %d", rsc 2637 lib/pengine/unpack.c pcmk__rsc_trace(rsc, "Skipping %s on %s: non-recurring", rsc 2644 lib/pengine/unpack.c pcmk__rsc_trace(rsc, "Skipping %s on %s: status", rsc 2650 lib/pengine/unpack.c key = pcmk__op_key(rsc->id, task, interval_ms); rsc 2651 lib/pengine/unpack.c pcmk__rsc_trace(rsc, "Creating %s on %s", key, pcmk__node_name(node)); rsc 2652 lib/pengine/unpack.c custom_action(rsc, key, task, node, TRUE, scheduler); rsc 2710 lib/pengine/unpack.c unpack_shutdown_lock(const xmlNode *rsc_entry, pcmk_resource_t *rsc, rsc 2721 lib/pengine/unpack.c pcmk__rsc_info(rsc, "Shutdown lock for %s on %s expired", rsc 2722 lib/pengine/unpack.c rsc->id, pcmk__node_name(node)); rsc 2723 lib/pengine/unpack.c pe__clear_resource_history(rsc, node); rsc 2729 lib/pengine/unpack.c rsc->lock_node = (pcmk_node_t *) node; rsc 2730 lib/pengine/unpack.c rsc->lock_time = lock_time; rsc 2756 lib/pengine/unpack.c pcmk_resource_t *rsc = NULL; rsc 2793 lib/pengine/unpack.c rsc = unpack_find_resource(scheduler, node, rsc_id); rsc 2794 lib/pengine/unpack.c if (rsc == NULL) { rsc 2799 lib/pengine/unpack.c rsc = process_orphan_resource(lrm_resource, node, scheduler); rsc 2802 lib/pengine/unpack.c pcmk__assert(rsc != NULL); rsc 2806 lib/pengine/unpack.c unpack_shutdown_lock(lrm_resource, rsc, node, scheduler); rsc 2810 lib/pengine/unpack.c saved_role = rsc->role; rsc 2811 lib/pengine/unpack.c rsc->role = pcmk_role_unknown; rsc 2817 lib/pengine/unpack.c unpack_rsc_op(rsc, node, rsc_op, &last_failure, &on_fail); rsc 2822 lib/pengine/unpack.c process_recurring(node, rsc, start_index, stop_index, sorted_op_list, rsc 2828 lib/pengine/unpack.c process_rsc_state(rsc, node, on_fail); rsc 2830 lib/pengine/unpack.c if (get_target_role(rsc, &req_role)) { rsc 2831 lib/pengine/unpack.c if ((rsc->next_role == pcmk_role_unknown) rsc 2832 lib/pengine/unpack.c || (req_role < rsc->next_role)) { rsc 2834 lib/pengine/unpack.c pe__set_next_role(rsc, req_role, PCMK_META_TARGET_ROLE); rsc 2836 lib/pengine/unpack.c } else if (req_role > rsc->next_role) { rsc 2837 lib/pengine/unpack.c pcmk__rsc_info(rsc, rsc 2840 lib/pengine/unpack.c rsc->id, pcmk_role_text(rsc->next_role), rsc 2845 lib/pengine/unpack.c if (saved_role > rsc->role) { rsc 2846 lib/pengine/unpack.c rsc->role = saved_role; rsc 2849 lib/pengine/unpack.c return rsc; rsc 2860 lib/pengine/unpack.c pcmk_resource_t *rsc; rsc 2880 lib/pengine/unpack.c rsc = pe_find_resource(scheduler->resources, rsc_id); rsc 2881 lib/pengine/unpack.c if ((rsc == NULL) || (rsc->container != NULL) rsc 2882 lib/pengine/unpack.c || !pcmk_is_set(rsc->flags, pcmk_rsc_removed_filler)) { rsc 2886 lib/pengine/unpack.c pcmk__rsc_trace(rsc, "Mapped container of orphaned resource %s to %s", rsc 2887 lib/pengine/unpack.c rsc->id, container_id); rsc 2888 lib/pengine/unpack.c rsc->container = container; rsc 2889 lib/pengine/unpack.c container->fillers = g_list_append(container->fillers, rsc); rsc 2923 lib/pengine/unpack.c pcmk_resource_t *rsc = unpack_lrm_resource(node, rsc_entry, scheduler); rsc 2925 lib/pengine/unpack.c if ((rsc != NULL) rsc 2926 lib/pengine/unpack.c && pcmk_is_set(rsc->flags, pcmk_rsc_removed_filler)) { rsc 2940 lib/pengine/unpack.c set_active(pcmk_resource_t *rsc) rsc 2942 lib/pengine/unpack.c const pcmk_resource_t *top = pe__const_top_resource(rsc, false); rsc 2945 lib/pengine/unpack.c rsc->role = pcmk_role_unpromoted; rsc 2947 lib/pengine/unpack.c rsc->role = pcmk_role_started; rsc 3048 lib/pengine/unpack.c unknown_on_node(pcmk_resource_t *rsc, const char *node_name) rsc 3058 lib/pengine/unpack.c node_name, rsc->id, PCMK_OCF_UNKNOWN); rsc 3060 lib/pengine/unpack.c search = xpath_search(rsc->cluster->input, xpath); rsc 3263 lib/pengine/unpack.c add_dangling_migration(pcmk_resource_t *rsc, const pcmk_node_t *node) rsc 3265 lib/pengine/unpack.c pcmk__rsc_trace(rsc, "Dangling migration of %s requires stop on %s", rsc 3266 lib/pengine/unpack.c rsc->id, pcmk__node_name(node)); rsc 3267 lib/pengine/unpack.c rsc->role = pcmk_role_stopped; rsc 3268 lib/pengine/unpack.c rsc->dangling_migrations = g_list_prepend(rsc->dangling_migrations, rsc 3329 lib/pengine/unpack.c source_newer_op = non_monitor_after(history->rsc->id, source, history->xml, rsc 3330 lib/pengine/unpack.c true, history->rsc->cluster); rsc 3333 lib/pengine/unpack.c migrate_from = find_lrm_op(history->rsc->id, PCMK_ACTION_MIGRATE_FROM, rsc 3334 lib/pengine/unpack.c target, source, -1, history->rsc->cluster); rsc 3350 lib/pengine/unpack.c target_newer_state = newer_state_after_migrate(history->rsc->id, target, rsc 3352 lib/pengine/unpack.c history->rsc->cluster); rsc 3362 lib/pengine/unpack.c add_dangling_migration(history->rsc, history->node); rsc 3369 lib/pengine/unpack.c history->rsc->role = pcmk_role_started; rsc 3371 lib/pengine/unpack.c target_node = pcmk_find_node(history->rsc->cluster, target); rsc 3377 lib/pengine/unpack.c native_add_running(history->rsc, target_node, history->rsc->cluster, rsc 3381 lib/pengine/unpack.c pcmk__set_rsc_flags(history->rsc, rsc 3383 lib/pengine/unpack.c pcmk__clear_rsc_flags(history->rsc, pcmk_rsc_migratable); rsc 3395 lib/pengine/unpack.c && unknown_on_node(history->rsc, target)) { rsc 3400 lib/pengine/unpack.c pcmk_node_t *source_node = pcmk_find_node(history->rsc->cluster, rsc 3403 lib/pengine/unpack.c native_add_running(history->rsc, target_node, history->rsc->cluster, rsc 3412 lib/pengine/unpack.c history->rsc->partial_migration_target = target_node; rsc 3413 lib/pengine/unpack.c history->rsc->partial_migration_source = source_node; rsc 3418 lib/pengine/unpack.c pcmk__set_rsc_flags(history->rsc, rsc 3420 lib/pengine/unpack.c pcmk__clear_rsc_flags(history->rsc, pcmk_rsc_migratable); rsc 3446 lib/pengine/unpack.c history->rsc->role = pcmk_role_started; rsc 3449 lib/pengine/unpack.c target_migrate_from = find_lrm_op(history->rsc->id, rsc 3451 lib/pengine/unpack.c PCMK_OCF_OK, history->rsc->cluster); rsc 3458 lib/pengine/unpack.c !unknown_on_node(history->rsc, target) rsc 3462 lib/pengine/unpack.c && !newer_state_after_migrate(history->rsc->id, target, history->xml, rsc 3464 lib/pengine/unpack.c history->rsc->cluster)) { rsc 3469 lib/pengine/unpack.c pcmk_node_t *target_node = pcmk_find_node(history->rsc->cluster, rsc 3473 lib/pengine/unpack.c native_add_running(history->rsc, target_node, history->rsc->cluster, rsc 3477 lib/pengine/unpack.c } else if (!non_monitor_after(history->rsc->id, source, history->xml, true, rsc 3478 lib/pengine/unpack.c history->rsc->cluster)) { rsc 3485 lib/pengine/unpack.c history->rsc->dangling_migrations = rsc 3486 lib/pengine/unpack.c g_list_prepend(history->rsc->dangling_migrations, rsc 3513 lib/pengine/unpack.c history->rsc->role = pcmk_role_started; rsc 3516 lib/pengine/unpack.c source_migrate_to = find_lrm_op(history->rsc->id, PCMK_ACTION_MIGRATE_TO, rsc 3518 lib/pengine/unpack.c history->rsc->cluster); rsc 3525 lib/pengine/unpack.c !unknown_on_node(history->rsc, source) rsc 3529 lib/pengine/unpack.c && !newer_state_after_migrate(history->rsc->id, source, rsc 3531 lib/pengine/unpack.c history->rsc->cluster)) { rsc 3535 lib/pengine/unpack.c pcmk_node_t *source_node = pcmk_find_node(history->rsc->cluster, rsc 3539 lib/pengine/unpack.c native_add_running(history->rsc, source_node, history->rsc->cluster, rsc 3558 lib/pengine/unpack.c for (const xmlNode *xIter = history->rsc->cluster->failed->children; rsc 3576 lib/pengine/unpack.c crm_xml_add(history->xml, PCMK__XA_RSC_ID, history->rsc->id); rsc 3577 lib/pengine/unpack.c pcmk__xml_copy(history->rsc->cluster->failed, history->xml); rsc 3702 lib/pengine/unpack.c ban_from_all_nodes(pcmk_resource_t *rsc) rsc 3705 lib/pengine/unpack.c pcmk_resource_t *fail_rsc = rsc; rsc 3724 lib/pengine/unpack.c fail_rsc->allowed_nodes = pe__node_list2table(rsc->cluster->nodes); rsc 3741 lib/pengine/unpack.c xmlNode *config = pcmk__find_action_config(history->rsc, history->task, rsc 3744 lib/pengine/unpack.c GHashTable *meta = pcmk__unpack_action_meta(history->rsc, history->node, rsc 3750 lib/pengine/unpack.c *on_fail = pcmk__parse_on_fail(history->rsc, history->task, rsc 3752 lib/pengine/unpack.c *fail_role = pcmk__role_after_failure(history->rsc, history->task, *on_fail, rsc 3781 lib/pengine/unpack.c if (!pcmk_is_set(history->rsc->cluster->flags, pcmk_sched_symmetric_cluster) rsc 3788 lib/pengine/unpack.c (is_probe? "probe" : history->task), history->rsc->id, rsc 3797 lib/pengine/unpack.c (is_probe? "probe" : history->task), history->rsc->id, rsc 3811 lib/pengine/unpack.c history->rsc->id, pcmk__node_name(history->node)); rsc 3820 lib/pengine/unpack.c pcmk__rsc_trace(history->rsc, "on-fail %s -> %s for %s", rsc 3827 lib/pengine/unpack.c resource_location(history->rsc, history->node, -PCMK_SCORE_INFINITY, rsc 3828 lib/pengine/unpack.c "__stop_fail__", history->rsc->cluster); rsc 3837 lib/pengine/unpack.c history->rsc->role = pcmk_role_promoted; rsc 3841 lib/pengine/unpack.c history->rsc->role = pcmk_role_promoted; rsc 3842 lib/pengine/unpack.c pe__set_next_role(history->rsc, pcmk_role_stopped, rsc 3846 lib/pengine/unpack.c history->rsc->role = pcmk_role_stopped; rsc 3854 lib/pengine/unpack.c history->rsc->role = pcmk_role_unpromoted; rsc 3860 lib/pengine/unpack.c pcmk__rsc_trace(history->rsc, "Leaving %s stopped", history->rsc->id); rsc 3861 lib/pengine/unpack.c history->rsc->role = pcmk_role_stopped; rsc 3863 lib/pengine/unpack.c } else if (history->rsc->role < pcmk_role_started) { rsc 3864 lib/pengine/unpack.c pcmk__rsc_trace(history->rsc, "Setting %s active", history->rsc->id); rsc 3865 lib/pengine/unpack.c set_active(history->rsc); rsc 3868 lib/pengine/unpack.c pcmk__rsc_trace(history->rsc, rsc 3870 lib/pengine/unpack.c history->rsc->id, pcmk_role_text(history->rsc->role), rsc 3876 lib/pengine/unpack.c && (history->rsc->next_role < fail_role)) { rsc 3877 lib/pengine/unpack.c pe__set_next_role(history->rsc, fail_role, "failure"); rsc 3881 lib/pengine/unpack.c ban_from_all_nodes(history->rsc); rsc 3910 lib/pengine/unpack.c history->rsc->id, history->task, rsc 3919 lib/pengine/unpack.c pcmk__clear_rsc_flags(history->rsc, pcmk_rsc_managed); rsc 3920 lib/pengine/unpack.c pcmk__set_rsc_flags(history->rsc, pcmk_rsc_blocked); rsc 3984 lib/pengine/unpack.c if (!pcmk__is_bundled(history->rsc) rsc 4039 lib/pengine/unpack.c pcmk__rsc_debug(history->rsc, rsc 4057 lib/pengine/unpack.c pcmk__rsc_info(history->rsc, rsc 4059 lib/pengine/unpack.c history->rsc->id, pcmk__node_name(history->node), rsc 4068 lib/pengine/unpack.c || !pcmk_is_set(history->rsc->flags, pcmk_rsc_managed)) { rsc 4075 lib/pengine/unpack.c history->rsc->role = pcmk_role_stopped; rsc 4077 lib/pengine/unpack.c pe__set_next_role(history->rsc, pcmk_role_unknown, rsc 4088 lib/pengine/unpack.c pcmk__rsc_info(history->rsc, rsc 4090 lib/pengine/unpack.c history->rsc->id, rsc 4096 lib/pengine/unpack.c history->rsc->role = pcmk_role_promoted; rsc 4102 lib/pengine/unpack.c history->rsc->role = pcmk_role_promoted; rsc 4145 lib/pengine/unpack.c history->exit_status, task, history->rsc->id, rsc 4156 lib/pengine/unpack.c pcmk__rsc_trace(history->rsc, rsc 4169 lib/pengine/unpack.c pcmk_resource_t *rsc, pcmk_node_t *node) rsc 4172 lib/pengine/unpack.c if (pe__bundle_needs_remote_name(rsc)) { rsc 4177 lib/pengine/unpack.c pe__add_param_check(xml_op, rsc, node, pcmk__check_last_failure, rsc 4178 lib/pengine/unpack.c rsc->cluster); rsc 4183 lib/pengine/unpack.c digest_data = rsc_action_digest_cmp(rsc, xml_op, node, rsc 4184 lib/pengine/unpack.c rsc->cluster); rsc 4189 lib/pengine/unpack.c rsc->id, pcmk__xe_history_key(xml_op), rsc 4218 lib/pengine/unpack.c should_ignore_failure_timeout(const pcmk_resource_t *rsc, const char *task, rsc 4241 lib/pengine/unpack.c if (rsc->remote_reconnect_ms rsc 4242 lib/pengine/unpack.c && pcmk_is_set(rsc->cluster->flags, pcmk_sched_fencing_enabled) rsc 4246 lib/pengine/unpack.c pcmk_node_t *remote_node = pcmk_find_node(rsc->cluster, rsc->id); rsc 4251 lib/pengine/unpack.c " until fencing has occurred", rsc->id); rsc 4287 lib/pengine/unpack.c pcmk__rsc_trace(history->rsc, rsc 4294 lib/pengine/unpack.c if ((history->rsc->failure_timeout > 0) rsc 4302 lib/pengine/unpack.c time_t now = get_effective_time(history->rsc->cluster); rsc 4306 lib/pengine/unpack.c if ((now >= (last_run + history->rsc->failure_timeout)) rsc 4307 lib/pengine/unpack.c && !should_ignore_failure_timeout(history->rsc, history->task, rsc 4314 lib/pengine/unpack.c unexpired_fail_count = pe_get_failcount(history->node, history->rsc, rsc 4324 lib/pengine/unpack.c history->rsc->failure_timeout, (long long) last_failure); rsc 4325 lib/pengine/unpack.c last_failure += history->rsc->failure_timeout + 1; rsc 4327 lib/pengine/unpack.c pe__update_recheck_time(last_failure, history->rsc->cluster, rsc 4333 lib/pengine/unpack.c if (pe_get_failcount(history->node, history->rsc, NULL, rsc 4348 lib/pengine/unpack.c pcmk__rsc_trace(history->rsc, rsc 4356 lib/pengine/unpack.c && (history->rsc->remote_reconnect_ms != 0)) { rsc 4366 lib/pengine/unpack.c history->rsc, history->node)) { rsc 4374 lib/pengine/unpack.c clear_op = pe__clear_failcount(history->rsc, history->node, rsc 4375 lib/pengine/unpack.c clear_reason, history->rsc->cluster); rsc 4377 lib/pengine/unpack.c if (pcmk_is_set(history->rsc->cluster->flags, rsc 4379 lib/pengine/unpack.c && (history->rsc->remote_reconnect_ms != 0)) { rsc 4390 lib/pengine/unpack.c history->task, history->rsc->id); rsc 4391 lib/pengine/unpack.c order_after_remote_fencing(clear_op, history->rsc, rsc 4392 lib/pengine/unpack.c history->rsc->cluster); rsc 4405 lib/pengine/unpack.c pcmk__rsc_trace(history->rsc, rsc 4447 lib/pengine/unpack.c || (!pcmk__is_bundled(history->rsc) rsc 4449 lib/pengine/unpack.c history->rsc->role = pcmk_role_stopped; rsc 4461 lib/pengine/unpack.c if (history->rsc->role < pcmk_role_started) { rsc 4462 lib/pengine/unpack.c set_active(history->rsc); rsc 4466 lib/pengine/unpack.c history->rsc->role = pcmk_role_started; rsc 4470 lib/pengine/unpack.c history->rsc->role = pcmk_role_stopped; rsc 4475 lib/pengine/unpack.c history->rsc->role = pcmk_role_promoted; rsc 4486 lib/pengine/unpack.c history->rsc->role = pcmk_role_unpromoted; rsc 4490 lib/pengine/unpack.c history->rsc->role = pcmk_role_started; rsc 4497 lib/pengine/unpack.c } else if (history->rsc->role < pcmk_role_started) { rsc 4498 lib/pengine/unpack.c pcmk__rsc_trace(history->rsc, "%s active on %s", rsc 4499 lib/pengine/unpack.c history->rsc->id, pcmk__node_name(history->node)); rsc 4500 lib/pengine/unpack.c set_active(history->rsc); rsc 4512 lib/pengine/unpack.c pcmk__rsc_trace(history->rsc, rsc 4514 lib/pengine/unpack.c history->rsc->id, pcmk_on_fail_text(*on_fail), rsc 4524 lib/pengine/unpack.c pe__set_next_role(history->rsc, pcmk_role_unknown, rsc 4529 lib/pengine/unpack.c if (history->rsc->remote_reconnect_ms == 0) { rsc 4537 lib/pengine/unpack.c pe__set_next_role(history->rsc, pcmk_role_unknown, rsc 4591 lib/pengine/unpack.c history->id, history->rsc->id, rsc 4608 lib/pengine/unpack.c history->id, history->rsc->id, rsc 4635 lib/pengine/unpack.c if (!pcmk__is_bundled(history->rsc) rsc 4639 lib/pengine/unpack.c if (history->rsc->role <= pcmk_role_stopped) { rsc 4640 lib/pengine/unpack.c history->rsc->role = pcmk_role_unknown; rsc 4644 lib/pengine/unpack.c history->id, history->rsc->id, rsc 4656 lib/pengine/unpack.c history->id, history->task, history->rsc->id, rsc 4675 lib/pengine/unpack.c history->rsc->id, pcmk__node_name(history->node)); rsc 4698 lib/pengine/unpack.c pcmk_resource_t *ban_rsc = history->rsc; rsc 4700 lib/pengine/unpack.c if (!pcmk_is_set(history->rsc->flags, pcmk_rsc_unique)) { rsc 4701 lib/pengine/unpack.c ban_rsc = uber_parent(history->rsc); rsc 4705 lib/pengine/unpack.c services_ocf_exitcode_str(orig_exit_status), history->rsc->id, rsc 4713 lib/pengine/unpack.c "masked-probe-failure", history->rsc->cluster); rsc 4789 lib/pengine/unpack.c pcmk__set_rsc_flags(history->rsc, pcmk_rsc_start_pending); rsc 4790 lib/pengine/unpack.c set_active(history->rsc); rsc 4793 lib/pengine/unpack.c history->rsc->role = pcmk_role_promoted; rsc 4805 lib/pengine/unpack.c target = pcmk_find_node(history->rsc->cluster, migrate_target); rsc 4807 lib/pengine/unpack.c stop_action(history->rsc, target, FALSE); rsc 4811 lib/pengine/unpack.c if (history->rsc->pending_task != NULL) { rsc 4825 lib/pengine/unpack.c history->rsc->pending_task = strdup("probe"); rsc 4826 lib/pengine/unpack.c history->rsc->pending_node = history->node; rsc 4829 lib/pengine/unpack.c history->rsc->pending_task = strdup(history->task); rsc 4830 lib/pengine/unpack.c history->rsc->pending_node = history->node; rsc 4835 lib/pengine/unpack.c unpack_rsc_op(pcmk_resource_t *rsc, pcmk_node_t *node, xmlNode *xml_op, rsc 4840 lib/pengine/unpack.c pcmk_resource_t *parent = rsc; rsc 4845 lib/pengine/unpack.c .rsc = rsc, rsc 4851 lib/pengine/unpack.c CRM_CHECK(rsc && node && xml_op, return); rsc 4856 lib/pengine/unpack.c "without ID", rsc->id, pcmk__node_name(node)); rsc 4865 lib/pengine/unpack.c history.id, rsc->id, pcmk__node_name(node)); rsc 4870 lib/pengine/unpack.c pcmk__rsc_trace(rsc, rsc 4873 lib/pengine/unpack.c history.id, rsc->id, pcmk__node_name(node), rsc 4886 lib/pengine/unpack.c pcmk__rsc_trace(rsc, "Unpacking %s (%s call %d on %s): %s (%s)", rsc 4893 lib/pengine/unpack.c pcmk__rsc_trace(rsc, rsc 4896 lib/pengine/unpack.c rsc->id, pcmk__node_name(node)); rsc 4908 lib/pengine/unpack.c if (!pcmk__is_bundled(rsc) && pcmk_xe_mask_probe_failure(xml_op)) { rsc 4913 lib/pengine/unpack.c if (!pcmk_is_set(rsc->flags, pcmk_rsc_unique)) { rsc 4914 lib/pengine/unpack.c parent = uber_parent(rsc); rsc 4933 lib/pengine/unpack.c history.task, rsc->id, pcmk__node_name(node), rsc 4942 lib/pengine/unpack.c "hard-error", rsc->cluster); rsc 4985 lib/pengine/unpack.c pcmk__s(history.exit_reason, ""), rsc->id, rsc 4992 lib/pengine/unpack.c pcmk__set_rsc_flags(rsc, pcmk_rsc_ignore_failure); rsc 5019 lib/pengine/unpack.c "hard-error", rsc->cluster); rsc 5029 lib/pengine/unpack.c "fatal-error", rsc->cluster); rsc 5034 lib/pengine/unpack.c pcmk__rsc_trace(rsc, "%s role on %s after %s is %s (next %s)", rsc 5035 lib/pengine/unpack.c rsc->id, pcmk__node_name(node), history.id, rsc 5036 lib/pengine/unpack.c pcmk_role_text(rsc->role), rsc 5037 lib/pengine/unpack.c pcmk_role_text(rsc->next_role)); rsc 5101 lib/pengine/unpack.c extract_operations(const char *node, const char *rsc, xmlNode * rsc_entry, gboolean active_filter) rsc 5121 lib/pengine/unpack.c crm_xml_add(rsc_op, PCMK_XA_RESOURCE, rsc); rsc 5164 lib/pengine/unpack.c find_operations(const char *rsc, const char *node, gboolean active_filter, rsc 5222 lib/pengine/unpack.c if (rsc != NULL && !pcmk__str_eq(rsc_id, rsc, pcmk__str_casei)) { rsc 42 lib/pengine/utils.c pcmk_resource_t *rsc = node->details->remote_rsc->container; rsc 44 lib/pengine/utils.c for (GList *n = rsc->running_on; n != NULL; n = n->next) { rsc 176 lib/pengine/utils.c pe__output_node_weights(const pcmk_resource_t *rsc, const char *comment, rsc 188 lib/pengine/utils.c out->message(out, "node-weight", rsc, comment, node->details->uname, rsc 207 lib/pengine/utils.c const pcmk_resource_t *rsc, const char *comment, rsc 218 lib/pengine/utils.c if (rsc) { rsc 222 lib/pengine/utils.c comment, rsc->id, rsc 250 lib/pengine/utils.c bool to_log, const pcmk_resource_t *rsc, rsc 254 lib/pengine/utils.c if ((rsc != NULL) && pcmk_is_set(rsc->flags, pcmk_rsc_removed)) { rsc 264 lib/pengine/utils.c pe__log_node_weights(file, function, line, rsc, comment, nodes); rsc 266 lib/pengine/utils.c pe__output_node_weights(rsc, comment, nodes, scheduler); rsc 270 lib/pengine/utils.c if (rsc && rsc->children) { rsc 271 lib/pengine/utils.c for (GList *gIter = rsc->children; gIter != NULL; gIter = gIter->next) { rsc 322 lib/pengine/utils.c resource_node_score(pcmk_resource_t *rsc, const pcmk_node_t *node, int score, rsc 327 lib/pengine/utils.c if ((rsc->exclusive_discover rsc 336 lib/pengine/utils.c } else if (rsc->children) { rsc 337 lib/pengine/utils.c GList *gIter = rsc->children; rsc 346 lib/pengine/utils.c match = g_hash_table_lookup(rsc->allowed_nodes, node->details->id); rsc 349 lib/pengine/utils.c g_hash_table_insert(rsc->allowed_nodes, (gpointer) match->details->id, match); rsc 352 lib/pengine/utils.c pcmk__rsc_trace(rsc, rsc 354 lib/pengine/utils.c tag, pcmk_readable_score(score), rsc->id, rsc 359 lib/pengine/utils.c resource_location(pcmk_resource_t *rsc, const pcmk_node_t *node, int score, rsc 363 lib/pengine/utils.c resource_node_score(rsc, node, score, tag); rsc 371 lib/pengine/utils.c resource_node_score(rsc, node_iter, score, tag); rsc 378 lib/pengine/utils.c g_hash_table_iter_init(&iter, rsc->allowed_nodes); rsc 380 lib/pengine/utils.c resource_node_score(rsc, node_iter, score, tag); rsc 385 lib/pengine/utils.c if (rsc->allocated_to) { rsc 387 lib/pengine/utils.c rsc->id, pcmk__node_name(rsc->allocated_to)); rsc 388 lib/pengine/utils.c free(rsc->allocated_to); rsc 389 lib/pengine/utils.c rsc->allocated_to = NULL; rsc 410 lib/pengine/utils.c get_target_role(const pcmk_resource_t *rsc, enum rsc_role_e *role) rsc 413 lib/pengine/utils.c const char *value = g_hash_table_lookup(rsc->meta, PCMK_META_TARGET_ROLE); rsc 433 lib/pengine/utils.c "because '%s' is not valid", rsc->id, value); rsc 437 lib/pengine/utils.c if (pcmk_is_set(pe__const_top_resource(rsc, false)->flags, rsc 447 lib/pengine/utils.c "clones", rsc->id, value); rsc 553 lib/pengine/utils.c rsc_printable_id(const pcmk_resource_t *rsc) rsc 555 lib/pengine/utils.c if (pcmk_is_set(rsc->flags, pcmk_rsc_unique)) { rsc 556 lib/pengine/utils.c return rsc->id; rsc 558 lib/pengine/utils.c return pcmk__xe_id(rsc->xml); rsc 562 lib/pengine/utils.c pe__clear_resource_flags_recursive(pcmk_resource_t *rsc, uint64_t flags) rsc 564 lib/pengine/utils.c pcmk__clear_rsc_flags(rsc, flags); rsc 565 lib/pengine/utils.c for (GList *gIter = rsc->children; gIter != NULL; gIter = gIter->next) { rsc 581 lib/pengine/utils.c pe__set_resource_flags_recursive(pcmk_resource_t *rsc, uint64_t flags) rsc 583 lib/pengine/utils.c pcmk__set_rsc_flags(rsc, flags); rsc 584 lib/pengine/utils.c for (GList *gIter = rsc->children; gIter != NULL; gIter = gIter->next) { rsc 591 lib/pengine/utils.c trigger_unfencing(pcmk_resource_t *rsc, pcmk_node_t *node, const char *reason, rsc 598 lib/pengine/utils.c } else if ((rsc != NULL) rsc 599 lib/pengine/utils.c && !pcmk_is_set(rsc->flags, pcmk_rsc_fence_device)) { rsc 614 lib/pengine/utils.c } else if(rsc) { rsc 617 lib/pengine/utils.c g_hash_table_iter_init(&iter, rsc->allowed_nodes); rsc 620 lib/pengine/utils.c trigger_unfencing(rsc, node, reason, dependency, scheduler); rsc 737 lib/pengine/utils.c pe__resource_is_disabled(const pcmk_resource_t *rsc) rsc 741 lib/pengine/utils.c CRM_CHECK(rsc != NULL, return false); rsc 742 lib/pengine/utils.c target_role = g_hash_table_lookup(rsc->meta, PCMK_META_TARGET_ROLE); rsc 749 lib/pengine/utils.c && pcmk_is_set(pe__const_top_resource(rsc, false)->flags, rsc 767 lib/pengine/utils.c pe__rsc_running_on_only(const pcmk_resource_t *rsc, const pcmk_node_t *node) rsc 769 lib/pengine/utils.c return (rsc != NULL) && pcmk__list_of_1(rsc->running_on) rsc 770 lib/pengine/utils.c && pcmk__same_node((const pcmk_node_t *) rsc->running_on->data, rsc 775 lib/pengine/utils.c pe__rsc_running_on_any(pcmk_resource_t *rsc, GList *node_list) rsc 777 lib/pengine/utils.c for (GList *ele = rsc->running_on; ele; ele = ele->next) { rsc 789 lib/pengine/utils.c pcmk__rsc_filtered_by_node(pcmk_resource_t *rsc, GList *only_node) rsc 791 lib/pengine/utils.c return (rsc->fns->active(rsc, FALSE) && !pe__rsc_running_on_any(rsc, only_node)); rsc 800 lib/pengine/utils.c pcmk_resource_t *rsc = (pcmk_resource_t *) gIter->data; rsc 805 lib/pengine/utils.c if (pcmk__str_in_list(rsc_printable_id(rsc), filter, pcmk__str_star_matches) || rsc 806 lib/pengine/utils.c (rsc->parent && pcmk__str_in_list(rsc_printable_id(rsc->parent), filter, pcmk__str_star_matches))) { rsc 807 lib/pengine/utils.c retval = g_list_prepend(retval, rsc); rsc 856 lib/pengine/utils.c pcmk_resource_t *rsc = pe_find_resource_with_flags(scheduler->resources, rsc 859 lib/pengine/utils.c if (rsc) { rsc 866 lib/pengine/utils.c resources = g_list_prepend(resources, strdup(rsc->id)); rsc 868 lib/pengine/utils.c resources = g_list_prepend(resources, strdup(rsc_printable_id(rsc))); rsc 883 lib/pengine/utils.c pe__failed_probe_for_rsc(const pcmk_resource_t *rsc, const char *name) rsc 885 lib/pengine/utils.c const pcmk_resource_t *parent = pe__const_top_resource(rsc, false); rsc 886 lib/pengine/utils.c const char *rsc_id = rsc->id; rsc 892 lib/pengine/utils.c for (xmlNode *xml_op = pcmk__xe_first_child(rsc->cluster->failed, NULL, rsc 134 lib/services/services.c expand_resource_class(const char *rsc, const char *standard, const char *agent) rsc 143 lib/services/services.c crm_debug("Found %s agent %s for %s", found_class, agent, rsc); rsc 158 lib/services/services.c default_standard, agent, rsc); rsc 239 lib/services/services.c op->rsc = strdup(name); rsc 240 lib/services/services.c if (op->rsc == NULL) { rsc 527 lib/services/services.c crm_trace("Removing timer for call %s to %s", op->action, op->rsc); rsc 639 lib/services/services.c free(op->rsc); rsc 864 lib/services/services.c if (op->rsc) { rsc 912 lib/services/services.c && op->rsc && is_op_blocked(op->rsc)) { rsc 930 lib/services/services.c is_op_blocked(const char *rsc) rsc 937 lib/services/services.c if (pcmk__str_eq(op->rsc, rsc, pcmk__str_casei)) { rsc 963 lib/services/services.c if (is_op_blocked(op->rsc)) { rsc 1068 lib/services/services.c op->rsc, op->action, op->interval_ms, op->opaque->exec, op->rc); rsc 476 lib/services/services_linux.c if (op->rsc) { rsc 477 lib/services/services_linux.c set_ocf_env("OCF_RESOURCE_INSTANCE", op->rsc, NULL); rsc 1011 lib/services/services_linux.c rc = pcmk__substitute_secrets(op->rsc, op->params); rsc 1016 lib/services/services_linux.c op->rsc, pcmk_rc_str(rc)); rsc 1020 lib/services/services_linux.c op->rsc, pcmk_rc_str(rc)); rsc 94 lib/services/services_private.h gboolean is_op_blocked(const char *rsc); rsc 315 lib/services/systemd.c error->name, pcmk__s(op->rsc, "unknown resource")); rsc 327 lib/services/systemd.c ((op->rsc == NULL)? "" : " for resource "), pcmk__s(op->rsc, ""), rsc 752 lib/services/systemd.c op->action, pcmk__s(op->rsc, "unknown resource")); rsc 763 lib/services/systemd.c op->action, pcmk__s(op->rsc, "unknown resource"), path); rsc 917 lib/services/systemd.c pcmk__s(op->rsc, "(unspecified)"), name, rsc 1005 lib/services/systemd.c ((op->rsc == NULL)? "" : " for resource "), pcmk__s(op->rsc, "")); rsc 1055 lib/services/systemd.c op->action, op->agent, op->rsc); rsc 1098 lib/services/systemd.c ((op->rsc == NULL)? "" : " for resource "), pcmk__s(op->rsc, "")); rsc 431 lib/services/upstart.c error->name, pcmk__s(op->rsc, "unknown resource")); rsc 443 lib/services/upstart.c error->name, pcmk__s(op->rsc, "unknown resource")); rsc 449 lib/services/upstart.c op->action, op->agent, pcmk__s(op->rsc, "with unknown name"), rsc 481 lib/services/upstart.c pcmk__s(op->rsc, "unknown resource")); rsc 488 lib/services/upstart.c pcmk__s(op->rsc, "unknown resource")); rsc 497 lib/services/upstart.c op->action, pcmk__s(op->rsc, "unknown resource"), path); rsc 636 lib/services/upstart.c action, pcmk__s(op->rsc, "unknown resource"), job); rsc 1783 tools/crm_mon.c send_custom_trap(const char *node, const char *rsc, const char *task, int target_rc, int rc, rsc 1795 tools/crm_mon.c if(rsc) { rsc 1796 tools/crm_mon.c setenv("CRM_notify_rsc", rsc, 1); rsc 1834 tools/crm_mon.c char *rsc = NULL; rsc 1863 tools/crm_mon.c if (parse_op_key(id, &rsc, &task, NULL) == FALSE) { rsc 1894 tools/crm_mon.c crm_notice("%s of %s on %s completed: %s", task, rsc, node, desc); rsc 1901 tools/crm_mon.c crm_warn("%s of %s on %s failed: %s", task, rsc, node, desc); rsc 1905 tools/crm_mon.c crm_warn("%s of %s on %s failed: %s", task, rsc, node, desc); rsc 1909 tools/crm_mon.c send_custom_trap(node, rsc, task, target_rc, rc, status, desc); rsc 1913 tools/crm_mon.c free(rsc); rsc 851 tools/crm_resource.c ban_or_move(pcmk__output_t *out, pcmk_resource_t *rsc, rsc 858 tools/crm_resource.c CRM_CHECK(rsc != NULL, return EINVAL); rsc 860 tools/crm_resource.c current = pe__find_active_requires(rsc, &nactive); rsc 867 tools/crm_resource.c } else if (pcmk_is_set(rsc->flags, pcmk_rsc_promotable)) { rsc 872 tools/crm_resource.c for(iter = rsc->children; iter; iter = iter->next) { rsc 912 tools/crm_resource.c cleanup(pcmk__output_t *out, pcmk_resource_t *rsc, pcmk_node_t *node) rsc 917 tools/crm_resource.c rsc = uber_parent(rsc); rsc 921 tools/crm_resource.c rsc->id, options.rsc_id, (options.host_uname? options.host_uname: "all nodes")); rsc 922 tools/crm_resource.c rc = cli_resource_delete(controld_api, options.host_uname, rsc, rsc 928 tools/crm_resource.c cli_resource_check(out, rsc, node); rsc 1107 tools/crm_resource.c refresh_resource(pcmk__output_t *out, pcmk_resource_t *rsc, pcmk_node_t *node) rsc 1112 tools/crm_resource.c rsc = uber_parent(rsc); rsc 1116 tools/crm_resource.c rsc->id, options.rsc_id, (options.host_uname? options.host_uname: "all nodes")); rsc 1117 tools/crm_resource.c rc = cli_resource_delete(controld_api, options.host_uname, rsc, NULL, 0, rsc 1122 tools/crm_resource.c cli_resource_check(out, rsc, node); rsc 1523 tools/crm_resource.c pcmk_resource_t *rsc = NULL; rsc 1734 tools/crm_resource.c rsc = pe_find_resource_with_flags(scheduler->resources, options.rsc_id, rsc 1736 tools/crm_resource.c if (rsc == NULL) { rsc 1746 tools/crm_resource.c if (pcmk__is_clone(rsc->parent) && (strchr(options.rsc_id, ':') != NULL) rsc 1848 tools/crm_resource.c rc = cli_resource_restart(out, rsc, node, options.move_lifetime, rsc 1866 tools/crm_resource.c exit_code = cli_resource_execute(rsc, options.rsc_id, rsc 1878 tools/crm_resource.c rc = pcmk__resource_digests(out, rsc, node, rsc 1884 tools/crm_resource.c rc = out->message(out, "locations-and-colocations", rsc, rsc 1916 tools/crm_resource.c GList *nodes = cli_resource_search(rsc, options.rsc_id, scheduler); rsc 1923 tools/crm_resource.c rc = cli_resource_print(rsc, scheduler, true); rsc 1927 tools/crm_resource.c rc = cli_resource_print(rsc, scheduler, false); rsc 1935 tools/crm_resource.c scheduler->resources, rsc, node); rsc 1945 tools/crm_resource.c rc = ban_or_move(out, rsc, options.move_lifetime); rsc 1947 tools/crm_resource.c rc = cli_resource_move(rsc, options.rsc_id, options.host_uname, rsc 1963 tools/crm_resource.c rc = ban_or_move(out, rsc, options.move_lifetime); rsc 1981 tools/crm_resource.c rc = out->message(out, "property-list", rsc, options.prop_name); rsc 1995 tools/crm_resource.c pcmk_node_t *current = rsc->fns->active_node(rsc, &count, NULL); rsc 2001 tools/crm_resource.c " returning the default value for %s", rsc->id, rsc 2006 tools/crm_resource.c crm_debug("Looking up %s in %s", options.prop_name, rsc->id); rsc 2010 tools/crm_resource.c params = pe_rsc_params(rsc, current, scheduler); rsc 2018 tools/crm_resource.c get_meta_attributes(params, rsc, NULL, scheduler); rsc 2024 tools/crm_resource.c value = crm_element_value(rsc->xml, options.prop_name); rsc 2033 tools/crm_resource.c pe__unpack_dataset_nvpairs(rsc->xml, PCMK_XE_UTILIZATION, rsc 2040 tools/crm_resource.c rc = out->message(out, "attribute-list", rsc, options.prop_name, value); rsc 2057 tools/crm_resource.c rc = cli_resource_update_attribute(rsc, options.rsc_id, rsc 2069 tools/crm_resource.c rc = cli_resource_delete_attribute(rsc, options.rsc_id, rsc 2078 tools/crm_resource.c if (rsc == NULL) { rsc 2086 tools/crm_resource.c cleanup(out, rsc, node); rsc 2091 tools/crm_resource.c if (rsc == NULL) { rsc 2094 tools/crm_resource.c refresh_resource(out, rsc, node); rsc 44 tools/crm_resource.h pcmk_resource_t *rsc; rsc 56 tools/crm_resource.h pcmk_resource_t *rsc; // Resource being checked rsc 61 tools/crm_resource.h resource_checks_t *cli_check_resource(pcmk_resource_t *rsc, char *role_s, rsc 74 tools/crm_resource.h const char *rsc, const char *node, gboolean promoted_role_only); rsc 77 tools/crm_resource.h void cli_resource_print_cts(pcmk_resource_t *rsc, pcmk__output_t *out); rsc 80 tools/crm_resource.h int cli_resource_print(pcmk_resource_t *rsc, pcmk_scheduler_t *scheduler, rsc 86 tools/crm_resource.h int cli_resource_check(pcmk__output_t *out, pcmk_resource_t *rsc, rsc 90 tools/crm_resource.h GList *cli_resource_search(pcmk_resource_t *rsc, const char *requested_name, rsc 93 tools/crm_resource.h const pcmk_resource_t *rsc, const char *operation, rsc 99 tools/crm_resource.h int cli_resource_restart(pcmk__output_t *out, pcmk_resource_t *rsc, rsc 103 tools/crm_resource.h int cli_resource_move(const pcmk_resource_t *rsc, const char *rsc_id, rsc 114 tools/crm_resource.h crm_exit_t cli_resource_execute(pcmk_resource_t *rsc, rsc 121 tools/crm_resource.h int cli_resource_update_attribute(pcmk_resource_t *rsc, rsc 127 tools/crm_resource.h int cli_resource_delete_attribute(pcmk_resource_t *rsc, rsc 136 tools/crm_resource.h bool resource_is_running_on(pcmk_resource_t *rsc, const char *host); rsc 358 tools/crm_resource_ban.c const char *rsc, const char *node, rsc 378 tools/crm_resource_ban.c if ((node != NULL) || (rsc != NULL) || promoted_role_only) { rsc 384 tools/crm_resource_ban.c if (promoted_role_only || (rsc != NULL)) { rsc 389 tools/crm_resource_ban.c if ((rsc != NULL) && promoted_role_only) { rsc 392 tools/crm_resource_ban.c "@" PCMK_XA_RSC "='", rsc, "' " rsc 395 tools/crm_resource_ban.c } else if (rsc != NULL) { rsc 398 tools/crm_resource_ban.c "@" PCMK_XA_RSC "='", rsc, "'", NULL); rsc 440 tools/crm_resource_ban.c const char *rsc, const char *node, gboolean promoted_role_only) rsc 462 tools/crm_resource_ban.c build_clear_xpath_string(buf, constraint_node, rsc, node, rsc 66 tools/crm_resource_print.c cli_resource_print_cts(pcmk_resource_t *rsc, pcmk__output_t *out) rsc 70 tools/crm_resource_print.c const char *rtype = crm_element_value(rsc->xml, PCMK_XA_TYPE); rsc 71 tools/crm_resource_print.c const char *rprov = crm_element_value(rsc->xml, PCMK_XA_PROVIDER); rsc 72 tools/crm_resource_print.c const char *rclass = crm_element_value(rsc->xml, PCMK_XA_CLASS); rsc 73 tools/crm_resource_print.c pcmk_node_t *node = pcmk__current_node(rsc); rsc 75 tools/crm_resource_print.c if (pcmk_is_set(rsc->flags, pcmk_rsc_fence_device)) { rsc 86 tools/crm_resource_print.c rsc->xml->name, rsc->id, rsc 87 tools/crm_resource_print.c rsc->clone_name ? rsc->clone_name : rsc->id, rsc->parent ? rsc->parent->id : "NA", rsc 88 tools/crm_resource_print.c rprov ? rprov : "NA", rclass, rtype, host ? host : "NA", needs_quorum, rsc->flags, rsc 89 tools/crm_resource_print.c rsc->flags); rsc 91 tools/crm_resource_print.c g_list_foreach(rsc->children, (GFunc) cli_resource_print_cts, out); rsc 121 tools/crm_resource_print.c cli_resource_print(pcmk_resource_t *rsc, pcmk_scheduler_t *scheduler, rsc 131 tools/crm_resource_print.c out->message(out, pcmk__map_element_name(rsc->xml), show_opts, rsc, all, rsc 133 tools/crm_resource_print.c out->message(out, "resource-config", rsc, !expanded); rsc 163 tools/crm_resource_print.c pcmk__output_xml_create_parent(out, (const char *) ud->rsc->xml->name, rsc 164 tools/crm_resource_print.c PCMK_XA_ID, ud->rsc->id, rsc 226 tools/crm_resource_print.c pcmk_resource_t *rsc = va_arg(args, pcmk_resource_t *); rsc 236 tools/crm_resource_print.c out->err(out, "Attribute '%s' not found for '%s'", attr, rsc->id); rsc 322 tools/crm_resource_print.c pcmk_resource_t *rsc = va_arg(args, pcmk_resource_t *); rsc 330 tools/crm_resource_print.c out->err(out, "Attribute '%s' not found for '%s'", attr, rsc->id); rsc 374 tools/crm_resource_print.c pcmk_resource_t *rsc = va_arg(args, pcmk_resource_t *); rsc 377 tools/crm_resource_print.c const char *value = crm_element_value(rsc->xml, attr); rsc 391 tools/crm_resource_print.c pcmk_resource_t *rsc = va_arg(args, pcmk_resource_t *); rsc 394 tools/crm_resource_print.c const char *value = crm_element_value(rsc->xml, attr); rsc 537 tools/crm_resource_print.c const pcmk_resource_t *parent = pe__const_top_resource(checks->rsc, false); rsc 570 tools/crm_resource_print.c pcmk__cluster_option(checks->rsc->cluster->config_hash, rsc 583 tools/crm_resource_print.c const pcmk_resource_t *parent = pe__const_top_resource(checks->rsc, false); rsc 692 tools/crm_resource_print.c pcmk_resource_t *rsc = va_arg(args, pcmk_resource_t *); rsc 699 tools/crm_resource_print.c if ((rsc == NULL) && (host_uname == NULL)) { rsc 704 tools/crm_resource_print.c pcmk_resource_t *rsc = (pcmk_resource_t *) lpc->data; rsc 705 tools/crm_resource_print.c rsc->fns->location(rsc, &hosts, TRUE); rsc 708 tools/crm_resource_print.c out->list_item(out, "reason", "Resource %s is not running", rsc->id); rsc 710 tools/crm_resource_print.c out->list_item(out, "reason", "Resource %s is running", rsc->id); rsc 713 tools/crm_resource_print.c cli_resource_check(out, rsc, NULL); rsc 718 tools/crm_resource_print.c } else if ((rsc != NULL) && (host_uname != NULL)) { rsc 719 tools/crm_resource_print.c if (resource_is_running_on(rsc, host_uname)) { rsc 721 tools/crm_resource_print.c rsc->id, host_uname); rsc 724 tools/crm_resource_print.c rsc->id, host_uname); rsc 727 tools/crm_resource_print.c cli_resource_check(out, rsc, node); rsc 729 tools/crm_resource_print.c } else if ((rsc == NULL) && (host_uname != NULL)) { rsc 737 tools/crm_resource_print.c pcmk_resource_t *rsc = (pcmk_resource_t *) lpc->data; rsc 739 tools/crm_resource_print.c rsc->id, host_uname); rsc 740 tools/crm_resource_print.c cli_resource_check(out, rsc, node); rsc 744 tools/crm_resource_print.c pcmk_resource_t *rsc = (pcmk_resource_t *) lpc->data; rsc 746 tools/crm_resource_print.c rsc->id, host_uname); rsc 747 tools/crm_resource_print.c cli_resource_check(out, rsc, node); rsc 754 tools/crm_resource_print.c } else if ((rsc != NULL) && (host_uname == NULL)) { rsc 757 tools/crm_resource_print.c rsc->fns->location(rsc, &hosts, TRUE); rsc 759 tools/crm_resource_print.c rsc->id, (hosts? "" : "not ")); rsc 760 tools/crm_resource_print.c cli_resource_check(out, rsc, NULL); rsc 774 tools/crm_resource_print.c pcmk_resource_t *rsc = va_arg(args, pcmk_resource_t *); rsc 782 tools/crm_resource_print.c if ((rsc == NULL) && (host_uname == NULL)) { rsc 789 tools/crm_resource_print.c pcmk_resource_t *rsc = (pcmk_resource_t *) lpc->data; rsc 792 tools/crm_resource_print.c rsc->fns->location(rsc, &hosts, TRUE); rsc 796 tools/crm_resource_print.c PCMK_XA_ID, rsc->id, rsc 800 tools/crm_resource_print.c cli_resource_check(out, rsc, NULL); rsc 808 tools/crm_resource_print.c } else if ((rsc != NULL) && (host_uname != NULL)) { rsc 809 tools/crm_resource_print.c if (resource_is_running_on(rsc, host_uname)) { rsc 813 tools/crm_resource_print.c cli_resource_check(out, rsc, node); rsc 815 tools/crm_resource_print.c } else if ((rsc == NULL) && (host_uname != NULL)) { rsc 825 tools/crm_resource_print.c pcmk_resource_t *rsc = (pcmk_resource_t *) lpc->data; rsc 828 tools/crm_resource_print.c PCMK_XA_ID, rsc->id, rsc 833 tools/crm_resource_print.c cli_resource_check(out, rsc, node); rsc 838 tools/crm_resource_print.c pcmk_resource_t *rsc = (pcmk_resource_t *) lpc->data; rsc 841 tools/crm_resource_print.c PCMK_XA_ID, rsc->id, rsc 846 tools/crm_resource_print.c cli_resource_check(out, rsc, node); rsc 855 tools/crm_resource_print.c } else if ((rsc != NULL) && (host_uname == NULL)) { rsc 858 tools/crm_resource_print.c rsc->fns->location(rsc, &hosts, TRUE); rsc 860 tools/crm_resource_print.c cli_resource_check(out, rsc, NULL); rsc 869 tools/crm_resource_print.c add_resource_name(pcmk_resource_t *rsc, pcmk__output_t *out) rsc 871 tools/crm_resource_print.c if (rsc->children == NULL) { rsc 876 tools/crm_resource_print.c out->list_item(out, PCMK_XE_RESOURCE, "%s", rsc->id); rsc 878 tools/crm_resource_print.c g_list_foreach(rsc->children, (GFunc) add_resource_name, out); rsc 25 tools/crm_resource_runtime.c build_node_info_list(const pcmk_resource_t *rsc) rsc 29 tools/crm_resource_runtime.c for (const GList *iter = rsc->children; iter != NULL; iter = iter->next) { rsc 39 tools/crm_resource_runtime.c ni->promoted = pcmk_is_set(rsc->flags, pcmk_rsc_promotable) && rsc 50 tools/crm_resource_runtime.c cli_resource_search(pcmk_resource_t *rsc, const char *requested_name, rsc 54 tools/crm_resource_runtime.c const pcmk_resource_t *parent = pe__const_top_resource(rsc, false); rsc 56 tools/crm_resource_runtime.c if (pcmk__is_clone(rsc)) { rsc 57 tools/crm_resource_runtime.c retval = build_node_info_list(rsc); rsc 61 tools/crm_resource_runtime.c && !pcmk_is_set(rsc->flags, pcmk_rsc_unique) rsc 62 tools/crm_resource_runtime.c && rsc->clone_name rsc 63 tools/crm_resource_runtime.c && pcmk__str_eq(requested_name, rsc->clone_name, pcmk__str_none) rsc 64 tools/crm_resource_runtime.c && !pcmk__str_eq(requested_name, rsc->id, pcmk__str_none)) { rsc 68 tools/crm_resource_runtime.c } else if (rsc->running_on != NULL) { rsc 69 tools/crm_resource_runtime.c for (GList *iter = rsc->running_on; iter != NULL; iter = iter->next) { rsc 74 tools/crm_resource_runtime.c ni->promoted = (rsc->fns->state(rsc, TRUE) == pcmk_role_promoted); rsc 86 tools/crm_resource_runtime.c const char *rsc, const char *attr_set_type, const char *set_name, rsc 110 tools/crm_resource_runtime.c xpath_base, "//*[@" PCMK_XA_ID "=\"", rsc, "\"]", NULL); rsc 161 tools/crm_resource_runtime.c pcmk_resource_t *rsc, const char * attr_set, rsc 166 tools/crm_resource_runtime.c char *lookup_id = clone_strip(rsc->id); rsc 169 tools/crm_resource_runtime.c for(GList *gIter = rsc->children; gIter; gIter = gIter->next) { rsc 175 tools/crm_resource_runtime.c if (pcmk__is_clone(rsc)) { rsc 186 tools/crm_resource_runtime.c *result = g_list_append(*result, rsc); rsc 195 tools/crm_resource_runtime.c find_matching_attr_resources(pcmk__output_t *out, pcmk_resource_t *rsc, rsc 208 tools/crm_resource_runtime.c return g_list_append(result, rsc); rsc 210 tools/crm_resource_runtime.c if (pcmk__is_clone(rsc->parent)) { rsc 215 tools/crm_resource_runtime.c rsc = rsc->parent; rsc 217 tools/crm_resource_runtime.c cmd, attr_name, rsc->id, rsc_id); rsc 219 tools/crm_resource_runtime.c return g_list_append(result, rsc); rsc 221 tools/crm_resource_runtime.c } else if ((rsc->parent == NULL) && (rsc->children != NULL) rsc 222 tools/crm_resource_runtime.c && pcmk__is_clone(rsc)) { rsc 223 tools/crm_resource_runtime.c pcmk_resource_t *child = rsc->children->data; rsc 231 tools/crm_resource_runtime.c rsc = child; rsc 238 tools/crm_resource_runtime.c return g_list_append(result, rsc); rsc 241 tools/crm_resource_runtime.c find_matching_attr_resources_recursive(out, &result, rsc, attr_set, rsc 248 tools/crm_resource_runtime.c update_element_attribute(pcmk__output_t *out, pcmk_resource_t *rsc, rsc 257 tools/crm_resource_runtime.c crm_xml_add(rsc->xml, attr_name, attr_value); rsc 259 tools/crm_resource_runtime.c rc = cib->cmds->replace(cib, PCMK_XE_RESOURCES, rsc->xml, cib_sync_call); rsc 270 tools/crm_resource_runtime.c resources_with_attr(pcmk__output_t *out, cib_t *cib, pcmk_resource_t *rsc, rsc 309 tools/crm_resource_runtime.c *resources = g_list_append(*resources, rsc); rsc 312 tools/crm_resource_runtime.c *resources = find_matching_attr_resources(out, rsc, requested_name, rsc 351 tools/crm_resource_runtime.c update_attribute(pcmk_resource_t *rsc, const char *requested_name, rsc 357 tools/crm_resource_runtime.c pcmk__output_t *out = rsc->cluster->priv; rsc 361 tools/crm_resource_runtime.c const char *top_id = pe__const_top_resource(rsc, false)->id; rsc 368 tools/crm_resource_runtime.c rc = resources_with_attr(out, cib, rsc, requested_name, attr_set, attr_set_type, rsc 386 tools/crm_resource_runtime.c rsc = (pcmk_resource_t *) iter->data; rsc 388 tools/crm_resource_runtime.c lookup_id = clone_strip(rsc->id); /* Could be a cloned group! */ rsc 412 tools/crm_resource_runtime.c xml_top = pcmk__xe_create(NULL, (const char *) rsc->xml->name); rsc 454 tools/crm_resource_runtime.c ud->rsc = rsc; rsc 473 tools/crm_resource_runtime.c pcmk__set_rsc_flags(rsc, pcmk_rsc_detect_loop); rsc 474 tools/crm_resource_runtime.c for (GList *lpc = rsc->rsc_cons_lhs; lpc != NULL; lpc = lpc->next) { rsc 499 tools/crm_resource_runtime.c cli_resource_update_attribute(pcmk_resource_t *rsc, const char *requested_name, rsc 509 tools/crm_resource_runtime.c pcmk__output_t *out = rsc->cluster->priv; rsc 515 tools/crm_resource_runtime.c return update_element_attribute(out, rsc, cib, attr_name, attr_value); rsc 521 tools/crm_resource_runtime.c pcmk__unpack_constraints(rsc->cluster); rsc 522 tools/crm_resource_runtime.c pe__clear_resource_flags_on_all(rsc->cluster, pcmk_rsc_detect_loop); rsc 525 tools/crm_resource_runtime.c rc = update_attribute(rsc, requested_name, attr_set, attr_set_type, rsc 543 tools/crm_resource_runtime.c cli_resource_delete_attribute(pcmk_resource_t *rsc, const char *requested_name, rsc 548 tools/crm_resource_runtime.c pcmk__output_t *out = rsc->cluster->priv; rsc 554 tools/crm_resource_runtime.c pe__const_top_resource(rsc, false)->id, NULL, rsc 559 tools/crm_resource_runtime.c resources = find_matching_attr_resources(out, rsc, requested_name, rsc 565 tools/crm_resource_runtime.c pcmk__xe_remove_attr(rsc->xml, attr_name); rsc 567 tools/crm_resource_runtime.c rc = cib->cmds->replace(cib, PCMK_XE_RESOURCES, rsc->xml, cib_options); rsc 575 tools/crm_resource_runtime.c resources = g_list_append(resources, rsc); rsc 585 tools/crm_resource_runtime.c rsc = (pcmk_resource_t *) iter->data; rsc 587 tools/crm_resource_runtime.c lookup_id = clone_strip(rsc->id); rsc 650 tools/crm_resource_runtime.c pcmk_resource_t *rsc = pe_find_resource(scheduler->resources, rsc_id); rsc 652 tools/crm_resource_runtime.c if (rsc == NULL) { rsc 656 tools/crm_resource_runtime.c } else if (!pcmk__is_primitive(rsc)) { rsc 661 tools/crm_resource_runtime.c rsc_class = crm_element_value(rsc->xml, PCMK_XA_CLASS); rsc 662 tools/crm_resource_runtime.c rsc_provider = crm_element_value(rsc->xml, PCMK_XA_PROVIDER), rsc 663 tools/crm_resource_runtime.c rsc_type = crm_element_value(rsc->xml, PCMK_XA_TYPE); rsc 696 tools/crm_resource_runtime.c if (rsc->clone_name) { rsc 697 tools/crm_resource_runtime.c rsc_api_id = rsc->clone_name; rsc 698 tools/crm_resource_runtime.c rsc_long_id = rsc->id; rsc 700 tools/crm_resource_runtime.c rsc_api_id = rsc->id; rsc 723 tools/crm_resource_runtime.c rsc_fail_name(const pcmk_resource_t *rsc) rsc 725 tools/crm_resource_runtime.c const char *name = (rsc->clone_name? rsc->clone_name : rsc->id); rsc 727 tools/crm_resource_runtime.c if (pcmk_is_set(rsc->flags, pcmk_rsc_unique)) { rsc 848 tools/crm_resource_runtime.c clear_rsc_fail_attrs(const pcmk_resource_t *rsc, const char *operation, rsc 853 tools/crm_resource_runtime.c char *rsc_name = rsc_fail_name(rsc); rsc 869 tools/crm_resource_runtime.c const pcmk_resource_t *rsc, const char *operation, rsc 877 tools/crm_resource_runtime.c if (rsc == NULL) { rsc 880 tools/crm_resource_runtime.c } else if (rsc->children) { rsc 882 tools/crm_resource_runtime.c for (const GList *lpc = rsc->children; lpc != NULL; lpc = lpc->next) { rsc 896 tools/crm_resource_runtime.c GList *nodes = g_hash_table_get_values(rsc->known_on); rsc 901 tools/crm_resource_runtime.c } else if(nodes == NULL && rsc->exclusive_discover) { rsc 905 tools/crm_resource_runtime.c g_hash_table_iter_init(&iter, rsc->allowed_nodes); rsc 913 tools/crm_resource_runtime.c nodes = g_hash_table_get_values(rsc->allowed_nodes); rsc 920 tools/crm_resource_runtime.c rc = cli_resource_delete(controld_api, node->details->uname, rsc, rsc 938 tools/crm_resource_runtime.c rsc->id, host_uname); rsc 944 tools/crm_resource_runtime.c rsc->id, host_uname); rsc 950 tools/crm_resource_runtime.c rsc->id, host_uname); rsc 954 tools/crm_resource_runtime.c rc = clear_rsc_fail_attrs(rsc, operation, interval_spec, node); rsc 957 tools/crm_resource_runtime.c rsc->id, host_uname, pcmk_rc_str(rc)); rsc 962 tools/crm_resource_runtime.c rc = clear_rsc_failures(out, controld_api, host_uname, rsc->id, operation, rsc 965 tools/crm_resource_runtime.c rc = clear_rsc_history(controld_api, host_uname, rsc->id, scheduler); rsc 969 tools/crm_resource_runtime.c rsc->id, host_uname, pcmk_rc_str(rc)); rsc 971 tools/crm_resource_runtime.c out->info(out, "Cleaned up %s on %s", rsc->id, host_uname); rsc 1042 tools/crm_resource_runtime.c const char *role_s = g_hash_table_lookup(checks->rsc->meta, rsc 1054 tools/crm_resource_runtime.c if (pcmk_is_set(pe__const_top_resource(checks->rsc, false)->flags, rsc 1068 tools/crm_resource_runtime.c const char *managed_s = g_hash_table_lookup(checks->rsc->meta, rsc 1079 tools/crm_resource_runtime.c if (checks->rsc->lock_node != NULL) { rsc 1081 tools/crm_resource_runtime.c checks->lock_node = checks->rsc->lock_node->details->uname; rsc 1123 tools/crm_resource_runtime.c g_hash_table_iter_init(&iter, checks->rsc->allowed_nodes); rsc 1141 tools/crm_resource_runtime.c cli_resource_check(pcmk__output_t *out, pcmk_resource_t *rsc, pcmk_node_t *node) rsc 1143 tools/crm_resource_runtime.c resource_checks_t checks = { .rsc = rsc }; rsc 1163 tools/crm_resource_runtime.c generate_resource_params(pcmk_resource_t *rsc, pcmk_node_t *node, rsc 1175 tools/crm_resource_runtime.c params = pe_rsc_params(rsc, node, scheduler); rsc 1184 tools/crm_resource_runtime.c get_meta_attributes(meta, rsc, NULL, scheduler); rsc 1198 tools/crm_resource_runtime.c bool resource_is_running_on(pcmk_resource_t *rsc, const char *host) rsc 1204 tools/crm_resource_runtime.c if (rsc == NULL) { rsc 1208 tools/crm_resource_runtime.c rsc->fns->location(rsc, &hosts, TRUE); rsc 1213 tools/crm_resource_runtime.c crm_trace("Resource %s is running on %s\n", rsc->id, host); rsc 1219 tools/crm_resource_runtime.c crm_trace("Resource %s is not running on: %s\n", rsc->id, host); rsc 1223 tools/crm_resource_runtime.c crm_trace("Resource %s is not running\n", rsc->id); rsc 1248 tools/crm_resource_runtime.c pcmk_resource_t *rsc = (pcmk_resource_t *) rIter->data; rsc 1254 tools/crm_resource_runtime.c if (pcmk__is_group(rsc)) { rsc 1256 tools/crm_resource_runtime.c get_active_resources(host, rsc->children)); rsc 1257 tools/crm_resource_runtime.c } else if (resource_is_running_on(rsc, host)) { rsc 1258 tools/crm_resource_runtime.c active = g_list_append(active, strdup(rsc->id)); rsc 1428 tools/crm_resource_runtime.c max_rsc_stop_timeout(pcmk_resource_t *rsc) rsc 1435 tools/crm_resource_runtime.c if (rsc == NULL) { rsc 1440 tools/crm_resource_runtime.c if (rsc->children != NULL) { rsc 1441 tools/crm_resource_runtime.c for (GList *iter = rsc->children; iter; iter = iter->next) { rsc 1446 tools/crm_resource_runtime.c pcmk__rsc_trace(rsc, rsc 1448 tools/crm_resource_runtime.c "due to %s", rsc->id, rsc 1457 tools/crm_resource_runtime.c config = pcmk__find_action_config(rsc, PCMK_ACTION_STOP, 0, true); rsc 1464 tools/crm_resource_runtime.c meta = pcmk__unpack_action_meta(rsc, NULL, PCMK_ACTION_STOP, 0, config); rsc 1496 tools/crm_resource_runtime.c pcmk_resource_t *rsc = pe_find_resource(scheduler->resources, rsc 1498 tools/crm_resource_runtime.c guint delay = max_rsc_stop_timeout(rsc); rsc 1501 tools/crm_resource_runtime.c pcmk__rsc_trace(rsc, rsc 1503 tools/crm_resource_runtime.c pcmk__readable_interval(delay), rsc->id); rsc 1538 tools/crm_resource_runtime.c cli_resource_restart(pcmk__output_t *out, pcmk_resource_t *rsc, rsc 1561 tools/crm_resource_runtime.c pcmk_resource_t *parent = uber_parent(rsc); rsc 1564 tools/crm_resource_runtime.c const char *id = rsc->clone_name ? rsc->clone_name : rsc->id; rsc 1570 tools/crm_resource_runtime.c if (pcmk__is_bundled(rsc)) { rsc 1571 tools/crm_resource_runtime.c rsc = parent->parent; rsc 1574 tools/crm_resource_runtime.c running = resource_is_running_on(rsc, host); rsc 1578 tools/crm_resource_runtime.c lookup_id = strdup(rsc->id); rsc 1580 tools/crm_resource_runtime.c lookup_id = clone_strip(rsc->id); rsc 1583 tools/crm_resource_runtime.c rsc = parent->fns->find_rsc(parent, lookup_id, node, rsc 1587 tools/crm_resource_runtime.c running = resource_is_running_on(rsc, host); rsc 1599 tools/crm_resource_runtime.c if (!pcmk_is_set(rsc->flags, pcmk_rsc_managed)) { rsc 1604 tools/crm_resource_runtime.c rsc_id = strdup(rsc->id); rsc 1607 tools/crm_resource_runtime.c lookup_id = strdup(rsc->id); rsc 1609 tools/crm_resource_runtime.c lookup_id = clone_strip(rsc->id); rsc 1613 tools/crm_resource_runtime.c if (pcmk__is_clone(rsc) || pe_bundle_replicas(rsc)) { rsc 1683 tools/crm_resource_runtime.c rc = cli_resource_update_attribute(rsc, rsc_id, NULL, rsc 1764 tools/crm_resource_runtime.c rc = cli_resource_update_attribute(rsc, rsc_id, NULL, rsc 1771 tools/crm_resource_runtime.c rc = cli_resource_delete_attribute(rsc, rsc_id, NULL, rsc 1794 tools/crm_resource_runtime.c while (waiting_for_starts(list_delta, rsc, host)) { rsc 1802 tools/crm_resource_runtime.c for (lpc = 0; (lpc < step_timeout_s) && waiting_for_starts(list_delta, rsc, host); lpc++) { rsc 1847 tools/crm_resource_runtime.c cli_resource_update_attribute(rsc, rsc_id, NULL, rsc 1853 tools/crm_resource_runtime.c cli_resource_delete_attribute(rsc, rsc_id, NULL, rsc 2202 tools/crm_resource_runtime.c get_action_timeout(pcmk_resource_t *rsc, const char *action) rsc 2205 tools/crm_resource_runtime.c xmlNode *op = pcmk__find_action_config(rsc, action, 0, true); rsc 2206 tools/crm_resource_runtime.c GHashTable *meta = pcmk__unpack_action_meta(rsc, NULL, action, 0, op); rsc 2218 tools/crm_resource_runtime.c cli_resource_execute(pcmk_resource_t *rsc, const char *requested_name, rsc 2233 tools/crm_resource_runtime.c if (pcmk__is_clone(rsc)) { rsc 2234 tools/crm_resource_runtime.c GList *nodes = cli_resource_search(rsc, requested_name, scheduler); rsc 2237 tools/crm_resource_runtime.c rsc_action, rsc->id); rsc 2249 tools/crm_resource_runtime.c if (pcmk__is_clone(rsc)) { rsc 2251 tools/crm_resource_runtime.c rsc = rsc->children->data; rsc 2254 tools/crm_resource_runtime.c if (pcmk__is_group(rsc)) { rsc 2257 tools/crm_resource_runtime.c } else if (pcmk__is_bundled(rsc)) { rsc 2262 tools/crm_resource_runtime.c rclass = crm_element_value(rsc->xml, PCMK_XA_CLASS); rsc 2263 tools/crm_resource_runtime.c rprov = crm_element_value(rsc->xml, PCMK_XA_PROVIDER); rsc 2264 tools/crm_resource_runtime.c rtype = crm_element_value(rsc->xml, PCMK_XA_TYPE); rsc 2266 tools/crm_resource_runtime.c params = generate_resource_params(rsc, NULL /* @TODO use local node */, rsc 2270 tools/crm_resource_runtime.c timeout_ms = get_action_timeout(rsc, get_action(rsc_action)); rsc 2273 tools/crm_resource_runtime.c rid = pcmk__is_anonymous_clone(rsc->parent)? requested_name : rsc->id; rsc 2283 tools/crm_resource_runtime.c cli_resource_move(const pcmk_resource_t *rsc, const char *rsc_id, rsc 2300 tools/crm_resource_runtime.c && !pcmk_is_set(rsc->flags, pcmk_rsc_promotable)) { rsc 2302 tools/crm_resource_runtime.c const pcmk_resource_t *p = pe__const_top_resource(rsc, false); rsc 2305 tools/crm_resource_runtime.c out->info(out, "Using parent '%s' for move instead of '%s'.", rsc->id, rsc_id); rsc 2307 tools/crm_resource_runtime.c rsc = p; rsc 2316 tools/crm_resource_runtime.c current = pe__find_active_requires(rsc, &count); rsc 2318 tools/crm_resource_runtime.c if (pcmk_is_set(rsc->flags, pcmk_rsc_promotable)) { rsc 2322 tools/crm_resource_runtime.c for (const GList *iter = rsc->children; iter; iter = iter->next) { rsc 2327 tools/crm_resource_runtime.c rsc = child; rsc 2340 tools/crm_resource_runtime.c if (pcmk__is_clone(rsc)) { rsc 2372 tools/crm_resource_runtime.c rsc->id, (promoted_role_only? " (promoted)" : ""),