File pacemaker-crm_mon-break-up-long-lines.patch of Package pacemaker.14737

commit ef19be9b02f97429f725ee031e81744c3b015480
Author: Ken Gaillot <kgaillot@redhat.com>
Date:   Fri Jun 24 16:43:09 2016 -0500

    Low: tools: break up long lines in crm_mon console output
    
    Fixed CLBZ#5291

diff --git a/tools/crm_mon.c b/tools/crm_mon.c
index 41763fd..d0d9d9a 100644
--- a/tools/crm_mon.c
+++ b/tools/crm_mon.c
@@ -2122,7 +2122,8 @@ print_cluster_times(FILE *stream, pe_working_set_t *data_set)
         case mon_output_plain:
         case mon_output_console:
             print_as("Last updated: %s", crm_now_string());
-            print_as("\t\tLast change: %s", last_written ? last_written : "");
+            print_as((user || client || origin)? "\n" : "\t\t");
+            print_as("Last change: %s", last_written ? last_written : "");
             if (user) {
                 print_as(" by %s", user);
             }
@@ -2280,23 +2281,32 @@ print_cluster_counts(FILE *stream, pe_working_set_t *data_set, const char *stack
         case mon_output_plain:
         case mon_output_console:
 
-            if (stack_s && strstr(stack_s, "classic openais") != NULL) {
-                print_as(", %s expected votes", quorum_votes);
-            }
-
             if(is_set(data_set->flags, pe_flag_maintenance_mode)) {
                 print_as("\n              *** Resource management is DISABLED ***");
                 print_as("\n  The cluster will not attempt to start, stop or recover services");
-                print_as("\n");
             }
 
-            print_as("\n%d node%s and %d resource%s configured",
-                     nnodes, s_if_plural(nnodes),
+            print_as("\n%d node%s configured", nnodes, s_if_plural(nnodes));
+            if (stack_s && strstr(stack_s, "classic openais") != NULL) {
+                print_as(" (%s expected votes)", quorum_votes);
+            }
+            print_as("\n");
+
+            print_as("\n%d resource%s configured",
                      nresources, s_if_plural(nresources));
             if(data_set->disabled_resources || data_set->blocked_resources) {
-                print_as(": %d resource%s DISABLED and %d BLOCKED from being started due to failures",
-                         data_set->disabled_resources, s_if_plural(data_set->disabled_resources),
-                         data_set->blocked_resources);
+                print_as(" (");
+                if (data_set->disabled_resources) {
+                    print_as("%d DISABLED", data_set->disabled_resources);
+                }
+                if (data_set->disabled_resources && data_set->blocked_resources) {
+                    print_as(", ");
+                }
+                if (data_set->blocked_resources) {
+                    print_as("%d BLOCKED from starting due to failure",
+                             data_set->blocked_resources);
+                }
+                print_as(")");
             }
             print_as("\n\n");
 
openSUSE Build Service is sponsored by