Send Linux-ha-cvs mailing list submissions to linux-ha-cvs@lists.linux-ha.org
To subscribe or unsubscribe via the World Wide Web, visit http://lists.community.tummy.com/mailman/listinfo/linux-ha-cvs or, via email, send a message with subject or body 'help' to [EMAIL PROTECTED] You can reach the person managing the list at [EMAIL PROTECTED] When replying, please edit your Subject line so it is more specific than "Re: Contents of Linux-ha-cvs digest..." Today's Topics: 1. Linux-HA CVS: crm by andrew from (linux-ha-cvs@lists.linux-ha.org) 2. Linux-HA CVS: crm by andrew from (linux-ha-cvs@lists.linux-ha.org) 3. Linux-HA CVS: crm by andrew from (linux-ha-cvs@lists.linux-ha.org) 4. Linux-HA CVS: include by andrew from (linux-ha-cvs@lists.linux-ha.org) ---------------------------------------------------------------------- Message: 1 Date: Fri, 23 Jun 2006 02:32:01 -0600 (MDT) From: linux-ha-cvs@lists.linux-ha.org Subject: [Linux-ha-cvs] Linux-HA CVS: crm by andrew from To: [EMAIL PROTECTED] Message-ID: <[EMAIL PROTECTED]> linux-ha CVS committal Author : andrew Host : Project : linux-ha Module : crm Dir : linux-ha/crm/admin Modified Files: crm_resource.c Log Message: Alternate logging setup that doesnt change the working directory =================================================================== RCS file: /home/cvs/linux-ha/linux-ha/crm/admin/crm_resource.c,v retrieving revision 1.41 retrieving revision 1.42 diff -u -3 -r1.41 -r1.42 --- crm_resource.c 22 Jun 2006 09:10:23 -0000 1.41 +++ crm_resource.c 23 Jun 2006 08:32:00 -0000 1.42 @@ -1,4 +1,4 @@ -/* $Id: crm_resource.c,v 1.41 2006/06/22 09:10:23 andrew Exp $ */ +/* $Id: crm_resource.c,v 1.42 2006/06/23 08:32:00 andrew Exp $ */ /* * Copyright (C) 2004 Andrew Beekhof <[EMAIL PROTECTED]> @@ -606,8 +606,9 @@ #endif crm_system_name = basename(argv[0]); - crm_log_init(crm_system_name); - crm_log_level = LOG_ERR; + cl_log_set_entity(crm_system_name); + cl_log_set_facility(LOG_USER); + set_crm_log_level(LOG_ERR); cl_log_enable_stderr(TRUE); if(argc < 2) { ------------------------------ Message: 2 Date: Fri, 23 Jun 2006 02:33:53 -0600 (MDT) From: linux-ha-cvs@lists.linux-ha.org Subject: [Linux-ha-cvs] Linux-HA CVS: crm by andrew from To: [EMAIL PROTECTED] Message-ID: <[EMAIL PROTECTED]> linux-ha CVS committal Author : andrew Host : Project : linux-ha Module : crm Dir : linux-ha/crm/crmd Modified Files: tengine.c Log Message: Pass the potentially very large TE graph around as a pointer to a file on disk to avoid IPC size limitations in larger (#nodes and/or #resources) clusters. =================================================================== RCS file: /home/cvs/linux-ha/linux-ha/crm/crmd/tengine.c,v retrieving revision 1.27 retrieving revision 1.28 diff -u -3 -r1.27 -r1.28 --- tengine.c 23 Feb 2006 09:36:01 -0000 1.27 +++ tengine.c 23 Jun 2006 08:33:53 -0000 1.28 @@ -150,14 +150,20 @@ if(action & A_TE_INVOKE) { ha_msg_input_t *input = fsa_typed_data(fsa_dt_ha_msg); - if(input->xml != NULL) { + const char *graph_file = cl_get_string(input->msg, F_CRM_TGRAPH); + const char *graph_input = cl_get_string(input->msg, F_CRM_TGRAPH_INPUT); + if(graph_file != NULL) { + crm_debug("Starting a transition"); set_bit_inplace(fsa_input_register, R_IN_TRANSITION); cmd = create_request( - CRM_OP_TRANSITION, input->xml, NULL, + CRM_OP_TRANSITION, NULL, NULL, CRM_SYSTEM_TENGINE, CRM_SYSTEM_DC, NULL); + + ha_msg_add(cmd, F_CRM_TGRAPH, graph_file); + ha_msg_add(cmd, F_CRM_TGRAPH_INPUT, graph_input); send_request(cmd, NULL); ------------------------------ Message: 3 Date: Fri, 23 Jun 2006 02:33:53 -0600 (MDT) From: linux-ha-cvs@lists.linux-ha.org Subject: [Linux-ha-cvs] Linux-HA CVS: crm by andrew from To: [EMAIL PROTECTED] Message-ID: <[EMAIL PROTECTED]> linux-ha CVS committal Author : andrew Host : Project : linux-ha Module : crm Dir : linux-ha/crm/pengine Modified Files: pengine.c Log Message: Pass the potentially very large TE graph around as a pointer to a file on disk to avoid IPC size limitations in larger (#nodes and/or #resources) clusters. =================================================================== RCS file: /home/cvs/linux-ha/linux-ha/crm/pengine/pengine.c,v retrieving revision 1.116 retrieving revision 1.117 diff -u -3 -r1.116 -r1.117 --- pengine.c 13 Jun 2006 09:39:05 -0000 1.116 +++ pengine.c 23 Jun 2006 08:33:53 -0000 1.117 @@ -1,4 +1,4 @@ -/* $Id: pengine.c,v 1.116 2006/06/13 09:39:05 andrew Exp $ */ +/* $Id: pengine.c,v 1.117 2006/06/23 08:33:53 andrew Exp $ */ /* * Copyright (C) 2004 Andrew Beekhof <[EMAIL PROTECTED]> * @@ -88,30 +88,34 @@ int series_id = 0; int series_wrap = 0; char *filename = NULL; + char *graph_file = NULL; const char *value = NULL; pe_working_set_t data_set; crm_data_t *generation = create_xml_node(NULL, XML_TAG_CIB); crm_data_t *log_input = copy_xml(xml_data); + HA_Message *reply = NULL; #if HAVE_BZLIB_H gboolean compress = TRUE; #else gboolean compress = FALSE; #endif - copy_in_properties(generation, xml_data); crm_log_xml_info(generation, "[generation]"); was_processing_error = FALSE; was_processing_warning = FALSE; + graph_file = crm_strdup(WORKING_DIR"/graph.XXXXXX"); + mktemp(graph_file); + crm_zero_mem_stats(NULL); do_calculations(&data_set, xml_data, NULL); - crm_log_xml_debug_3(data_set.graph, "[out]"); - if(send_ipc_reply(sender, msg, data_set.graph) == FALSE) { - crm_err("Answer could not be sent"); + crm_info("Writing the TE graph to %s", graph_file); + if(write_xml_file(data_set.graph, graph_file, FALSE) < 0) { + crm_err("TE graph could not be written to disk"); } series_id = get_series(); @@ -129,15 +133,15 @@ pe_config_warn("No value specified for cluster" " preference: %s", series[series_id].param); - } - + } + data_set.input = NULL; cleanup_alloc_calculations(&data_set); - if(is_ipc_empty(sender) && crm_mem_stats(NULL)) { + if(crm_mem_stats(NULL)) { pe_warn("Unfree'd memory"); } - + seq = get_last_sequence(PE_WORKING_DIR, series[series_id].name); filename = generate_series_filename( @@ -173,7 +177,16 @@ " Please run \"crm_verify -L\" to identify issues."); } + reply = create_reply(msg, NULL); + ha_msg_add(reply, F_CRM_TGRAPH, graph_file); + ha_msg_add(reply, F_CRM_TGRAPH_INPUT, filename); + CRM_ASSERT(reply != NULL); + if(send_ipc_message(sender, reply) == FALSE) { + crm_err("Answer could not be sent"); + } + free_xml(generation); + crm_free(graph_file); free_xml(log_input); crm_free(filename); ------------------------------ Message: 4 Date: Fri, 23 Jun 2006 02:33:53 -0600 (MDT) From: linux-ha-cvs@lists.linux-ha.org Subject: [Linux-ha-cvs] Linux-HA CVS: include by andrew from To: [EMAIL PROTECTED] Message-ID: <[EMAIL PROTECTED]> linux-ha CVS committal Author : andrew Host : Project : linux-ha Module : include Dir : linux-ha/include/crm Modified Files: msg_xml.h Log Message: Pass the potentially very large TE graph around as a pointer to a file on disk to avoid IPC size limitations in larger (#nodes and/or #resources) clusters. =================================================================== RCS file: /home/cvs/linux-ha/linux-ha/include/crm/msg_xml.h,v retrieving revision 1.55 retrieving revision 1.56 diff -u -3 -r1.55 -r1.56 --- msg_xml.h 2 Jun 2006 15:52:13 -0000 1.55 +++ msg_xml.h 23 Jun 2006 08:33:53 -0000 1.56 @@ -1,4 +1,4 @@ -/* $Id: msg_xml.h,v 1.55 2006/06/02 15:52:13 andrew Exp $ */ +/* $Id: msg_xml.h,v 1.56 2006/06/23 08:33:53 andrew Exp $ */ /* * Copyright (C) 2004 Andrew Beekhof <[EMAIL PROTECTED]> * @@ -31,6 +31,8 @@ #define F_CRM_JOIN_ID "join_id" #define F_CRM_ELECTION_ID "election-id" #define F_CRM_ELECTION_OWNER "election-owner" +#define F_CRM_TGRAPH "crm-tgraph" +#define F_CRM_TGRAPH_INPUT "crm-tgraph-in" /*---- Common tags/attrs */ #define XML_DIFF_MARKER "__crm_diff_marker__" ------------------------------ _______________________________________________ Linux-ha-cvs mailing list Linux-ha-cvs@lists.linux-ha.org http://lists.community.tummy.com/mailman/listinfo/linux-ha-cvs End of Linux-ha-cvs Digest, Vol 31, Issue 88 ********************************************