Bug 1242631 - Cancellation of node sync tasks not propagated to the agent/capsule
Summary: Cancellation of node sync tasks not propagated to the agent/capsule
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Satellite 6
Classification: Red Hat
Component: Pulp
Version: 6.0.0
Hardware: x86_64
OS: Linux
high
high vote
Target Milestone: Unspecified
Assignee: satellite6-bugs
QA Contact: Corey Welton
URL:
Whiteboard:
Depends On:
Blocks: sat61-release-notes
TreeView+ depends on / blocked
 
Reported: 2015-07-13 19:43 UTC by Brian Bouterse
Modified: 2019-08-15 04:52 UTC (History)
13 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2015-10-15 18:20:21 UTC


Attachments (Terms of Use)


Links
System ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2015:1911 normal SHIPPED_LIVE Satellite 6.1.3 bug fix update 2015-10-15 22:19:19 UTC
Pulp Redmine 1136 Normal CLOSED - CURRENTRELEASE Cancellation of node sync tasks not propagated to the agent/node. Never

Description Brian Bouterse 2015-07-13 19:43:19 UTC
Cancellation of node sync tasks is not propagated to the agent. As a result, the task on the parent has a state of canceled but continues to run on the agent/node. This means that Katello things the task was cancelled when it was not. It prevents new tasks to be run by the agent from being run until the previous task finishes normally. This can result in a backlog of agent requests and tasks on the node.

Comment 1 RHEL Product and Program Management 2015-07-13 19:44:09 UTC
Since this issue was entered in Red Hat Bugzilla, the release flag has been
set to ? to ensure that it is properly evaluated for this release.

Comment 3 pulp-infra@redhat.com 2015-07-13 20:00:17 UTC
The Pulp upstream bug status is at NEW. Updating the external tracker on this bug.

Comment 4 pulp-infra@redhat.com 2015-07-13 20:00:18 UTC
The Pulp upstream bug priority is at Normal. Updating the external tracker on this bug.

Comment 5 pulp-infra@redhat.com 2015-07-15 16:00:17 UTC
The Pulp upstream bug status is at ASSIGNED. Updating the external tracker on this bug.

Comment 6 pulp-infra@redhat.com 2015-07-16 16:00:16 UTC
The Pulp upstream bug status is at POST. Updating the external tracker on this bug.

Comment 7 David O'Brien 2015-08-19 02:33:28 UTC
Can I get some suitable text for a rel note for this?

thanks

Comment 8 David O'Brien 2015-08-21 13:13:36 UTC
Brad,
Can you help with rel note text? Need at least Issue and Workaround, Cause is optional, examples optional (but nice) :)

thanks

Comment 11 pulp-infra@redhat.com 2015-09-09 18:30:20 UTC
The Pulp upstream bug status is at MODIFIED. Updating the external tracker on this bug.

Comment 12 pulp-infra@redhat.com 2015-09-09 19:00:20 UTC
The Pulp upstream bug status is at ON_QA. Updating the external tracker on this bug.

Comment 13 pulp-infra@redhat.com 2015-09-11 20:00:20 UTC
The Pulp upstream bug status is at VERIFIED. Updating the external tracker on this bug.

Comment 14 pulp-infra@redhat.com 2015-09-11 20:30:21 UTC
The Pulp upstream bug status is at CLOSED - CURRENTRELEASE. Updating the external tracker on this bug.

Comment 18 Corey Welton 2015-10-05 20:42:37 UTC
In trying to cancel a capsule sync in Sat6 (by way of canceling the task, since there is no 'normal' way via UI/cli to do it), I get the following upon cancel:

Oct  5 16:37:53 rhsm-qe-3 goferd: [ERROR][worker-0] pulp_node.handlers.model:324 - Task [a321949c-3215-4a9c-a78e-589e16cc5124] cancellation failed http=200
Oct  5 16:37:53 rhsm-qe-3 pulp: celery.worker.control:INFO: Terminating a321949c-3215-4a9c-a78e-589e16cc5124 (15)
Oct  5 16:37:53 rhsm-qe-3 pulp: pulp_node.importers.strategies:ERROR: (16370-82688) Default_Organization-Library-cv_Capsule-Red_Hat_Enterprise_Linux_Server-Red_Hat_Enterprise_Linux_7_Server_RPMs_x86_64_7Server
Oct  5 16:37:53 rhsm-qe-3 pulp: pulp_node.importers.strategies:ERROR: (16370-82688) Traceback (most recent call last):
Oct  5 16:37:53 rhsm-qe-3 pulp: pulp_node.importers.strategies:ERROR: (16370-82688)   File "/usr/lib/python2.7/site-packages/pulp_node/importers/strategies.py", line 130, in synchronize
Oct  5 16:37:53 rhsm-qe-3 pulp: pulp_node.importers.strategies:ERROR: (16370-82688)     self._synchronize(request)
Oct  5 16:37:53 rhsm-qe-3 pulp: pulp_node.importers.strategies:ERROR: (16370-82688)   File "/usr/lib/python2.7/site-packages/pulp_node/importers/strategies.py", line 374, in _synchronize
Oct  5 16:37:53 rhsm-qe-3 pulp: pulp_node.importers.strategies:ERROR: (16370-82688)     unit_inventory = self._unit_inventory(request)
Oct  5 16:37:53 rhsm-qe-3 pulp: pulp_node.importers.strategies:ERROR: (16370-82688)   File "/usr/lib/python2.7/site-packages/pulp_node/importers/strategies.py", line 218, in _unit_inventory
Oct  5 16:37:53 rhsm-qe-3 pulp: pulp_node.importers.strategies:ERROR: (16370-82688)     inventory = UnitInventory(base_URL, parent_units, child_units)
Oct  5 16:37:53 rhsm-qe-3 pulp: pulp_node.importers.strategies:ERROR: (16370-82688)   File "/usr/lib/python2.7/site-packages/pulp_node/importers/inventory.py", line 76, in __init__
Oct  5 16:37:53 rhsm-qe-3 pulp: pulp_node.importers.strategies:ERROR: (16370-82688)     self.parent_units = self._import_parent_units(parent_units)
Oct  5 16:37:53 rhsm-qe-3 pulp: pulp_node.importers.strategies:ERROR: (16370-82688)   File "/usr/lib/python2.7/site-packages/pulp_node/importers/inventory.py", line 52, in _import_parent_units
Oct  5 16:37:53 rhsm-qe-3 pulp: pulp_node.importers.strategies:ERROR: (16370-82688)     for unit, ref in units:
Oct  5 16:37:53 rhsm-qe-3 pulp: pulp_node.importers.strategies:ERROR: (16370-82688)   File "/usr/lib/python2.7/site-packages/pulp_node/manifest.py", line 405, in next
Oct  5 16:37:53 rhsm-qe-3 pulp: pulp_node.importers.strategies:ERROR: (16370-82688)     return self.unit_generator.next()
Oct  5 16:37:53 rhsm-qe-3 pulp: pulp_node.importers.strategies:ERROR: (16370-82688)   File "/usr/lib/python2.7/site-packages/pulp_node/manifest.py", line 387, in get_units
Oct  5 16:37:53 rhsm-qe-3 pulp: pulp_node.importers.strategies:ERROR: (16370-82688)     unit = json.loads(json_unit)
Oct  5 16:37:53 rhsm-qe-3 pulp: pulp_node.importers.strategies:ERROR: (16370-82688)   File "/usr/lib64/python2.7/json/__init__.py", line 338, in loads
Oct  5 16:37:53 rhsm-qe-3 pulp: pulp_node.importers.strategies:ERROR: (16370-82688)     return _default_decoder.decode(s)
Oct  5 16:37:53 rhsm-qe-3 pulp: pulp_node.importers.strategies:ERROR: (16370-82688)   File "/usr/lib64/python2.7/json/decoder.py", line 365, in decode
Oct  5 16:37:53 rhsm-qe-3 pulp: pulp_node.importers.strategies:ERROR: (16370-82688)     obj, end = self.raw_decode(s, idx=_w(s, 0).end())
Oct  5 16:37:53 rhsm-qe-3 pulp: pulp_node.importers.strategies:ERROR: (16370-82688)   File "/usr/lib64/python2.7/json/decoder.py", line 381, in raw_decode
Oct  5 16:37:53 rhsm-qe-3 pulp: pulp_node.importers.strategies:ERROR: (16370-82688)     obj, end = self.scan_once(s, idx)
Oct  5 16:37:53 rhsm-qe-3 pulp: pulp_node.importers.strategies:ERROR: (16370-82688)   File "/usr/lib/python2.7/site-packages/pulp/server/async/tasks.py", line 478, in sigterm_handler
Oct  5 16:37:53 rhsm-qe-3 pulp: pulp_node.importers.strategies:ERROR: (16370-82688)     handler()
Oct  5 16:37:53 rhsm-qe-3 pulp: pulp_node.importers.strategies:ERROR: (16370-82688) TypeError: cancel_sync_repo() takes exactly 3 arguments (1 given)

Comment 19 Corey Welton 2015-10-05 20:43:07 UTC
submitted ^ too soon.  This is in the logs on the capsule.

Comment 20 Brian Bouterse 2015-10-05 20:53:29 UTC
The traceback above is a known issue related to cancellation. It has been fixed and has a commit which could be cherry picked also. The known upstream Pulp issue is:  https://pulp.plan.io/issues/1097

Comment 22 Corey Welton 2015-10-05 21:05:08 UTC
Verified on 6.1.3 2-Oct compose.  Traceback above does not have any net effect on cancellation and can be fixed at a later date.

Comment 24 errata-xmlrpc 2015-10-15 18:20:21 UTC
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-2015:1911


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