Bug 1506237
Summary: | foreman-tasks-delete always failed showing Invalid State | ||
---|---|---|---|
Product: | Red Hat Satellite | Reporter: | Nikhil Kathole <nkathole> |
Component: | Satellite Maintain | Assignee: | Kavita <kgaikwad> |
Status: | CLOSED ERRATA | QA Contact: | Nikhil Kathole <nkathole> |
Severity: | medium | Docs Contact: | |
Priority: | unspecified | ||
Version: | 6.3.0 | CC: | apatel, bbuckingham, inecas, kgaikwad, mmccune, sthirugn |
Target Milestone: | Unspecified | Keywords: | Triaged |
Target Release: | Unused | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | If docs needed, set a value | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2018-04-04 14:02:54 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: | |||
Bug Depends On: | |||
Bug Blocks: | 1496794 |
Description
Nikhil Kathole
2017-10-25 13:17:45 UTC
Created redmine issue http://projects.theforeman.org/issues/21472 from this bug Moving this bug to POST for triage into Satellite 6 since the upstream issue http://projects.theforeman.org/issues/21472 has been resolved. Attached upstream ticket is not fully serving the purpose of BZ. Using foreman-tasks-delete procedure, we are only deleting below foreman-tasks: 1. Having state - planning/pending and 2. paused/stopped tasks which are older than 30 days. Here, expected possible values are old, planning or pending for --state option. Attaching a upstream bug - http://projects.theforeman.org/issues/21974 and modifying status of this BZ ticket. Updated outdated Target Milestone. Closing this since this is not a relevant issue. We do not try to delete paused tasks, we just try to resume them. So, run `foreman-tasks-delete --state paused` should never be run. The only valid values are 'old', 'planning' or 'pending'. With PR ( https://github.com/theforeman/foreman_maintain/pull/132 ) foreman-maintain would validate values passed to --state option and won't throw an error. Moved to ON_QA as per Anurag's email that this is present from rubygem-foreman_maintain-0.1.4 onwards. VERIFIED # rpm -qa | grep maintain rubygem-foreman_maintain-0.1.5-1.el7sat.noarch # foreman-maintain advanced procedure run foreman-tasks-delete --state paused 'paused' not allowed for state param. Possible values are old, planning, pending # foreman-maintain advanced procedure run foreman-tasks-delete --state old Running ForemanMaintain::Scenario ================================================================================ Delete tasks: / Deleting old task [OK] -------------------------------------------------------------------------------- # foreman-maintain advanced procedure run foreman-tasks-delete --state planning Running ForemanMaintain::Scenario ================================================================================ Delete tasks: / Deleting planning task [OK] -------------------------------------------------------------------------------- # foreman-maintain advanced procedure run foreman-tasks-delete --state pending Running ForemanMaintain::Scenario ================================================================================ Delete tasks: / Deleting pending task [OK] -------------------------------------------------------------------------------- Error gets properly handled and foreman-tasks-delete procedure working fine with possible values old, planning and pending. 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-2018:0633 |