[ClusterLabs Developers] crmadmin

Gerry R Sommerville gerry at ca.ibm.com
Thu Feb 24 09:05:49 EST 2022


Hey Ken,

Thought so, thank you for confirming!

Gerry Sommerville
________________________________
From: Developers <developers-bounces at clusterlabs.org> on behalf of Ken Gaillot <kgaillot at redhat.com>
Sent: Wednesday, February 23, 2022 5:06 PM
To: developers at clusterlabs.org <developers at clusterlabs.org>
Subject: [EXTERNAL] Re: [ClusterLabs Developers] crmadmin

On Wed, 2022-02-23 at 21:26 +0000, Gerry R Sommerville wrote:
> Hey devs,
>
> I noticed there was a change in exit code from crmadmin --version
> from version 2.0.4 to 2.0.5, I run this command in a script which
> checks if [[ 0 -ne $? ]]; then .... which is how I noticed the
> change.
>
> In 2.0.4, crmadmin would exit with 0, while in 2.0.5 it will exit
> with 64. Ran this through gdb quick as well and here are the
> respective traces.

That was in fact a bug in 2.0.5, fixed in 2.1.0. The bug and fix were
both side effects of other changes, so it wasn't noticed until you did
:) and it wasn't in the ChangeLog.

>
> Pacemaker 2.0.4
> Thread 1 (Thread 0x7ffff7fc9b80 (LWP 3423363)):
> #0  0x00007ffff5190c20 in exit () from /lib64/libc.so.6
> #1  0x00007ffff70c00b4 in crm_exit (rc=rc at entry=CRM_EX_OK) at
> results.c:773
> #2  0x00007ffff70b63f6 in pcmk__cli_help (cmd=<optimized out>,
> exit_code=CRM_EX_OK) at options.c:263
> #3  0x0000555555556084 in main (argc=2, argv=0x7fffffffd738) at
> crmadmin.c:183
>
>
> Pacemaker 2.0.5
> Thread 1 (Thread 0x7ffff7fd6b80 (LWP 2880544)):
> #0  0x00007ffff5184c20 in exit () from /lib64/libc.so.6
> #1  0x00007ffff70be6e4 in crm_exit (rc=rc at entry=CRM_EX_USAGE) at
> results.c:781
> #2  0x00007ffff70aed96 in pcmk__cli_help (cmd=<optimized out>,
> exit_code=CRM_EX_USAGE) at options.c:264
> #3  0x00005555555563d5 in main (argc=2, argv=0x7fffffffe058) at
> crmadmin.c:426
>
> I am wondering if this change was intentional, or a bug introduced by
> some other change. I believe its a bug since crmadmin -h still exits
> with 0.
>
> Gerry Sommerville
> _______________________________________________
> Manage your subscription:
> https://lists.clusterlabs.org/mailman/listinfo/developers
>
> ClusterLabs home: https://www.clusterlabs.org/
--
Ken Gaillot <kgaillot at redhat.com>

_______________________________________________
Manage your subscription:
https://lists.clusterlabs.org/mailman/listinfo/developers

ClusterLabs home: https://www.clusterlabs.org/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.clusterlabs.org/pipermail/developers/attachments/20220224/0f84fdf1/attachment-0001.htm>


More information about the Developers mailing list