Bug 1351535

Summary: Need error logging on volume create failures
Product: [Red Hat Storage] Red Hat Gluster Storage Reporter: Anoop <annair>
Component: heketiAssignee: Mohamed Ashiq <mliyazud>
Status: CLOSED ERRATA QA Contact: Prasanth <pprakash>
Severity: high Docs Contact:
Priority: unspecified    
Version: rhgs-3.1CC: annair, hchiramm, madam, mliyazud, pprakash, rcyriac, rreddy
Target Milestone: ---Keywords: Reopened, ZStream
Target Release: CNS 3.4   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2017-01-18 21:55:44 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: 1385246    

Description Anoop 2016-06-30 09:19:03 UTC
If the volume create fails due to some reason, there is no logging of the error message and neither do I see any meaniful error on the console to figure out what really wnt wrong. See below:

[root@dhcp42-41 ~]# heketi-cli volume create --size=10 --persistent-volume-file=pv001.json
Error: 

docker logs on teh cotainer too have nothing useful to debug:
[negroni] Completed 200 OK in 208.298µs
[negroni] Started GET /clusters/0f8e46ce836ef0cc66da14fc5aa92ac4
[negroni] Completed 200 OK in 413.617µs
[negroni] Started GET /volumes/a7d8b934a572163c1995aa003c736a60
[negroni] Completed 200 OK in 1.804691ms
[negroni] Started GET /nodes/3aaac28bba4c47fa18da478fc75b1eea
[negroni] Completed 200 OK in 588.055µs
[negroni] Started GET /nodes/5202eb162964a814f02395669abf59c0
[negroni] Completed 200 OK in 483.038µs
[negroni] Started GET /nodes/ed72981275e1fd8664b4f3b20db75ec2
[negroni] Completed 200 OK in 460.901µs
[negroni] Started GET /clusters
[negroni] Completed 200 OK in 163.369µs
[negroni] Started GET /clusters/0f8e46ce836ef0cc66da14fc5aa92ac4
[negroni] Completed 200 OK in 280.523µs
[negroni] Started GET /volumes/a7d8b934a572163c1995aa003c736a60
[negroni] Completed 200 OK in 947.963µs
[negroni] Started GET /nodes/3aaac28bba4c47fa18da478fc75b1eea
[negroni] Completed 200 OK in 711.588µs
[negroni] Started GET /nodes/5202eb162964a814f02395669abf59c0
[negroni] Completed 200 OK in 636.589µs
[negroni] Started GET /nodes/ed72981275e1fd8664b4f3b20db75ec2
[negroni] Completed 200 OK in 662.538µs

Comment 2 Luis Pabón 2016-07-06 16:20:03 UTC
The errors are definitely logged, I am not sure why they are not showing up.

The error "Error: " is definitely bad, and is probably due to the same issue as BZ1350636

*** This bug has been marked as a duplicate of bug 1350636 ***

Comment 3 Anoop 2016-07-07 06:53:28 UTC
This is the original bug, mark 1350636 as duplicate of this bug.

Comment 4 Luis Pabón 2016-07-07 11:39:00 UTC
*** Bug 1350636 has been marked as a duplicate of this bug. ***

Comment 6 Luis Pabón 2016-10-05 21:32:46 UTC
Is this still an issue?  Could you please reproduce?

Comment 7 Michael Adam 2016-10-19 16:19:44 UTC
according to the upstream issues this has meanwhile been fixed:

https://github.com/heketi/heketi/issues/394

https://github.com/heketi/heketi/issues/412

Comment 13 Prasanth 2016-11-24 11:06:14 UTC
I've tested this against the latest heketi build (heketi-3.1.0-3.el7rhgs.x86_64) and noticed that heketi server still doesn't log proper error message on any volume create failures. See below:

######
{"log":"[negroni] Started POST /volumes\n","stream":"stdout","time":"2016-11-24T11:04:11.642199782Z"}
{"log":"[negroni] Completed 400 Bad Request in 215.879µs\n","stream":"stdout","time":"2016-11-24T11:04:11.642272341Z"}
#######

Hence, moving it back to Assigned.

PS: heketi-cli seems to correctly print the proper error message to stdout now. But the same should be logged in the server logs as well.

Comment 14 Mohamed Ashiq 2016-12-06 07:43:52 UTC
Patch Upstream under review:

https://github.com/heketi/heketi/pull/610

Comment 15 Mohamed Ashiq 2016-12-07 11:43:42 UTC
(In reply to Mohamed Ashiq from comment #14)
> Patch Upstream under review:
> 
> https://github.com/heketi/heketi/pull/610

merged upstream.

Comment 18 Prasanth 2016-12-27 08:00:24 UTC
Verified as fixed in the latest heketi build

Comment 20 errata-xmlrpc 2017-01-18 21:55:44 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://rhn.redhat.com/errata/RHEA-2017-0148.html