Description of problem: rhnKickstartableTree table contains a column last_modified, which gets populated by satellite-sync with data from hosted or channel dump. These values play an important role when creating a time constrained (aka incremental) channel dump: it determines which kickstartable trees will fall into the specified date range and which won't. Satellite 5.3.0 schema defines following trigger: create or replace trigger rhn_kstree_mod_trig before insert or update on rhnKickstartableTree for each row begin if (:new.last_modified = :old.last_modified) or (:new.last_modified is null ) then :new.last_modified := sysdate; end if; :new.modified := sysdate; end rhn_kstree_mod_trig; / When CobblerSyncTask is run (by taskomatic), it modifies existing rows in rhnKickstartableTree table and causes the last_modified values to be overwritten by sysdate (current date & time). Version-Release number of selected component (if applicable): satellite-schema-5.3.0.23-1.el5sat spacewalk-schema-0.5.20-23.el5sat spacewalk-java-0.5.44-69.el5sat How reproducible: Always Steps to Reproduce: 1. Install Satellite 5.3.0, synchronize rhel-5 channel from hosted 2. sqlplus `spacewalk-cfg-get default_db` 3. SQL> select label, to_char(last_modified,'YYYY-MM-DD HH24-MI-SS') from rhnKickstartableTree; 4. Wait for CobblerSyncTask to wake up (you'll see log entries in /var/log/cobbler/cobblerd.log like this: 2010-03-22 12:53:01,302 - api - login attempt; user(taskomatic_user) 2010-03-22 12:53:01,495 - api - authenticate; ['taskomatic_user', True] 2010-03-22 12:53:01,497 - api - login succeeded; user(taskomatic_user) 2010-03-22 12:53:01,668 - api - get_distros; user(?) 2010-03-22 12:53:01,971 - api - get_profiles; user(?) 2010-03-22 12:53:01,983 - api - get_systems; user(?) 5. After you see the task has been executed, connect to your database with sqlplus 6. SQL> select label, to_char(last_modified,'YYYY-MM-DD HH24-MI-SS') from rhnKickstartableTree; Actual results: The last_modified values will get overwritten with sysdate. Expected results: last_modified values will be preserved. Additional info: The problem described above defeats the fix from https://bugzilla.redhat.com/show_bug.cgi?id=246480
updated trigger to ignore changes to the cobbler_id and cobbler_xen_id columns for last_modified d4cb96d46b4b97242225eac0daa6992df39c78fa
Verified. # rpm -q satellite-schema spacewalk-schema spacewalk-java satellite-schema-5.4.0.8-1.el5sat.noarch spacewalk-schema-1.2.21-4.el5sat.noarch spacewalk-java-1.2.39-27.el5sat.noarch # satellite-sync -c rhel-i386-server-5 # sqlplus `spacewalk-cfg-get default_db` SQL> select label, to_char(last_modified,'YYYY-MM-DD HH24-MI-SS') from rhnKickstartableTree; LABEL TO_CHAR(LAST_MODIFI ------------------------------- ------------------- ks-rhel-i386-server-5 2007-03-14 00-00-00 ks-rhel-i386-server-5-u1 2007-11-21 00-00-00 ks-rhel-i386-server-5-u2 2008-06-04 00-00-00 ks-rhel-i386-server-5-u3 2009-01-29 00-00-00 ks-rhel-i386-server-5-u4 2009-09-23 00-00-00 ks-rhel-i386-server-5-u5 2010-05-04 00-00-00
Cobbler sync task is scheduled every minute. I see last_modified dates older than 1 day (and taskomatic is running). STAGE VALIDATED on Satellite-5.4.0-RHEL5-re20101015.0
The 5.4.0 RHN Satellite and RHN Proxy release has occurred. This issue has been resolved with this release. RHEA-2010:0801 - RHN Satellite Server 5.4.0 Upgrade https://rhn.redhat.com/rhn/errata/details/Details.do?eid=10332 RHEA-2010:0803 - RHN Tools enhancement update https://rhn.redhat.com/rhn/errata/details/Details.do?eid=10333 RHEA-2010:0802 - RHN Proxy Server 5.4.0 bug fix update https://rhn.redhat.com/rhn/errata/details/Details.do?eid=10334 RHEA-2010:0800 - RHN Satellite Server 5.4.0 https://rhn.redhat.com/rhn/errata/details/Details.do?eid=10335 Docs are available: http://docs.redhat.com/docs/en-US/Red_Hat_Network_Satellite/index.html Regards, Clifford