Bug 501024 - rhn-satellite-exporter: Incremental export doesn't work
Summary: rhn-satellite-exporter: Incremental export doesn't work
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Satellite 5
Classification: Red Hat
Component: Satellite Synchronization
Version: 530
Hardware: All
OS: Linux
medium
high
Target Milestone: ---
Assignee: Jan Pazdziora (Red Hat)
QA Contact: Šimon Lukašík
URL:
Whiteboard:
Depends On:
Blocks: sat-channel-dumps
TreeView+ depends on / blocked
 
Reported: 2009-05-15 14:46 UTC by Michael Mráka
Modified: 2018-10-30 18:57 UTC (History)
8 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2010-03-22 12:04:48 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
channel_families.xml.gz from step 4. (335 bytes, application/xml)
2009-05-15 14:48 UTC, Michael Mráka
no flags Details
channel_families.xml.gz from step 7. (396 bytes, application/xml)
2009-05-18 08:44 UTC, Michael Mráka
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2010:0160 0 normal SHIPPED_LIVE Red Hat Network Satellite bug fix update 2010-03-22 12:04:28 UTC

Description Michael Mráka 2009-05-15 14:46:53 UTC
Description of problem:
Export of channel to directory which already contains export of another (group of) channels may break satellite-sync. This kind of incremental export should work.

Version-Release number of selected component (if applicable):
spacewalk-backend-tools-0.5.28-13.el4sat


How reproducible:
always

Steps to Reproduce:
1. install 2 satellites, sat1 registered to webqa, sa2 disconnected
   make sure you have entitlements for rhel-i386-server-5 and rhel-i386-server-5.0.z on both satellites
as root@sat1:
2. sync rhel-i386-server-5 and rhel-i386-server-5.0.z channel from webqa
3. rhn-satellite-exporter -c rhel-i386-server-5 -d /shared/dir
4. rhn-satellite-exporter -c rhel-i386-server-5.0.z -d /shared/dir
as root@sat2:
5. satelilte-sync -c rhel-i386-server-5 -d /shared/dir
6. satelilte-sync -c rhel-i386-server-5.0.z -d /shared/dir
as root@sat1:
7. rhn-satellite-exporter -c rhel-i386-server-5 -d /shared/dir
as root@sat2:
8. satelilte-sync -c rhel-i386-server-5 -d /shared/dir
9. satelilte-sync -c rhel-i386-server-5.0.z -d /shared/dir
  
Actual results:
1.- 4. ok
5. ...
ERROR: you are not entitled to sync a channel in this set of channels.
Please contact your sales rep or RHN contact
rhel-i386-server-5
6. ok (rhel-i386-server-5.0.z synced)
7. ok
8. ok (this time rhel-i386-server-5 synced)
9. ...
ERROR: you are not entitled to sync a channel in this set of channels.
Please contact your sales rep or RHN contact
rhel-i386-server-5.0.z


Expected results:
both channels synced ok everytime

Additional info:
see channel_families.xml.gz

Comment 1 Michael Mráka 2009-05-15 14:48:08 UTC
Created attachment 344167 [details]
channel_families.xml.gz from step 4.

Comment 2 Michael Mráka 2009-05-18 08:44:54 UTC
Created attachment 344397 [details]
channel_families.xml.gz from step 7.

Comment 3 Michael Mráka 2009-05-18 10:27:14 UTC
IMHO channel_families.xml.gz should not be overwritten but new channel families should be appended to the file.

Comment 4 Brandon Perkins 2009-05-19 16:08:07 UTC
Prad, how hard would this be to fix?  We know its not a regression from previous behavior, but its still bad.

Comment 5 Pradeep Kilambi 2009-05-19 20:40:30 UTC
Yea currently we don't support appending new exports to existing exported directory. If you point to an already existing directory, it will obviously overwrite. If you want to include multiple channel the use case is do 
$ rhn-satellite-export -c ch1 -c ch2 

I dont see an easy non hacky way to fix this for 530. This will need some rewrite to the Channel family dumper.

Comment 6 Frederik Bijlsma 2009-09-08 20:08:54 UTC
is this going to be fixed?
Ran into this today - at least there should be a warning from the export if it is not fixed.

Comment 9 Jan Pazdziora (Red Hat) 2010-02-19 12:11:48 UTC
Fixed in Spacewalk master d860824b6db4787aa6e0f9d53a9bb479bee43466.

Comment 11 Milan Zázrivec 2010-03-04 16:54:26 UTC
satellite.git: 44ef9849b594d3af16c62d2abb1877b8109d9cc3

Comment 12 Milan Zázrivec 2010-03-04 16:58:52 UTC
spacewalk-backend-0.5.28-40.1

Comment 14 Šimon Lukašík 2010-03-08 11:33:47 UTC
Taking.

Comment 22 Milan Zázrivec 2010-03-16 14:30:21 UTC
spacewalk-backend-0.5.28-48

Comment 25 errata-xmlrpc 2010-03-22 12:04:48 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2010-0160.html


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