Re: [Pacemaker] crm_mon and pingd

2010-11-11 Thread Keisuke MORI
No objections.

I've push the changeset below:
http://hg.clusterlabs.org/pacemaker/stable-1.0/rev/53132ed532ea

But it would be still preferable to rely on -A, particularly if you
want to use two or more pingd resources or change the attribute name.

I'd also agree for the filtering feature as an enhancement.

Thanks,

2010/11/10 Andrew Beekhof and...@beekhof.net:
 Any objections Mori-san?
 Seems like a reasonable change to me.

 On Tue, Nov 9, 2010 at 1:26 PM, Vadym Chepkov vchep...@gmail.com wrote:

 Would it be too much harm to restore the previous behavior at least 
 partially?

 diff -r 7f2e453eedfa -r ab2da8a98b47 tools/crm_mon.c
 --- a/tools/crm_mon.c   Mon Nov 08 23:13:17 2010 +0100
 +++ b/tools/crm_mon.c   Tue Nov 09 07:18:53 2010 -0500
 @@ -748,6 +748,17 @@
    g_list_free(sorted_op_list);
  }

 +static void get_ping_score(node_t *node, pe_working_set_t *data_set)
 +{
 +    const char *attr = pingd;
 +    const char *value = NULL;
 +    value = g_hash_table_lookup(node-details-attrs, attr);
 +
 +    if(value != NULL) {
 +       print_as( %s=%s, attr, value);
 +    }
 +}
 +
  static void print_attr_msg(node_t *node, GListPtr rsc_list, const
 char *attrname, const char *attrvalue)
  {
    slist_iter(rsc, resource_t, rsc_list, lpc2,
 @@ -848,6 +859,9 @@
       }

       print_as(* Node %s: , crm_element_value(node_state, XML_ATTR_UNAME));
 +       if(!print_nodes_attr) {
 +               get_ping_score(node, data_set);
 +       }
       print_as(\n);

       lrm_rsc = find_xml_node(node_state, XML_CIB_TAG_LRM, FALSE);

 Thanks,
 Vadym

 ___
 Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
 http://oss.clusterlabs.org/mailman/listinfo/pacemaker

 Project Home: http://www.clusterlabs.org
 Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
 Bugs: 
 http://developerbugs.linux-foundation.org/enter_bug.cgi?product=Pacemaker


 ___
 Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
 http://oss.clusterlabs.org/mailman/listinfo/pacemaker

 Project Home: http://www.clusterlabs.org
 Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
 Bugs: 
 http://developerbugs.linux-foundation.org/enter_bug.cgi?product=Pacemaker




-- 
Keisuke MORI

___
Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
http://oss.clusterlabs.org/mailman/listinfo/pacemaker

Project Home: http://www.clusterlabs.org
Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
Bugs: http://developerbugs.linux-foundation.org/enter_bug.cgi?product=Pacemaker


Re: [Pacemaker] crm_mon and pingd

2010-11-09 Thread Andrew Beekhof
On Fri, Nov 5, 2010 at 6:39 PM, Vadym Chepkov vchep...@gmail.com wrote:

 On Nov 5, 2010, at 1:29 PM, Keisuke MORI wrote:

 Hi Vadym,

 Could you provide the output of 'cibadmin -Q' to see what's happening
 over there?

 Thanks,

 As Yuusuke IIDA pointed out this is a new and expected behavior of crm_mon.
 To be honest I don't excited about it, since -A flag fills screen with 
 master-drbd scores and not just pingd.

hmmm
maybe we need some user configurable filter. eg.
   crm_mon -A ping

___
Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
http://oss.clusterlabs.org/mailman/listinfo/pacemaker

Project Home: http://www.clusterlabs.org
Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
Bugs: http://developerbugs.linux-foundation.org/enter_bug.cgi?product=Pacemaker


Re: [Pacemaker] crm_mon and pingd

2010-11-09 Thread Vadym Chepkov
On Tue, Nov 9, 2010 at 3:30 AM, Andrew Beekhof and...@beekhof.net wrote:
 On Fri, Nov 5, 2010 at 6:39 PM, Vadym Chepkov vchep...@gmail.com wrote:

 On Nov 5, 2010, at 1:29 PM, Keisuke MORI wrote:

 Hi Vadym,

 Could you provide the output of 'cibadmin -Q' to see what's happening
 over there?

 Thanks,

 As Yuusuke IIDA pointed out this is a new and expected behavior of crm_mon.
 To be honest I don't excited about it, since -A flag fills screen with 
 master-drbd scores and not just pingd.

 hmmm
 maybe we need some user configurable filter. eg.
   crm_mon -A ping


Would it be too much harm to restore the previous behavior at least partially?

diff -r 7f2e453eedfa -r ab2da8a98b47 tools/crm_mon.c
--- a/tools/crm_mon.c   Mon Nov 08 23:13:17 2010 +0100
+++ b/tools/crm_mon.c   Tue Nov 09 07:18:53 2010 -0500
@@ -748,6 +748,17 @@
g_list_free(sorted_op_list);
 }

+static void get_ping_score(node_t *node, pe_working_set_t *data_set)
+{
+const char *attr = pingd;
+const char *value = NULL;
+value = g_hash_table_lookup(node-details-attrs, attr);
+
+if(value != NULL) {
+   print_as( %s=%s, attr, value);
+}
+}
+
 static void print_attr_msg(node_t *node, GListPtr rsc_list, const
char *attrname, const char *attrvalue)
 {
slist_iter(rsc, resource_t, rsc_list, lpc2,
@@ -848,6 +859,9 @@
   }

   print_as(* Node %s: , crm_element_value(node_state, XML_ATTR_UNAME));
+   if(!print_nodes_attr) {
+   get_ping_score(node, data_set);
+   }
   print_as(\n);

   lrm_rsc = find_xml_node(node_state, XML_CIB_TAG_LRM, FALSE);

Thanks,
Vadym

___
Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
http://oss.clusterlabs.org/mailman/listinfo/pacemaker

Project Home: http://www.clusterlabs.org
Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
Bugs: http://developerbugs.linux-foundation.org/enter_bug.cgi?product=Pacemaker


Re: [Pacemaker] crm_mon and pingd

2010-11-09 Thread Andrew Beekhof
Any objections Mori-san?
Seems like a reasonable change to me.

On Tue, Nov 9, 2010 at 1:26 PM, Vadym Chepkov vchep...@gmail.com wrote:

 Would it be too much harm to restore the previous behavior at least partially?

 diff -r 7f2e453eedfa -r ab2da8a98b47 tools/crm_mon.c
 --- a/tools/crm_mon.c   Mon Nov 08 23:13:17 2010 +0100
 +++ b/tools/crm_mon.c   Tue Nov 09 07:18:53 2010 -0500
 @@ -748,6 +748,17 @@
    g_list_free(sorted_op_list);
  }

 +static void get_ping_score(node_t *node, pe_working_set_t *data_set)
 +{
 +    const char *attr = pingd;
 +    const char *value = NULL;
 +    value = g_hash_table_lookup(node-details-attrs, attr);
 +
 +    if(value != NULL) {
 +       print_as( %s=%s, attr, value);
 +    }
 +}
 +
  static void print_attr_msg(node_t *node, GListPtr rsc_list, const
 char *attrname, const char *attrvalue)
  {
    slist_iter(rsc, resource_t, rsc_list, lpc2,
 @@ -848,6 +859,9 @@
       }

       print_as(* Node %s: , crm_element_value(node_state, XML_ATTR_UNAME));
 +       if(!print_nodes_attr) {
 +               get_ping_score(node, data_set);
 +       }
       print_as(\n);

       lrm_rsc = find_xml_node(node_state, XML_CIB_TAG_LRM, FALSE);

 Thanks,
 Vadym

 ___
 Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
 http://oss.clusterlabs.org/mailman/listinfo/pacemaker

 Project Home: http://www.clusterlabs.org
 Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
 Bugs: 
 http://developerbugs.linux-foundation.org/enter_bug.cgi?product=Pacemaker


___
Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
http://oss.clusterlabs.org/mailman/listinfo/pacemaker

Project Home: http://www.clusterlabs.org
Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
Bugs: http://developerbugs.linux-foundation.org/enter_bug.cgi?product=Pacemaker


Re: [Pacemaker] crm_mon and pingd

2010-11-05 Thread Keisuke MORI
Hi Vadym,

Could you provide the output of 'cibadmin -Q' to see what's happening
over there?

Thanks,

2010/11/4 Vadym Chepkov vchep...@gmail.com:
 Hi,

 It seems this patch in pacemaker doesn't work as expected

 changeset:   15672:4d50adc3ccd9
 branch:      stable-1.0
 user:        Andrew Beekhof and...@beekhof.net
 date:        Mon May 10 10:26:50 2010 +0200
 summary:     Medium: tools: crm_mon - Enable 'connectivity' mode for 'ping' 
 resources too

 crm_mon doesn't show pingd attribute value in Migration summary: anymore.

 Version: 1.0.9-0a40fd0cb9f2fcedef9d1967115c912314c57438

 Thanks,
 Vadym


 ___
 Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
 http://oss.clusterlabs.org/mailman/listinfo/pacemaker

 Project Home: http://www.clusterlabs.org
 Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
 Bugs: 
 http://developerbugs.linux-foundation.org/enter_bug.cgi?product=Pacemaker




-- 
Keisuke MORI

___
Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
http://oss.clusterlabs.org/mailman/listinfo/pacemaker

Project Home: http://www.clusterlabs.org
Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
Bugs: http://developerbugs.linux-foundation.org/enter_bug.cgi?product=Pacemaker


Re: [Pacemaker] crm_mon and pingd

2010-11-05 Thread Vadym Chepkov

On Nov 5, 2010, at 1:29 PM, Keisuke MORI wrote:

 Hi Vadym,
 
 Could you provide the output of 'cibadmin -Q' to see what's happening
 over there?
 
 Thanks,

As Yuusuke IIDA pointed out this is a new and expected behavior of crm_mon.
To be honest I don't excited about it, since -A flag fills screen with 
master-drbd scores and not just pingd.

Vadym

 
 2010/11/4 Vadym Chepkov vchep...@gmail.com:
 Hi,
 
 It seems this patch in pacemaker doesn't work as expected
 
 changeset:   15672:4d50adc3ccd9
 branch:  stable-1.0
 user:Andrew Beekhof and...@beekhof.net
 date:Mon May 10 10:26:50 2010 +0200
 summary: Medium: tools: crm_mon - Enable 'connectivity' mode for 'ping' 
 resources too
 
 crm_mon doesn't show pingd attribute value in Migration summary: anymore.
 
 Version: 1.0.9-0a40fd0cb9f2fcedef9d1967115c912314c57438
 
 Thanks,
 Vadym
 
 
 ___
 Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
 http://oss.clusterlabs.org/mailman/listinfo/pacemaker
 
 Project Home: http://www.clusterlabs.org
 Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
 Bugs: 
 http://developerbugs.linux-foundation.org/enter_bug.cgi?product=Pacemaker
 
 
 
 
 -- 
 Keisuke MORI
 
 ___
 Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
 http://oss.clusterlabs.org/mailman/listinfo/pacemaker
 
 Project Home: http://www.clusterlabs.org
 Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
 Bugs: 
 http://developerbugs.linux-foundation.org/enter_bug.cgi?product=Pacemaker


___
Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
http://oss.clusterlabs.org/mailman/listinfo/pacemaker

Project Home: http://www.clusterlabs.org
Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
Bugs: http://developerbugs.linux-foundation.org/enter_bug.cgi?product=Pacemaker


Re: [Pacemaker] crm_mon and pingd

2010-11-05 Thread Vladislav Bogdanov
05.11.2010 19:39, Vadym Chepkov wrote:
...
 As Yuusuke IIDA pointed out this is a new and expected behavior of crm_mon.
 To be honest I don't excited about it, since -A flag fills screen with 
 master-drbd scores and not just pingd.

watch crm_mon -1A|grep -E \^(\* Node|\+ ping)\ ?

___
Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
http://oss.clusterlabs.org/mailman/listinfo/pacemaker

Project Home: http://www.clusterlabs.org
Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
Bugs: http://developerbugs.linux-foundation.org/enter_bug.cgi?product=Pacemaker


Re: [Pacemaker] crm_mon and pingd

2010-11-05 Thread Vadym Chepkov

On Nov 5, 2010, at 2:36 PM, Vladislav Bogdanov wrote:

 05.11.2010 19:39, Vadym Chepkov wrote:
 ...
 As Yuusuke IIDA pointed out this is a new and expected behavior of crm_mon.
 To be honest I don't excited about it, since -A flag fills screen with 
 master-drbd scores and not just pingd.
 
 watch crm_mon -1A|grep -E \^(\* Node|\+ ping)\ ?

I can see how it's better then crm_mon -f 
:)


___
Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
http://oss.clusterlabs.org/mailman/listinfo/pacemaker

Project Home: http://www.clusterlabs.org
Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
Bugs: http://developerbugs.linux-foundation.org/enter_bug.cgi?product=Pacemaker


[Pacemaker] crm_mon and pingd

2010-11-04 Thread Vadym Chepkov
Hi,

It seems this patch in pacemaker doesn't work as expected

changeset:   15672:4d50adc3ccd9
branch:  stable-1.0
user:Andrew Beekhof and...@beekhof.net
date:Mon May 10 10:26:50 2010 +0200
summary: Medium: tools: crm_mon - Enable 'connectivity' mode for 'ping' 
resources too

crm_mon doesn't show pingd attribute value in Migration summary: anymore.

Version: 1.0.9-0a40fd0cb9f2fcedef9d1967115c912314c57438

Thanks,
Vadym


___
Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
http://oss.clusterlabs.org/mailman/listinfo/pacemaker

Project Home: http://www.clusterlabs.org
Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
Bugs: http://developerbugs.linux-foundation.org/enter_bug.cgi?product=Pacemaker


Re: [Pacemaker] crm_mon and pingd

2010-11-04 Thread Yuusuke IIDA

Hi, Vadym

I can confirm the attribute information of the current node with a crm_mon -A 
option.


http://hg.clusterlabs.org/pacemaker/stable-1.0/rev/e674c1977128
I came to display all the attribute information of the node by this change.
Therefore the score indication function of pingd deleted it for redundancy from 
Migration Summary.


Best Regards,
Yuusuke IIDA

(2010/11/04 19:22), Vadym Chepkov wrote:

Hi,

It seems this patch in pacemaker doesn't work as expected

changeset:   15672:4d50adc3ccd9
branch:  stable-1.0
user:Andrew Beekhofand...@beekhof.net
date:Mon May 10 10:26:50 2010 +0200
summary: Medium: tools: crm_mon - Enable 'connectivity' mode for 'ping' 
resources too

crm_mon doesn't show pingd attribute value in Migration summary: anymore.

Version: 1.0.9-0a40fd0cb9f2fcedef9d1967115c912314c57438

Thanks,
Vadym


___
Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
http://oss.clusterlabs.org/mailman/listinfo/pacemaker

Project Home: http://www.clusterlabs.org
Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
Bugs: http://developerbugs.linux-foundation.org/enter_bug.cgi?product=Pacemaker



--

METRO SYSTEMS CO., LTD

YuusukeIida
Mail: iiday...@intellilink.co.jp


___
Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
http://oss.clusterlabs.org/mailman/listinfo/pacemaker

Project Home: http://www.clusterlabs.org
Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
Bugs: http://developerbugs.linux-foundation.org/enter_bug.cgi?product=Pacemaker