Send Linux-ha-cvs mailing list submissions to
        [email protected]

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: membership by gshi from 
      ([email protected])
   2. Linux-HA CVS: doc by gshi from  ([email protected])
   3. Linux-HA CVS: crm by andrew from 
      ([email protected])
   4. Linux-HA CVS: crm by andrew from 
      ([email protected])


----------------------------------------------------------------------

Message: 1
Date: Mon, 21 Nov 2005 14:43:31 -0700 (MST)
From: [email protected]
Subject: [Linux-ha-cvs] Linux-HA CVS: membership by gshi from 
To: [EMAIL PROTECTED]
Message-ID: <[EMAIL PROTECTED]>

linux-ha CVS committal

Author  : gshi
Host    : 
Project : linux-ha
Module  : membership

Dir     : linux-ha/membership/ccm


Modified Files:
        ccmmain.c 


Log Message:
change the send queue size from ccm to logd


===================================================================
RCS file: /home/cvs/linux-ha/linux-ha/membership/ccm/ccmmain.c,v
retrieving revision 1.31
retrieving revision 1.32
diff -u -3 -r1.31 -r1.32
--- ccmmain.c   5 Oct 2005 22:36:57 -0000       1.31
+++ ccmmain.c   21 Nov 2005 21:43:30 -0000      1.32
@@ -1,4 +1,4 @@
-/* $Id: ccmmain.c,v 1.31 2005/10/05 22:36:57 gshi Exp $ */
+/* $Id: ccmmain.c,v 1.32 2005/11/21 21:43:30 gshi Exp $ */
 /* 
  * ccm.c: Consensus Cluster Service Program 
  *
@@ -246,7 +246,7 @@
        CL_SIGNAL(SIGUSR2, ccm_debug);
        CL_IGNORE_SIG(SIGPIPE);
        
-       cl_inherit_use_logd(ENV_PREFIX ""KEY_LOGDAEMON, 0);
+       cl_inherit_use_logd(ENV_PREFIX ""KEY_LOGDAEMON, 256);
        
        inherit_logconfig_from_environment();
 




------------------------------

Message: 2
Date: Mon, 21 Nov 2005 15:32:46 -0700 (MST)
From: [email protected]
Subject: [Linux-ha-cvs] Linux-HA CVS: doc by gshi from 
To: [EMAIL PROTECTED]
Message-ID: <[EMAIL PROTECTED]>

linux-ha CVS committal

Author  : gshi
Host    : 
Project : linux-ha
Module  : doc

Dir     : linux-ha/doc


Modified Files:
        Makefile.am 
Added Files:
        hb_addnode.1 hb_delnode.1 


Log Message:
add man page for hb_addnode and hb_delnode

===================================================================
RCS file: /home/cvs/linux-ha/linux-ha/doc/Makefile.am,v
retrieving revision 1.23
retrieving revision 1.24
diff -u -3 -r1.23 -r1.24
--- Makefile.am 20 Sep 2005 02:00:01 -0000      1.23
+++ Makefile.am 21 Nov 2005 22:32:46 -0000      1.24
@@ -41,7 +41,7 @@
 doc_DATA               = $(OTHER_DOCS) $(txtfiles) $(htmlfiles) 
 
 man_MANS               = heartbeat.8 apphbd.8 cl_status.1 ha_logd.8 
ha_logger.1 \
-                        hb_standby.1 hb_takeover.1
+                        hb_standby.1 hb_takeover.1 hb_addnode.1 hb_delnode.1
 
 EXTRA_DIST = $(txtfiles) $(htmlfiles) $(man_MANS) $(OTHER_DOCS)
 




------------------------------

Message: 3
Date: Mon, 21 Nov 2005 19:37:08 -0700 (MST)
From: [email protected]
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_mon.c crm_uuid.c 


Log Message:
BEAM Fixes

===================================================================
RCS file: /home/cvs/linux-ha/linux-ha/crm/admin/crm_mon.c,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -3 -r1.16 -r1.17
--- crm_mon.c   14 Oct 2005 09:43:54 -0000      1.16
+++ crm_mon.c   22 Nov 2005 02:37:08 -0000      1.17
@@ -1,4 +1,4 @@
-/* $Id: crm_mon.c,v 1.16 2005/10/14 09:43:54 andrew Exp $ */
+/* $Id: crm_mon.c,v 1.17 2005/11/22 02:37:08 andrew Exp $ */
 
 /* 
  * Copyright (C) 2004 Andrew Beekhof <[EMAIL PROTECTED]>
@@ -250,9 +250,13 @@
        if(cib_conn == NULL) {
                crm_debug_4("Creating CIB connection");
                cib_conn = cib_new();
-               CRM_DEV_ASSERT(cib_conn != NULL);
        }
-       if(cib_conn != NULL && cib_conn->state != cib_connected_query){
+
+       CRM_DEV_ASSERT(cib_conn != NULL);
+       if(crm_assert_failed) {
+               return FALSE;
+               
+       } else if(cib_conn->state != cib_connected_query){
                crm_debug_4("Connecting to the CIB");
 #if CURSES_ENABLED
                if(as_console) {
===================================================================
RCS file: /home/cvs/linux-ha/linux-ha/crm/admin/crm_uuid.c,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -3 -r1.1 -r1.2
--- crm_uuid.c  25 Oct 2005 13:55:51 -0000      1.1
+++ crm_uuid.c  22 Nov 2005 02:37:08 -0000      1.2
@@ -1,4 +1,4 @@
-/* $Id: crm_uuid.c,v 1.1 2005/10/25 13:55:51 andrew Exp $ */
+/* $Id: crm_uuid.c,v 1.2 2005/11/22 02:37:08 andrew Exp $ */
 
 /* 
  * Copyright (C) 2004 Andrew Beekhof <[EMAIL PROTECTED]>
@@ -77,9 +77,12 @@
                        UUID_LEN, read_len);
                return 3;
                
-       } else {
+       } else if(buffer != NULL) {
                cl_uuid_unparse(&uuid, buffer);
                fprintf(stdout, "%s\n", buffer);
+
+       } else {
+               fprintf(stderr, "No buffer to unparse\n");
        }
        
        cl_free(buffer);




------------------------------

Message: 4
Date: Mon, 21 Nov 2005 19:40:24 -0700 (MST)
From: [email protected]
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:
        control.c election.c utils.c 


Log Message:
Timer fixes prompted by BEAM complaints

===================================================================
RCS file: /home/cvs/linux-ha/linux-ha/crm/crmd/control.c,v
retrieving revision 1.100
retrieving revision 1.101
diff -u -3 -r1.100 -r1.101
--- control.c   16 Sep 2005 16:45:58 -0000      1.100
+++ control.c   22 Nov 2005 02:40:24 -0000      1.101
@@ -264,7 +264,7 @@
        interval = interval * 1000;
 
        if(election_trigger != NULL) {
-               election_trigger->source_id = -1;
+               election_trigger->source_id = 0;
                election_trigger->period_ms = -1;
                election_trigger->fsa_input = I_DC_TIMEOUT;
                election_trigger->callback = crm_timer_popped;
@@ -274,7 +274,7 @@
        }
        
        if(dc_heartbeat != NULL) {
-               dc_heartbeat->source_id = -1;
+               dc_heartbeat->source_id = 0;
                dc_heartbeat->period_ms = -1;
                dc_heartbeat->fsa_input = I_NULL;
                dc_heartbeat->callback = do_dc_heartbeat;
@@ -284,7 +284,7 @@
        }
        
        if(election_timeout != NULL) {
-               election_timeout->source_id = -1;
+               election_timeout->source_id = 0;
                election_timeout->period_ms = -1;
                election_timeout->fsa_input = I_ELECTION_DC;
                election_timeout->callback = crm_timer_popped;
@@ -294,7 +294,7 @@
        }
        
        if(integration_timer != NULL) {
-               integration_timer->source_id = -1;
+               integration_timer->source_id = 0;
                integration_timer->period_ms = -1;
                integration_timer->fsa_input = I_INTEGRATED;
                integration_timer->callback = crm_timer_popped;
@@ -304,7 +304,7 @@
        }
        
        if(finalization_timer != NULL) {
-               finalization_timer->source_id = -1;
+               finalization_timer->source_id = 0;
                finalization_timer->period_ms = -1;
                finalization_timer->fsa_input = I_FINALIZED;
                finalization_timer->callback = crm_timer_popped;
@@ -314,7 +314,7 @@
        }
        
        if(shutdown_escalation_timer != NULL) {
-               shutdown_escalation_timer->source_id = -1;
+               shutdown_escalation_timer->source_id = 0;
                shutdown_escalation_timer->period_ms = -1;
                shutdown_escalation_timer->fsa_input = I_STOP;
                shutdown_escalation_timer->callback = crm_timer_popped;
@@ -324,7 +324,7 @@
        }
        
        if(wait_timer != NULL) {
-               wait_timer->source_id = -1;
+               wait_timer->source_id = 0;
                wait_timer->period_ms = 500;
                wait_timer->fsa_input = I_NULL;
                wait_timer->callback = crm_timer_popped;
@@ -334,7 +334,7 @@
        }
 
        if(shutdown_timer != NULL) {
-               shutdown_timer->source_id = -1;
+               shutdown_timer->source_id = 0;
                shutdown_timer->period_ms = -1;
                shutdown_timer->fsa_input = I_SHUTDOWN;
                shutdown_timer->callback = crm_timer_popped;
@@ -344,7 +344,7 @@
        }
 
        if(recheck_timer != NULL) {
-               recheck_timer->source_id = -1;
+               recheck_timer->source_id = 0;
                recheck_timer->period_ms = -1;
                recheck_timer->fsa_input = I_PE_CALC;
                recheck_timer->callback = crm_timer_popped;
===================================================================
RCS file: /home/cvs/linux-ha/linux-ha/crm/crmd/election.c,v
retrieving revision 1.99
retrieving revision 1.100
diff -u -3 -r1.99 -r1.100
--- election.c  20 Oct 2005 13:48:31 -0000      1.99
+++ election.c  22 Nov 2005 02:40:24 -0000      1.100
@@ -291,8 +291,7 @@
        set_bit_inplace(fsa_input_register, R_JOIN_OK);
        set_bit_inplace(fsa_input_register, R_INVOKE_PE);
        
-       if(dc_heartbeat->source_id == (guint)-1
-          || dc_heartbeat->source_id == (guint)-2) {
+       if(dc_heartbeat->source_id != 0) {
                crm_debug_3("Starting DC Heartbeat timer");
                dc_heartbeat->source_id = Gmain_timeout_add_full(
                        G_PRIORITY_HIGH, dc_heartbeat->period_ms,
===================================================================
RCS file: /home/cvs/linux-ha/linux-ha/crm/crmd/utils.c,v
retrieving revision 1.80
retrieving revision 1.81
diff -u -3 -r1.80 -r1.81
--- utils.c     20 Oct 2005 13:48:31 -0000      1.80
+++ utils.c     22 Nov 2005 02:40:24 -0000      1.81
@@ -88,25 +88,53 @@
        return I_NULL;
 }
 
-gboolean
-crm_timer_popped(gpointer data)
+static const char *
+get_timer_desc(fsa_timer_t *timer) 
 {
-       fsa_timer_t *timer = (fsa_timer_t *)data;
-
        if(timer == election_trigger) {
-               crm_info("Election Trigger (%s) just popped!",
-                        fsa_input2string(timer->fsa_input));
+               return "Election Trigger";
 
        } else if(timer == election_timeout) {
-               crm_info("Election Timeout (%s) just popped!",
-                        fsa_input2string(timer->fsa_input));
-
+               return "Election Timeout";
+               
        } else if(timer == shutdown_escalation_timer) {
-               crm_err("Shutdown Escalation Timer (%s) just popped!",
+               return "Shutdown Escalation";
+
+       } else if(timer == shutdown_timer) {
+               return "Shutdown Timer";
+
+       } else if(timer == integration_timer) {
+               return "Integration Timer";
+
+       } else if(timer == finalization_timer) {
+               return "Finalization Timer";
+
+       } else if(timer == dc_heartbeat) {
+               return "Heartbeat Timer";
+
+       } else if(timer == wait_timer) {
+               return "Wait Timer";
+
+       } else if(timer == recheck_timer) {
+               return "Recheck Timer";
+               
+       }       
+       return "Unknown Timer";
+}
+
+gboolean
+crm_timer_popped(gpointer data)
+{
+       fsa_timer_t *timer = (fsa_timer_t *)data;
+
+       if(timer == shutdown_escalation_timer) {
+               crm_err("%s (%s) just popped!",
+                       get_timer_desc(timer),
                        fsa_input2string(timer->fsa_input));
                
        } else {
-               crm_info("Timer %s just popped!",
+               crm_info("%s (%s) just popped!",
+                        get_timer_desc(timer),
                         fsa_input2string(timer->fsa_input));
        }
 
@@ -141,22 +169,12 @@
 gboolean
 crm_timer_start(fsa_timer_t *timer)
 {
-       const char *timer_desc = NULL;
-       if(timer == election_trigger) {
-               timer_desc = "Election Trigger";
-
-       } else if(timer == election_timeout) {
-               timer_desc = "Election Timeout";
-               
-       } else {
-               timer_desc = "Timer";
-       }
+       const char *timer_desc = get_timer_desc(timer);
 
-       if((timer->source_id == (guint)-1 || timer->source_id == (guint)-2)
-          && timer->period_ms > 0) {
+       if(timer->source_id == 0 && timer->period_ms > 0) {
                timer->source_id = Gmain_timeout_add(
                        timer->period_ms, timer->callback, (void*)timer);
-
+               CRM_ASSERT(timer->source_id != 0);
                crm_debug("Started %s (%s:%dms), src=%d",
                          timer_desc, fsa_input2string(timer->fsa_input),
                          timer->period_ms, timer->source_id);
@@ -179,37 +197,23 @@
 gboolean
 crm_timer_stop(fsa_timer_t *timer)
 {
-       const char *timer_desc = NULL;
-       if(timer == election_trigger) {
-               timer_desc = "Election Trigger";
-
-       } else if(timer == election_timeout) {
-               timer_desc = "Election Timeout";
-               
-       } else if(timer == wait_timer) {
-               timer_desc = "Stall Timeout";
-               
-       } else {
-               timer_desc = "Timer";
-       }
+       const char *timer_desc = get_timer_desc(timer);
 
        if(timer == NULL) {
                crm_err("Attempted to stop NULL timer");
                return FALSE;
                
-       } else if(timer->source_id != (guint)-1
-                 && timer->source_id != (guint)-2) {
+       } else if(timer->source_id != 0) {
                crm_debug("Stopping %s (%s:%dms), src=%d",
                          timer_desc, fsa_input2string(timer->fsa_input),
                          timer->period_ms, timer->source_id);
                Gmain_timeout_remove(timer->source_id);
-               timer->source_id = -2;
+               timer->source_id = 0;
                
        } else {
                crm_debug_2("%s (%s:%dms) already stopped",
                          timer_desc, fsa_input2string(timer->fsa_input),
                          timer->period_ms);
-               timer->source_id = -2;
                return FALSE;
        }
        return TRUE;




------------------------------

_______________________________________________
Linux-ha-cvs mailing list
[email protected]
http://lists.community.tummy.com/mailman/listinfo/linux-ha-cvs


End of Linux-ha-cvs Digest, Vol 24, Issue 61
********************************************

Reply via email to