Bug 996012 - targetcli: Traceback when grep its output
targetcli: Traceback when grep its output
Status: CLOSED WONTFIX
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: python-configshell (Show other bugs)
6.5
Unspecified Unspecified
medium Severity medium
: rc
: ---
Assigned To: Maurizio Lombardi
Bruno Goncalves
:
Depends On:
Blocks: 1061157
  Show dependency treegraph
 
Reported: 2013-08-12 04:27 EDT by Bruno Goncalves
Modified: 2017-12-06 07:08 EST (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of:
: 1061157 (view as bug list)
Environment:
Last Closed: 2017-12-06 07:08:20 EST
Type: Bug
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 Bruno Goncalves 2013-08-12 04:27:30 EDT
Description of problem:
Some targetcli commands generate traceback when "grepping" its output.

Version-Release number of selected component (if applicable):
rpm -q fcoe-target-utils
fcoe-target-utils-2.0rc1.fb16-3.el6.noarch 

How reproducible:
100%

Steps to Reproduce:
# targetcli /tcm_f ls
No such path /tcm_f

# targetcli /tcm_f ls | grep "tcm"
Traceback (most recent call last):
File "/usr/bin/targetcli", line 91, in <module>
main()
File "/usr/bin/targetcli", line 74, in main
shell.run_cmdline(" ".join(sys.argv[1:]))
File "/usr/lib/python2.6/site-packages/configshell/shell.py", line 934,
in run_cmdline
self._execute_command(path, command, pparams, kparams)
File "/usr/lib/python2.6/site-packages/configshell/shell.py", line 899,
in _execute_command
self.log.error(msg)
File "/usr/lib/python2.6/site-packages/configshell/log.py", line 159, in
error
self._log('error', msg)
File "/usr/lib/python2.6/site-packages/configshell/log.py", line 112, in
_log
self.con.display(msg)
File "/usr/lib/python2.6/site-packages/configshell/console.py", line
151, in display
self.raw_write(text)
File "/usr/lib/python2.6/site-packages/configshell/console.py", line
139, in raw_write
self._stdout.write(text)
TypeError: argument 1 must be string or read-only character buffer, not
exceptions.ValueError


# targetcli /tcm_fc/20:00:00:1b:21:59:12:37/luns create
/backstores/fileio/fcoe_lun
lun for storage object /backstores/fileio/fcoe_lun already exists

# targetcli /tcm_fc/20:00:00:1b:21:59:12:37/luns create
/backstores/fileio/fcoe_lun | grep ""
Traceback (most recent call last):
File "/usr/bin/targetcli", line 91, in <module>
main()
File "/usr/bin/targetcli", line 74, in main
shell.run_cmdline(" ".join(sys.argv[1:]))
File "/usr/lib/python2.6/site-packages/configshell/shell.py", line 934,
in run_cmdline
self._execute_command(path, command, pparams, kparams)
File "/usr/lib/python2.6/site-packages/configshell/shell.py", line 909,
in _execute_command
result = target.execute_command(command, pparams, kparams)
File "/usr/lib/python2.6/site-packages/targetcli/ui_node.py", line 84,
in execute_command
pparams, kparams)
File "/usr/lib/python2.6/site-packages/configshell/node.py", line 1407,
in execute_command
self.shell.log.error(msg)
File "/usr/lib/python2.6/site-packages/configshell/log.py", line 159, in
error
self._log('error', msg)
File "/usr/lib/python2.6/site-packages/configshell/log.py", line 112, in
_log
self.con.display(msg)
File "/usr/lib/python2.6/site-packages/configshell/console.py", line
151, in display
self.raw_write(text)
File "/usr/lib/python2.6/site-packages/configshell/console.py", line
139, in raw_write
self._stdout.write(text)
TypeError: argument 1 must be string or read-only character buffer, not
ExecutionError

------
In this case no traceback is generated.

# targetcli /tcm_fc/20:00:00:1b:21:59:12:37/acls create
10:00:00:00:c9:e6:61:d5
This NodeACL already exists in configFS.

# targetcli /tcm_fc/20:00:00:1b:21:59:12:37/acls create
10:00:00:00:c9:e6:61:d5 | grep ""
This NodeACL already exists in configFS.
Comment 1 RHEL Product and Program Management 2013-08-19 21:10:08 EDT
This request was evaluated by Red Hat Product Management for
inclusion in a Red Hat Enterprise Linux release.  Product
Management has requested further review of this request by
Red Hat Engineering, for potential inclusion in a Red Hat
Enterprise Linux release for currently deployed products.
This request is not yet committed for inclusion in a release.
Comment 5 Jan Kurik 2017-12-06 07:08:20 EST
Red Hat Enterprise Linux 6 is in the Production 3 Phase. During the Production 3 Phase, Critical impact Security Advisories (RHSAs) and selected Urgent Priority Bug Fix Advisories (RHBAs) may be released as they become available.

The official life cycle policy can be reviewed here:

http://redhat.com/rhel/lifecycle

This issue does not meet the inclusion criteria for the Production 3 Phase and will be marked as CLOSED/WONTFIX. If this remains a critical requirement, please contact Red Hat Customer Support to request a re-evaluation of the issue, citing a clear business justification. Note that a strong business justification will be required for re-evaluation. Red Hat Customer Support can be contacted via the Red Hat Customer Portal at the following URL:

https://access.redhat.com/

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