Bug 1569666 - targetcli crashes when creating a block-based backstore
Summary: targetcli crashes when creating a block-based backstore
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: targetcli
Version: 28
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Andy Grover
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2018-04-19 18:01 UTC by Scott Mayhew
Modified: 2018-05-23 15:58 UTC (History)
1 user (show)

Fixed In Version: targetcli-2.1.fb48-4.fc28 targetcli-2.1.fb48-4.fc27
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2018-05-23 15:38:42 UTC
Type: Bug


Attachments (Terms of Use)

Description Scott Mayhew 2018-04-19 18:01:01 UTC
Description of problem:
targetcli crashes when creating a block-based backstore.

Version-Release number of selected component (if applicable):
targetcli-2.1.fb48-3.fc28.noarch

How reproducible:
easy

Steps to Reproduce:
/> cd backstores/block
/backstores/block> create block_backend1 /dev/sdb


Actual results:

Traceback (most recent call last):
  File "/usr/bin/targetcli", line 122, in <module>
    main()
  File "/usr/bin/targetcli", line 112, in main
    shell.run_interactive()
  File "/usr/lib/python3.6/site-packages/configshell_fb/shell.py", line 905, in run_interactive
    self._cli_loop()
  File "/usr/lib/python3.6/site-packages/configshell_fb/shell.py", line 734, in _cli_loop
    self.run_cmdline(cmdline)
  File "/usr/lib/python3.6/site-packages/configshell_fb/shell.py", line 848, in run_cmdline
    self._execute_command(path, command, pparams, kparams)
  File "/usr/lib/python3.6/site-packages/configshell_fb/shell.py", line 823, in _execute_command
    result = target.execute_command(command, pparams, kparams)
  File "/usr/lib/python3.6/site-packages/configshell_fb/node.py", line 1406, in execute_command
    return method(*pparams, **kparams)
  File "/usr/lib/python3.6/site-packages/targetcli/ui_backstore.py", line 561, in ui_command_create
    readonly = self._ui_block_ro_check(dev)
  File "/usr/lib/python3.6/site-packages/targetcli/ui_backstore.py", line 539, in _ui_block_ro_check
    buf = array.array('c', [chr(0)] * 4)
ValueError: bad typecode (must be b, B, u, h, H, i, I, l, L, q, Q, f or d)


Expected results:

/backstores/block> create block_backend1 /dev/sdb
Created block storage object block_backend1 using /dev/sdb.

Additional info:

Fixed by
https://github.com/open-iscsi/targetcli-fb/commit/ed5ff9b9505e50b545e86dfbdd32077f0ddda0cb?diff=unified

Comment 1 Fedora Update System 2018-05-08 18:27:28 UTC
targetcli-2.1.fb48-4.fc27 has been submitted as an update to Fedora 27. https://bodhi.fedoraproject.org/updates/FEDORA-2018-ec416ac4f1

Comment 2 Fedora Update System 2018-05-08 18:27:35 UTC
targetcli-2.1.fb48-4.fc28 has been submitted as an update to Fedora 28. https://bodhi.fedoraproject.org/updates/FEDORA-2018-b8908dc20e

Comment 3 Fedora Update System 2018-05-09 23:30:59 UTC
targetcli-2.1.fb48-4.fc27 has been pushed to the Fedora 27 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2018-ec416ac4f1

Comment 4 Fedora Update System 2018-05-10 01:29:32 UTC
targetcli-2.1.fb48-4.fc28 has been pushed to the Fedora 28 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2018-b8908dc20e

Comment 5 Fedora Update System 2018-05-23 15:38:42 UTC
targetcli-2.1.fb48-4.fc28 has been pushed to the Fedora 28 stable repository. If problems still persist, please make note of it in this bug report.

Comment 6 Fedora Update System 2018-05-23 15:58:25 UTC
targetcli-2.1.fb48-4.fc27 has been pushed to the Fedora 27 stable repository. If problems still persist, please make note of it in this bug report.


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