Note: This bug is displayed in read-only format because
the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
DescriptionCorey Marthaler
2019-03-07 23:29:13 UTC
Description of problem:
[root@hayes-01 ~]# stratis fs create my_pool2 my_fs62
^C^C^C^C^C^CTraceback (most recent call last):
File "/usr/bin/stratis", line 33, in <module>
main()
File "/usr/bin/stratis", line 29, in main
return run()(sys.argv[1:])
File "/usr/lib/python3.6/site-packages/stratis_cli/_main.py", line 48, in the_func
result.func(result)
File "/usr/lib/python3.6/site-packages/stratis_cli/_actions/_logical.py", line 57, in create_volumes
get_object(pool_object_path), {'specs': namespace.fs_name})
File "/usr/lib/python3.6/site-packages/dbus_python_client_gen/_invokers.py", line 304, in dbus_func
return dbus_method(*xformed_args, timeout=timeout)
File "/usr/lib64/python3.6/site-packages/dbus/proxies.py", line 145, in __call__
**keywords)
File "/usr/lib64/python3.6/site-packages/dbus/connection.py", line 651, in call_blocking
message, timeout)
KeyboardInterrupt
[root@hayes-01 ~]# stratis fs list | grep 62
my_pool2 my_fs62 545 MiB Mar 07 2019 17:23 /stratis/my_pool2/my_fs62 81f6309be63b4a698f87b114ee021f29
Version-Release number of selected component (if applicable):
stratisd-1.0.3-1.el8.x86_64
stratis-cli-1.0.2-1.el8.noarch
How reproducible:
Everytime
Conflicting with this is the concern to ignore the keyboard interrupt while a call is being
made across the D-Bus. This is, of course, exactly the time when a user is most likely to
hit Ctrl-C. And, the CLI itself is not doing tricky stuff that should not be interrupted,
unless it's in the middle of marshalling a call on the D-Bus. So, I favor just allowing
the exception to be raised and then catching it.
Like this:
[mulhern@localhost ~/stratis2/stratis-cli (master-keyboard-interrupt)]$ PYTHONPATH=./src ./bin/stratis --version; echo $?
^CReceived KeyboardInterrupt
1
Does the above look good, or do you consider the bare exit code preferable?
> [mulhern@localhost ~/stratis2/stratis-cli (master-keyboard-interrupt)]$
> PYTHONPATH=./src ./bin/stratis --version; echo $?
> ^CReceived KeyboardInterrupt
> 1
>
> Does the above look good, or do you consider the bare exit code preferable?
Above looks fine to me.
stratis-cli-1.0.4-2.el8.noarch
# stratis pool create interrupt /dev/sdb
^CReceived KeyboardInterrupt
# echo $?
1
Interrupting is now correctly caught and no longer results in traceback.
Note: The command itself gets probably interrupted when the call across D-Bus has been made resulting in the request actually being completed some time after:
# stratis pool
Name Total Physical Size Total Physical Used
interrupt 9.10 TiB 9.35 GiB
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:3414
Description of problem: [root@hayes-01 ~]# stratis fs create my_pool2 my_fs62 ^C^C^C^C^C^CTraceback (most recent call last): File "/usr/bin/stratis", line 33, in <module> main() File "/usr/bin/stratis", line 29, in main return run()(sys.argv[1:]) File "/usr/lib/python3.6/site-packages/stratis_cli/_main.py", line 48, in the_func result.func(result) File "/usr/lib/python3.6/site-packages/stratis_cli/_actions/_logical.py", line 57, in create_volumes get_object(pool_object_path), {'specs': namespace.fs_name}) File "/usr/lib/python3.6/site-packages/dbus_python_client_gen/_invokers.py", line 304, in dbus_func return dbus_method(*xformed_args, timeout=timeout) File "/usr/lib64/python3.6/site-packages/dbus/proxies.py", line 145, in __call__ **keywords) File "/usr/lib64/python3.6/site-packages/dbus/connection.py", line 651, in call_blocking message, timeout) KeyboardInterrupt [root@hayes-01 ~]# stratis fs list | grep 62 my_pool2 my_fs62 545 MiB Mar 07 2019 17:23 /stratis/my_pool2/my_fs62 81f6309be63b4a698f87b114ee021f29 Version-Release number of selected component (if applicable): stratisd-1.0.3-1.el8.x86_64 stratis-cli-1.0.2-1.el8.noarch How reproducible: Everytime