Bug 1021314 - Syncing repository with distribution to a node places distribution in the wrong directory
Syncing repository with distribution to a node places distribution in the wro...
Status: CLOSED CURRENTRELEASE
Product: Red Hat Satellite 6
Classification: Red Hat
Component: Content Management (Show other bugs)
6.0.2
Unspecified Unspecified
urgent Severity high (vote)
: Unspecified
: --
Assigned To: Mike McCune
Corey Welton
: Triaged
Depends On: 1020549
Blocks:
  Show dependency treegraph
 
Reported: 2013-10-20 23:40 EDT by Mike McCune
Modified: 2014-09-11 08:23 EDT (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: 1020549
Environment:
Last Closed: 2014-09-11 08:23:56 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Mike McCune 2013-10-20 23:40:39 EDT
+++ This bug was initially created as a clone of Bug #1020549 +++

Description of problem:

When you sync a repo down to a pulp node that has a distribution, it appears to put the distribution files in the wrong directory.

Here is the layout on the pulp server:


[root@qe-blade-09 ~]# tree /var/lib/pulp/content/distribution/ks-Red\ Hat\ Enterprise\ Linux-Server-6.4-x86_64/
/var/lib/pulp/content/distribution/ks-Red Hat Enterprise Linux-Server-6.4-x86_64/
├── images
│   ├── boot.iso
│   ├── efiboot.img
│   ├── efidisk.img
│   ├── install.img
│   ├── product.img
│   └── pxeboot
│       ├── initrd.img
│       └── vmlinuz
└── treeinfo



And here it is on the pulp node:

[root@cloud-qe-2 ks-Red Hat Satellite-Tools-6.0.2-x86_64]# tree /var/lib/pulp/content/distribution/ks-Red\ Hat\ Enterprise\ Linux-Server-6.4-x86_64/
/var/lib/pulp/content/distribution/ks-Red Hat Enterprise Linux-Server-6.4-x86_64/
└── ks-Red Hat Enterprise Linux-Server-6.4-x86_64
    ├── images
    │   ├── boot.iso
    │   ├── efiboot.img
    │   ├── efidisk.img
    │   ├── install.img
    │   ├── product.img
    │   └── pxeboot
    │       ├── initrd.img
    │       └── vmlinuz
    └── treeinfo


As you will notice, the node puts all the files within an additional subdirectory 
/var/lib/pulp/content/distribution/ks-Red Hat Enterprise Linux-Server-6.4-x86_64/ks-Red Hat Enterprise Linux-Server-6.4-x86_64


While this syncs fine, it causes the repository publish to fail on the node:


2013-10-17 16:22:26,549 pulp.server.managers.repo.publish:INFO: publish failed for repo [Katello_Infrastructure-Dev_Env-rhel6_published-Red_Hat_Enterprise_Linux_Server-Red_Hat_Enterprise_Linux_6_Server_RPMs_x86_64_6Server] with distributor ID [Katello_Infrastructure-Dev_Env-rhel6_published-Red_Hat_Enterprise_Linux_Server-Red_Hat_Enterprise_Linux_6_Server_RPMs_x86_64_6Server]


Here's the output from the task:



{ "_id" : ObjectId("52604702e6fc26788400494e"), "exception" : null, "repo_id" : "Katello_Infrastructure-Dev_Env-rhel6_published-Red_Hat_Enterprise_Linux_Server-Red_Hat_Enterprise_Linux_6_Server_RPMs_x86_64_6Server", "traceback" : null, "started" : "2013-10-17T16:20:40-04:00", "_ns" : "repo_publish_results", "completed" : "2013-10-17T16:22:26-04:00", "error_message" : null, "distributor_type_id" : "yum_distributor", "distributor_id" : "Katello_Infrastructure-Dev_Env-rhel6_published-Red_Hat_Enterprise_Linux_Server-Red_Hat_Enterprise_Linux_6_Server_RPMs_x86_64_6Server", "summary" : { "num_package_units_errors" : 0, "https_publish_dir" : "/var/lib/pulp/published/https/repos/Katello_Infrastructure/Dev_Env/rhel6_published/content/dist/rhel/server/6/6Server/x86_64/os", "num_package_categories_published" : 0, "num_distribution_units_errors" : 7, "skip_metadata_update" : false, "num_distribution_units_published" : -6, "num_package_groups_published" : 202, "num_package_units_attempted" : 11029, "num_package_units_published" : 11029, "num_distribution_units_attempted" : 1, "relative_path" : "Katello_Infrastructure/Dev_Env/rhel6_published/content/dist/rhel/server/6/6Server/x86_64/os" }, "result" : "failed", "id" : "52604702e6fc26788400494e", "details" : { "errors" : [ 	[ 	"/var/lib/pulp/content/distribution/ks-Red Hat Enterprise Linux-Server-6.4-x86_64/images/efiboot.img", 	"/var/lib/pulp/working/repos/Katello_Infrastructure-Dev_Env-rhel6_published-Red_Hat_Enterprise_Linux_Server-Red_Hat_Enterprise_Linux_6_Server_RPMs_x86_64_6Server/distributors/yum_distributor/images/efiboot.img", 	"Source path: /var/lib/pulp/content/distribution/ks-Red Hat Enterprise Linux-Server-6.4-x86_64/images/efiboot.img is missing" ], 	[ 	"/var/lib/pulp/content/distribution/ks-Red Hat Enterprise Linux-Server-6.4-x86_64/images/pxeboot/vmlinuz", 	"/var/lib/pulp/working/repos/Katello_Infrastructure-Dev_Env-rhel6_published-Red_Hat_Enterprise_Linux_Server-Red_Hat_Enterprise_Linux_6_Server_RPMs_x86_64_6Server/distributors/yum_distributor/images/pxeboot/vmlinuz", 	"Source path: /var/lib/pulp/content/distribution/ks-Red Hat Enterprise Linux-Server-6.4-x86_64/images/pxeboot/vmlinuz is missing" ], 	[ 	"/var/lib/pulp/content/distribution/ks-Red Hat Enterprise Linux-Server-6.4-x86_64/images/efidisk.img", 	"/var/lib/pulp/working/repos/Katello_Infrastructure-Dev_Env-rhel6_published-Red_Hat_Enterprise_Linux_Server-Red_Hat_Enterprise_Linux_6_Server_RPMs_x86_64_6Server/distributors/yum_distributor/images/efidisk.img", 	"Source path: /var/lib/pulp/content/distribution/ks-Red Hat Enterprise Linux-Server-6.4-x86_64/images/efidisk.img is missing" ], 	[ 	"/var/lib/pulp/content/distribution/ks-Red Hat Enterprise Linux-Server-6.4-x86_64/images/product.img", 	"/var/lib/pulp/working/repos/Katello_Infrastructure-Dev_Env-rhel6_published-Red_Hat_Enterprise_Linux_Server-Red_Hat_Enterprise_Linux_6_Server_RPMs_x86_64_6Server/distributors/yum_distributor/images/product.img", 	"Source path: /var/lib/pulp/content/distribution/ks-Red Hat Enterprise Linux-Server-6.4-x86_64/images/product.img is missing" ], 	[ 	"/var/lib/pulp/content/distribution/ks-Red Hat Enterprise Linux-Server-6.4-x86_64/images/install.img", 	"/var/lib/pulp/working/repos/Katello_Infrastructure-Dev_Env-rhel6_published-Red_Hat_Enterprise_Linux_Server-Red_Hat_Enterprise_Linux_6_Server_RPMs_x86_64_6Server/distributors/yum_distributor/images/install.img", 	"Source path: /var/lib/pulp/content/distribution/ks-Red Hat Enterprise Linux-Server-6.4-x86_64/images/install.img is missing" ], 	[ 	"/var/lib/pulp/content/distribution/ks-Red Hat Enterprise Linux-Server-6.4-x86_64/images/pxeboot/initrd.img", 	"/var/lib/pulp/working/repos/Katello_Infrastructure-Dev_Env-rhel6_published-Red_Hat_Enterprise_Linux_Server-Red_Hat_Enterprise_Linux_6_Server_RPMs_x86_64_6Server/distributors/yum_distributor/images/pxeboot/initrd.img", 	"Source path: /var/lib/pulp/content/distribution/ks-Red Hat Enterprise Linux-Server-6.4-x86_64/images/pxeboot/initrd.img is missing" ], 	[ 	"/var/lib/pulp/content/distribution/ks-Red Hat Enterprise Linux-Server-6.4-x86_64/images/boot.iso", 	"/var/lib/pulp/working/repos/Katello_Infrastructure-Dev_Env-rhel6_published-Red_Hat_Enterprise_Linux_Server-Red_Hat_Enterprise_Linux_6_Server_RPMs_x86_64_6Server/distributors/yum_distributor/images/boot.iso", 	"Source path: /var/lib/pulp/content/distribution/ks-Red Hat Enterprise Linux-Server-6.4-x86_64/images/boot.iso is missing" ] ], "time_metadata_sec" : 102.79039597511292 } }



Version-Release number of selected component (if applicable):
pulp-server-2.3.0-0.22.beta.el6sat.noarch

How reproducible:
Always

Steps to Reproduce:
1. Sync a repository to a pulp server that contains a distribution
2. Setup a pulp node pointing to that pulp server
3. Bind the pulp node to the repo synced in 1
4. Attempt to 'sync' the node

Actual results:
repo is synced, distribution is not in the same directory as it is on the master pulp server, repo publish fails

Expected results:
Repo publish runs successfully
Comment 1 Mike McCune 2013-10-20 23:41:29 EDT
Justin,

Just giving this to you to track
Comment 2 Mike McCune 2013-10-20 23:41:55 EDT
ignore previous comment.  this is a clone to track the upstream pulp bug
Comment 5 Mike McCune 2013-10-23 19:38:18 EDT
https://bugzilla.redhat.com/show_bug.cgi?id=1020549#c3

 Jeff Ortel 2013-10-23 19:27:12 EDT

build: 2.3.0-0.24.beta
Comment 8 Corey Welton 2014-08-13 17:13:16 EDT
This is essentially verified in Satellite-6.0.4-RHEL-6-20140806.0, but capsule sync is broken out of the box. With appropriate fixes, sync works and I can get the proper tree format.  However, I will not mark this verified until snap arrives that fixes bug #1129835
Comment 9 Corey Welton 2014-08-27 20:34:12 EDT
Verified in Satellite-6.0.4-RHEL-6-20140823.0
Comment 10 Bryan Kearney 2014-09-11 08:23:56 EDT
This was delivered with Satellite 6.0 which was released on 10 September 2014.

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