Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
This project is now read‑only. Starting Monday, February 2, please use Jira Cloud for all bug tracking management.

Bug 1495533

Summary: [ceph-iscsi-cli]: JSON error seen when trying to delete a host entry
Product: [Red Hat Storage] Red Hat Ceph Storage Reporter: Tejas <tchandra>
Component: iSCSIAssignee: Paul Cuzner <pcuzner>
Status: CLOSED ERRATA QA Contact: Tejas <tchandra>
Severity: low Docs Contact:
Priority: unspecified    
Version: 3.0CC: ceph-eng-bugs, ceph-qe-bugs, jdillama
Target Milestone: rc   
Target Release: 3.0   
Hardware: Unspecified   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2017-12-05 23:45:31 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 Tejas 2017-09-26 09:17:11 UTC
Description of problem:
      I was trying to delete a host entry in gwcli. Saw this JSON error when I accidentally entered without a iqn.
This failure should be handled gracefully.

/iscsi-target...eph-igw/hosts> delete client_iqn=
CMD: ../hosts/ delete 
Client DELETE for 
Traceback (most recent call last):
  File "/usr/bin/gwcli", line 187, in <module>
    main()
  File "/usr/bin/gwcli", line 119, in main
    shell.run_interactive()
  File "/usr/lib/python2.7/site-packages/configshell_fb/shell.py", line 905, in run_interactive
    self._cli_loop()
  File "/usr/lib/python2.7/site-packages/configshell_fb/shell.py", line 734, in _cli_loop
    self.run_cmdline(cmdline)
  File "/usr/lib/python2.7/site-packages/configshell_fb/shell.py", line 848, in run_cmdline
    self._execute_command(path, command, pparams, kparams)
  File "/usr/lib/python2.7/site-packages/configshell_fb/shell.py", line 823, in _execute_command
    result = target.execute_command(command, pparams, kparams)
  File "/usr/lib/python2.7/site-packages/configshell_fb/node.py", line 1406, in execute_command
    return method(*pparams, **kparams)
  File "/usr/lib/python2.7/site-packages/gwcli/client.py", line 130, in ui_command_delete
    error_message = api.response.json()['message']
  File "/usr/lib/python2.7/site-packages/requests/models.py", line 802, in json
    return json.loads(self.text, **kwargs)
  File "/usr/lib64/python2.7/json/__init__.py", line 338, in loads
    return _default_decoder.decode(s)
  File "/usr/lib64/python2.7/json/decoder.py", line 366, in decode
    obj, end = self.raw_decode(s, idx=_w(s, 0).end())
  File "/usr/lib64/python2.7/json/decoder.py", line 384, in raw_decode
    raise ValueError("No JSON object could be decoded")
ValueError: No JSON object could be decoded




2017-09-26 14:28:20,251     INFO [_internal.py:87:_log()] - 127.0.0.1 - - [26/Sep/2017 14:28:20] "GET /api/config HTTP/1.1" 200 -
2017-09-26 14:28:20,292     INFO [_internal.py:87:_log()] - 10.70.39.2 - - [26/Sep/2017 14:28:20] "GET /api/_ping HTTP/1.1" 200 -
2017-09-26 14:28:20,304     INFO [_internal.py:87:_log()] - 10.70.39.2 - - [26/Sep/2017 14:28:20] "GET /api/_ping HTTP/1.1" 200 -
2017-09-26 14:28:30,304     INFO [_internal.py:87:_log()] - 10.70.39.2 - - [26/Sep/2017 14:28:30] "GET /api/_ping HTTP/1.1" 200 -
2017-09-26 14:28:35,614     INFO [_internal.py:87:_log()] - 127.0.0.1 - - [26/Sep/2017 14:28:35] "DELETE /api/client/ HTTP/1.1" 404 -

Version-Release number of selected component (if applicable):
ceph-iscsi-config-2.3-8.el7cp.noarch
ceph-iscsi-cli-2.5-7.el7cp.noarch

Comment 4 Tejas 2017-09-28 11:16:40 UTC
Verified in ceph-iscsi-cli-2.5-8.el7cp.noarch

Comment 7 errata-xmlrpc 2017-12-05 23:45:31 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-2017:3387