Bug 1179811

Summary: pulp-admin tasks details --task-id=$ID reports no operation and no resources for certains sync tasks
Product: Red Hat Satellite Reporter: Jindrich Novy <jindrich.novy>
Component: PulpAssignee: satellite6-bugs <satellite6-bugs>
Status: CLOSED CURRENTRELEASE QA Contact: Katello QA List <katello-qa-list>
Severity: high Docs Contact:
Priority: unspecified    
Version: 6.0.6CC: bkearney, chrobert, jindrich.novy, jsherril, mhrivnak
Target Milestone: Unspecified   
Target Release: Unused   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
: 1180677 (view as bug list) Environment:
Last Closed: 2015-12-11 16:54:55 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: 1120671, 1180677    
Bug Blocks:    

Description Jindrich Novy 2015-01-07 15:26:11 UTC
Description of problem:
I'm monitoring progress of tasks on pulp level to track progress of sync/publish/associate tasks by parsing output of:

pulp-admin tasks details --task-id=$ID

A sane task has all fields complete except progress report, e.g.:

pulp-admin tasks details --task-id=e1abc554-7643-4fa6-b5ae-05ddbecb0abc
+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
                                                                                                             Task Details
+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+

Operations:       publish
Resources:        MorganStanley-Red_Hat_Enterprise_Linux_Server_-_Extended_Update_Support-Red_Hat_Enterprise_Linux_6_Server_-_Extended_Update_Support_-_RH_Common_RPMs_x86_64_6Server (repository)
State:            Waiting
Start Time:       Unstarted
Finish Time:      Incomplete
Result:           Incomplete
Task Id:          e1abc554-7643-4fa6-b5ae-05ddbecb0abc
Progress Report:

Some sync tasks on the other hand have incomplete fields:

pulp-admin tasks details --task-id=48592c77-7667-4bb9-baf4-d464833b74bb
+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
                                                                                                             Task Details
+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+

Operations:
Resources:
State:            Running
Start Time:       2015-01-07T14:55:01Z
Finish Time:      Incomplete
Result:           Incomplete
Task Id:          48592c77-7667-4bb9-baf4-d464833b74bb
Progress Report:
  Yum Importer:
    Comps:
      State: NOT_STARTED
    Content:
      Details:
        Drpm Done:  0
        Drpm Total: 0
        Rpm Done:   2433
        Rpm Total:  14297
      Error Details:
      Items Left:    11864
      Items Total:   14297
      Size Left:     23364210920
      Size Total:    25316532188
      State:         IN_PROGRESS
    Distribution:
      Error Details:
      Items Left:    0
      Items Total:   0
      State:         NOT_STARTED
    Errata:
      State: NOT_STARTED
    Metadata:
      State: FINISHED

Version-Release number of selected component (if applicable):
6.0.6

How reproducible:
Trigger an initial sync for all Red Hat repositories for newly created organization.

Steps to Reproduce:
1. set up a Satellite server, import manifest, enable RH repositories
2. trigger sync
3. note tasks with unknown Operation/Resources

Actual results:
No Resources/Operations field present for some sync tasks.

Expected results:
Resources/Operations field non-empty so that I know what is actually going on in the task.


Additional info:

Comment 1 RHEL Program Management 2015-01-07 15:54:31 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 Bryan Kearney 2015-01-09 16:29:04 UTC
Cloned to pulp community, and moved the release to 6.2.

Comment 4 Michael Hrivnak 2015-01-14 03:33:48 UTC
Are you able to reproduce this behavior only when the sync has been scheduled as part of a sync plan, or does it also happen when you induce a manual one-time sync?

Comment 5 Jindrich Novy 2015-01-15 16:41:49 UTC
I'm able to always reproduce it if I trigger sync manually on freshly installed Satellite (no previous syncs were made). I trigger the first sync explicitly via:

for REPOID in $(hammer --csv repository list --organization=$ORG  | awk -F, {'print $1'} | grep -vi '^ID'); do
        hammer repository synchronize --id $REPOID --organization=$ORG --async
done

and then I'm having a look at the tasks being executed.

Comment 6 Justin Sherrill 2015-01-22 21:15:00 UTC
Jindrich,

Testing this out myself with Satellite 6, I am not able to reproduce with a single repo sync.  I've tried a few different ones and have not been able to see this behavior.  In all cases the operation and resource are filed in.

Couple of questions:

1.  Is the satellite running on el6 or el7?
2.  Is it happening for all repositories? or just some?
3.  Can you determine which repo or repos are having this problem if it is not all of them?  If you could provide the name and label of:

 * the organization
 * the product
 * the repo

for one of the repos you are seeing this occur on, it would help greatly.

-Justin

Comment 7 Jindrich Novy 2015-01-26 17:20:32 UTC
Important note - we are using "stateless build" of Satellite so we rebuild the box and install the new Satellite from scratch and the auto-configure it via hammer. The symptoms of unknown Operation and Resources shows up only when doing the first synchronization. Subsequent syncs don't show this. It seems to happen for all repositories.

We are running EL6 Satellite.

Comment 8 Chris Roberts 2015-01-30 01:51:18 UTC
*** Bug 1180259 has been marked as a duplicate of this bug. ***

Comment 10 Bryan Kearney 2015-12-11 16:54:55 UTC
We believe this is fixed in Satellite 6.1. I am closing this out as current release. If you are still seeing issue, please feel free to re-open and provide the symptoms you are seeing.