Bug 1632663

Summary: dump all cli failure msgs to stderr
Product: [Red Hat Storage] Red Hat Gluster Storage Reporter: Prasanna Kumar Kalever <prasanna.kalever>
Component: gluster-blockAssignee: Prasanna Kumar Kalever <prasanna.kalever>
Status: CLOSED ERRATA QA Contact: Neha Berry <nberry>
Severity: medium Docs Contact:
Priority: high    
Version: cns-3.10CC: bgoyal, hchiramm, jmulligan, kramdoss, madam, nberry, pkarampu, pprakash, prasanna.kalever, rhs-bugs, rtalur, sankarshan, vbellur, xiubli
Target Milestone: ---Keywords: ZStream
Target Release: OCS 3.11.1   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: gluster-block-0.2.1-30.el7rhgs Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2019-02-07 03:38:29 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:
Bug Depends On:    
Bug Blocks: 1641915, 1644154    

Description Prasanna Kumar Kalever 2018-09-25 10:39:04 UTC
Description of problem:

Right now, we dump everything to stdout :-(

On FAILURE dump reply.out to stderr
On SUCCESS dump reply.out to stdout

Comment 8 Prasanna Kumar Kalever 2018-11-19 07:11:09 UTC
# gluster-block create ... >file1.out 2>file2.err

file1.out should capture only stdout, while file file2.err should capture stderr

Basically, you need to simulate a Failure and a Success and see if the output msgs are dumped to stderr and stdout respectively.

Comment 9 Neha Berry 2018-11-21 09:37:45 UTC
(In reply to Prasanna Kumar Kalever from comment #8)
> # gluster-block create ... >file1.out 2>file2.err
> 
> file1.out should capture only stdout, while file file2.err should capture
> stderr
> 
> Basically, you need to simulate a Failure and a Success and see if the
> output msgs are dumped to stderr and stdout respectively.

Thanks for the steps Prasanna.

Is there a way to validate this from oc or heketi side or do we need to go inside the gluster pod and verify with gluster-block create?

Thanks,
Neha

Comment 10 Prasanna Kumar Kalever 2018-11-21 09:39:56 UTC
(In reply to Neha Berry from comment #9)
> (In reply to Prasanna Kumar Kalever from comment #8)
> > # gluster-block create ... >file1.out 2>file2.err
> > 
> > file1.out should capture only stdout, while file file2.err should capture
> > stderr
> > 
> > Basically, you need to simulate a Failure and a Success and see if the
> > output msgs are dumped to stderr and stdout respectively.
> 
> Thanks for the steps Prasanna.
> 
> Is there a way to validate this from oc or heketi side or do we need to go
> inside the gluster pod and verify with gluster-block create?

AFAIK, we have a way straight way to validate this in oc/heketi. Worth checking with cns-team though. Thanks!

> 
> Thanks,
> Neha

Comment 12 Neha Berry 2018-11-21 10:39:02 UTC
(In reply to Prasanna Kumar Kalever from comment #10)
> (In reply to Neha Berry from comment #9)
> > (In reply to Prasanna Kumar Kalever from comment #8)
> > > # gluster-block create ... >file1.out 2>file2.err
> > > 
> > > file1.out should capture only stdout, while file file2.err should capture
> > > stderr
> > > 
> > > Basically, you need to simulate a Failure and a Success and see if the
> > > output msgs are dumped to stderr and stdout respectively.
> > 
> > Thanks for the steps Prasanna.
> > 
> > Is there a way to validate this from oc or heketi side or do we need to go
> > inside the gluster pod and verify with gluster-block create?
> 
> AFAIK, we have a way straight way to validate this in oc/heketi. Worth
> checking with cns-team though. Thanks!
> 
> > 
> > Thanks,
> > Neha

Putting a needinfo on Humble and Talur. 

The steps are verified in gluster pod and works as expected.

Comment 15 Michael Adam 2018-11-28 13:46:39 UTC
Answering in place of John/Talur/Humble, since we just discussed it:
In order to verify this bug, you don't need to look at heketi, just test the gluster-block cli directly.

After this fix, the consumer (heketi) can be improved (which is already done in the upstream). But not the concern of this BZ.

Comment 24 errata-xmlrpc 2019-02-07 03:38:29 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2019:0285