Bug 666991 - standard error code for usage issues should be 2
standard error code for usage issues should be 2
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: lvm2-cluster (Show other bugs)
5.6
All All
low Severity low
: rc
: ---
Assigned To: Milan Broz
Cluster QE
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2011-01-03 19:16 EST by Corey Marthaler
Modified: 2013-02-28 23:10 EST (History)
12 users (show)

See Also:
Fixed In Version: lvm2-cluster-2.02.84-2.el5
Doc Type: Bug Fix
Doc Text:
This field is the basis of the errata or release note for this bug. It can also be used for change logs. The Technical Note template, known as CCFR, is as follows: Cause What actions or circumstances cause this bug to present. Consequence What happens when the bug presents. Fix What was done to fix the bug. Result What now happens when the actions or circumstances above occur. Note: this is not the same as the bug doesn’t present anymore.
Story Points: ---
Clone Of:
Environment:
Last Closed: 2011-07-21 03:03:44 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Corey Marthaler 2011-01-03 19:16:41 EST
Description of problem:
[root@taft-04 ~]# clvmd -s
Usage:
clvmd [Vhd]

   -V       Show version of clvmd
   -h       Show this help information
   -d       Set debug level
            If starting clvmd then don't fork, run in the foreground
   -R       Tell all running clvmds in the cluster to reload their device cache
   -S       Restart clvmd, preserving exclusive locks
   -C       Sets debug level (from -d) on all clvmd instances clusterwide
   -t<secs> Command timeout (default 60 seconds)
   -T<secs> Startup timeout (default none)
   -I<cmgr> Cluster manager (default: auto)
            Available cluster managers: cman
[root@taft-04 ~]# echo $?
0

Version-Release number of selected component (if applicable):
lvm2-2.02.74-5.el5    BUILT: Wed Dec  8 08:12:31 CST 2010
lvm2-cluster-2.02.74-3.el5    BUILT: Tue Nov  9 08:01:59 CST 2010
Comment 1 Alasdair Kergon 2011-01-04 07:00:19 EST
Well it shouldn't return success in that example!

Need to review all exit points from the code for appropriate status code, make changes where necessary and then document all the ones used in the clvmd man page.
Comment 2 Alasdair Kergon 2011-01-04 07:42:54 EST
The value 4 added for non-root invocation clashes with a different existing use: the existing one needs to be changed (regression).
Comment 3 RHEL Product and Program Management 2011-01-11 15:25:35 EST
This request was evaluated by Red Hat Product Management for
inclusion in the current release of Red Hat Enterprise Linux.
Because the affected component is not scheduled to be updated in the
current release, Red Hat is unfortunately unable to address this
request at this time. Red Hat invites you to ask your support
representative to propose this request, if appropriate and relevant,
in the next release of Red Hat Enterprise Linux.
Comment 4 RHEL Product and Program Management 2011-01-11 18:05:47 EST
This request was erroneously denied for the current release of
Red Hat Enterprise Linux.  The error has been fixed and this
request has been re-proposed for the current release.
Comment 6 Milan Broz 2011-03-08 08:28:43 EST
In 2.02.85 upstream.
Comment 7 Milan Broz 2011-03-23 08:18:40 EDT
Fixed in
lvm2-cluster-2.02.84-2.el5
Comment 9 Corey Marthaler 2011-05-11 11:43:27 EDT
Fix verified in in the latest rpms.

[root@taft-01 ~]# clvmd -s
Usage: clvmd [options]
   -V       Show version of clvmd
   -h       Show this help information
   -d[n]    Set debug logging (0:none, 1:stderr (implies -f option), 2:syslog)
   -f       Don't fork, run in the foreground
   -R       Tell all running clvmds in the cluster to reload their device cache
   -S       Restart clvmd, preserving exclusive locks
   -C       Sets debug level (from -d) on all clvmd instances clusterwide
   -t<secs> Command timeout (default 60 seconds)
   -T<secs> Startup timeout (default none)
   -I<cmgr> Cluster manager (default: auto)
            Available cluster managers: cman
[root@taft-01 ~]# echo $?
2

2.6.18-256.el5

lvm2-2.02.84-2.el5    BUILT: Wed Mar 23 07:18:08 CDT 2011
lvm2-cluster-2.02.84-2.el5    BUILT: Wed Mar 23 07:19:43 CDT 2011
device-mapper-1.02.63-2.el5    BUILT: Fri Mar  4 10:23:17 CST 2011
device-mapper-event-1.02.63-2.el5    BUILT: Fri Mar  4 10:23:17 CST 2011
cmirror-1.1.39-10.el5    BUILT: Wed Sep  8 16:32:05 CDT 2010
kmod-cmirror-0.1.22-3.el5    BUILT: Tue Dec 22 13:39:47 CST 2009
Comment 11 Florian Nadge 2011-05-26 10:50:45 EDT
    Technical note added. If any revisions are required, please edit the "Technical Notes" field
    accordingly. All revisions will be proofread by the Engineering Content Services team.
    
    New Contents:
This field is the basis of the errata or release note for this bug. It can also be used for change logs.

The Technical Note template, known as CCFR, is as follows:

Cause
    What actions or circumstances cause this bug to present.
Consequence
    What happens when the bug presents.
Fix
    What was done to fix the bug.
Result
    What now happens when the actions or circumstances above occur.
    Note: this is not the same as the bug doesn’t present anymore.
Comment 12 errata-xmlrpc 2011-07-21 03:03:44 EDT
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2011-0986.html

Note You need to log in before you can comment on or make changes to this bug.