Bug 246480 - sync last_modified dates correctly for ks trees instead of defaulting to current date
sync last_modified dates correctly for ks trees instead of defaulting to curr...
Status: CLOSED ERRATA
Product: Red Hat Satellite 5
Classification: Red Hat
Component: Satellite Synchronization (Show other bugs)
unspecified
All Linux
high Severity high
: ---
: ---
Assigned To: Jan Pazdziora
Šimon Lukašík
: Reopened, Triaged
Depends On: 328271
Blocks: sat-channel-dumps
  Show dependency treegraph
 
Reported: 2007-07-02 12:20 EDT by Pradeep Kilambi
Modified: 2010-10-22 12:01 EDT (History)
7 users (show)

See Also:
Fixed In Version: sat510
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2010-03-22 08:04:31 EDT
Type: ---
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 Pradeep Kilambi 2007-07-02 12:20:25 EDT
Description of problem:
When satellite-sync pulls down kickstart trees from hosted, It overrides the
last_modified date to the date it synced the files. This has been the behavior
since long. This becomes a problem with channel dump generation (for incremental
dumps) as the date ranges no longer get validated for kickstart trees and pulls
everything.
Comment 1 Pradeep Kilambi 2007-09-25 12:03:55 EDT
not a very high priority/blocker IMO, this bug fits well with the Enhancements
we're planning for rhn-sat-exporter tool for 520.
Comment 2 Pradeep Kilambi 2007-10-11 15:59:57 EDT
Investigating further, looks like we don't export last_modified from hosted. So
for us to include the right KickstartTree last_modified date field into sat's
rhnKickstartTree table, we need this date to be first exported by hosted
satellite exporter. 

I opened a bug(bz#328271) for hosted to add this to the exporter. Once thats
done, we can grab the last_modified from the xml stream and populate db with
correct values.
Comment 3 Clifford Perry 2007-12-11 21:41:20 EST
https://bugzilla.redhat.com/show_bug.cgi?id=328271#c1
Comment #1 From James Bowes (jbowes@redhat.com) 	on 2007-10-17 19:55 EST 
[reply] 	Private

Data is sent, but as last-modified rather than last_modified
Comment 4 Pradeep Kilambi 2007-12-19 17:35:55 EST
Looks like even though the data is sent as a different key, looks like the
satsync was never written to handle last_modified dates for kickstart-trees and
hence there seems to be no validation for the last-modified dates verses the the
timestamps. So we pretty much need to rewrite rhnKickstartTreeCollection and
Container classes. I would say we could scope this for next release if we're
short on time. 
Comment 5 Pradeep Kilambi 2007-12-20 10:35:44 EST
After discussing with cliff, moving to sat-5.2 ..
Comment 10 Clifford Perry 2010-01-26 10:02:52 EST
Moving to sat-channel-dumps tracker. Agree we should look to address this as part of the feature code changes needed to redo channel dump creation process. 

Cliff
Comment 14 Jan Pazdziora 2010-02-19 12:54:54 EST
Fixed in Spacewalk master 460aad3e019c6fd064732aed14127d822d62217b.
Comment 15 Milan Zazrivec 2010-03-04 11:54:00 EST
satellite.git: 9ee57b70a63c7fbdb3e46e8b4352cfbbd2681fb0
Comment 16 Milan Zazrivec 2010-03-04 11:58:47 EST
spacewalk-backend-0.5.28-40.1
Comment 18 Šimon Lukašík 2010-03-15 04:09:43 EDT
Taking QA contact for the bug verification.
Comment 20 Milan Zazrivec 2010-03-16 10:30:34 EDT
spacewalk-backend-0.5.28-48
Comment 21 Šimon Lukašík 2010-03-17 10:37:51 EDT
Verified against: (on rhel-i386-server-5-u4) 
spacewalk-backend-0.5.28-49.el5sat.noarch
Comment 23 errata-xmlrpc 2010-03-22 08:04:31 EDT
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
Comment 24 Milan Zazrivec 2010-03-23 11:13:42 EDT
Although the errata fixing this particular issue is out, I'd like
to point out two important things:

1) The updated packages won't update last_modified values that already
exist in the database. This means, if the previous satellite-sync
set these values incorrectly, new sync won't update these values. It
will only be able to insert new correct values for newly synchronized
kickstartable trees.

2) Due to bug #576222, even correctly set last_modified values will be
overwritten when taskomatic executes CobblerSyncTask, which modifies
existing rows in rhnKickstartableTree for use with cobbler (disabling
this task may help, as long as cobbler functionality is not required).

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