Bug 1473771 - hammer host package remove command hangs indefinitely when launched
Summary: hammer host package remove command hangs indefinitely when launched
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: Remote Execution
Version: 6.3.0
Hardware: x86_64
OS: Linux
unspecified
high
Target Milestone: Unspecified
Assignee: satellite6-bugs
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2017-07-21 15:07 UTC by Djebran Lezzoum
Modified: 2019-04-01 20:26 UTC (History)
5 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2017-08-22 13:54:45 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Comment 2 Shimon Shtein 2017-08-16 07:43:19 UTC
The behavior depends on a task: it shows the progress of the task. If the task runs for too long, it will appear as the command is hanging. Eventually it will stop, but it will take a long time.

Workaround: you can always press CTRL+C to stop the hammer command, the asynchronous task will continue running in the background.

Is it acceptable?

Comment 3 Djebran Lezzoum 2017-08-16 08:06:35 UTC
Hi Shimon,

As you said the process is taking too much time, but it's too much for removing a package, I can assume this behavior is affected by bug https://bugzilla.redhat.com/show_bug.cgi?id=1457977
but it should have a reasonable timeout to exit as other tasks do.

Any way we have fixed our automation to cancel such process when reaching a time limit (as the whole automation was hanging on that tests), but in a client environment it can appear annoying and not acceptable.

Comment 4 Shimon Shtein 2017-08-17 11:03:14 UTC
@dlezzoum Thanks for the quick reply, after digging a bit into the code I have fond the following things that could help here:

1. Content tasks have a timeout setting - look for content_action_finish_timeout setting in the Administer -> Settings UI section (it's called "Finish action timeout" in the content tab).
2. You can add --async in the hammer command to release the execution:

# hammer host package-group remove --help
Usage:
    hammer host package-group remove [OPTIONS]

Options:
 --async                       Do not wait for the task

Is it good enough?

Comment 5 Djebran Lezzoum 2017-08-17 16:31:52 UTC
Hi Shimon, many thanks for the explanation. 

Yes I think it's good enough.

Comment 6 Ivan Necas 2017-08-22 13:54:45 UTC
Based on comments, I'm closing as notabug


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