Bug 1260790

Summary: RFE: adjustable format strings for node IDs logging
Product: Red Hat Enterprise Linux 7 Reporter: Jaroslav Kortus <jkortus>
Component: corosyncAssignee: Jan Friesse <jfriesse>
Status: CLOSED UPSTREAM QA Contact: cluster-qe <cluster-qe>
Severity: low Docs Contact:
Priority: medium    
Version: 7.3CC: ccaulfie, cluster-maint
Target Milestone: rcKeywords: FutureFeature
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Enhancement
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2019-07-02 08:55:48 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Jaroslav Kortus 2015-09-07 19:15:04 UTC
Description of problem:
Sep  2 19:20:57 virt-009 corosync[3150]: [TOTEM ] A new membership (10.34.71.9:140) was formed. Members joined: 2 4294967295
Sep  2 19:20:57 virt-009 corosync[3150]: [QUORUM] This node is within the primary component and will provide service.
Sep  2 19:20:57 virt-009 corosync[3150]: [QUORUM] Members[3]: 1 2 -1

Note the -1 in the output instead of the big ID. In our discussion Honza suggested filing this RFE and ask for making the output adjustable (%u, %d, %x).

Version-Release number of selected component (if applicable):
corosync-2.3.4-7.el7.x86_64

How reproducible:
always

Steps to Reproduce:
1. set large node ids in corosync.conf
2. start corosync cluster
3.

Actual results:
-1 in output for big IDs

Expected results:
output as per user request (%u, %d or %x).

Additional info:

Comment 2 Jan Friesse 2015-09-08 07:25:00 UTC
Just as reminder, main reasonable for this bug is to walk thru source code of corosync/tools and replace nodeid output modifier with macro, so it will be evident WHAT is nodeid.

It may also make sense to consider moving nodeid to defined type instead of int (type may be macro, so no real change, but makes clear distinction what is nodeid).

Comment 9 Jan Friesse 2019-07-02 08:55:48 UTC
PR for corosync master branch can be found as a https://github.com/corosync/corosync/pull/491. Implemented is only compile-time part, because runtime change turned out to be way over.

I'm closing this bug for RHEL 7, because change is quite massive and potentially risky, but it should get into RHEL 8 with next rebase.