orchestra-import-isos does not update

Bug #850892 reported by Scott Moser
This bug affects 1 person
Affects Status Importance Assigned to Milestone
cobbler (Ubuntu)
Adam Gandelman
orchestra (Ubuntu)
Adam Gandelman

Bug Description

currently, ubuntu-orchestra-provisioning-server will install a cron job in /etc/cron.d/orchestra-import-isos that runs weekly.

That runs /usr/sbin/orchestra-import-isos , which does has code like this:
      # Skip if cobbler already has this distro/arch combo
      if ! (cobbler distro list | grep -qs " $r-$a$"); then
         # Import the iso
         cobbler-ubuntu-import $r-$a

The stanza there makes sense to not waste bandwidth, but it is insufficient in 2 ways:
 1.) it will not update the development release (even from an iso imported during development to a released iso), which ensures that the user will have failed installs of development releases. (bug 850886)
 2.) if '1' is fixed, it would not do out-of-date checking and thus waste bandwidth.

I think the most reasonable way to fix this is to have cobbler-ubuntu-import have a '--out-of-date-check' flag that would then check if an update was needed against a timestamp or file. Then orchestra could just check if an update was needed and if so do it, otherwise continue.

related bugs:
 bug 850886: cobbler-ubuntu-import results in possibly stale netboot kernels
 bug 850880: cobbler-ubuntu-import does not pull from -updates
 bug 850892: orchestra-import-isos does not update

Related branches

Scott Moser (smoser)
summary: - orchestra-import-isos cron job wastes bandwidth
+ orchestra-import-isos does not update
description: updated
Changed in orchestra (Ubuntu):
importance: Undecided → Medium
status: New → Confirmed
Changed in cobbler (Ubuntu):
status: New → In Progress
assignee: nobody → Adam Gandelman (gandelman-a)
Changed in orchestra (Ubuntu):
assignee: nobody → Adam Gandelman (gandelman-a)
status: Confirmed → In Progress
Revision history for this message
Andres Rodriguez (andreserl) wrote :

Hi Adam.

I've looked at your patches. They look good. However, there's something that we shouldn't be doing. I've seen that to update the ISO's you would be removing a profile. correct?

If you do so, then the system that points to a profile (or subprofile for which a parent profile gets removed) then the system will be *automatically* removed from the system list. So, this means that we *should not* remove a profile, but rather update its contents and run a cobbler sync operation to create the hardlinks and stuff (We'll have to test that doing so really updates the initrd and kernel).

Revision history for this message
Adam Gandelman (gandelman-a) wrote :


Interesting. Do you know of a way to update the profile using a newer ISO? I don't see anyway other than importing the newer profile and updating the existing subprofiles to point to it as its parents. This is what we've been doing manually but seems a bit clunky. Thoughts?

Revision history for this message
Andres Rodriguez (andreserl) wrote :

The only thing that comes into my mind right now is download the new iso, mount it, then rsync it to the location where it lives whithing cobbler, and then do cobbler sync.

Cobbler sync should re-create the hardlinks, as it puts the kernel and initrd in a different location, which are used by the PXE file.

Other thing that comes into my mind is to:

1. Download new ISO
2. Import it with oneiric-<date>-<arch>
3. Change the child profile (-ensemble) to point to the parent profile above (oneiric-<date>-<arch>)
4. Remove old profile

This way, we would point the -ensemble profile to the newly imported, and then, once the old one is removed, then the systems wont be deleted as the -ensemble profile will be pointing to the newer profile at the time of deletion.

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package cobbler - 2.1.0+git20110602-0ubuntu26

cobbler (2.1.0+git20110602-0ubuntu26) oneiric; urgency=low

  * debian/cobbler-ubuntu-import: Add --check-update and --remove
    functionality. This should help orchestra-import-isos keep local
    ISO caches up-to-date. (LP: #850892)
 -- Adam Gandelman <email address hidden> Thu, 15 Sep 2011 16:36:39 -0700

Changed in cobbler (Ubuntu):
status: In Progress → Fix Released
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package orchestra - 2.25-0ubuntu1

orchestra (2.25-0ubuntu1) precise; urgency=low

  [ Scott Moser ]
  * provisioning-server/
    Advertise the orchestra provisioning service via avahi (LP: #893189)

  [ Adam Gandelman ]
  * orchestra-import-isos: import ISOs by default if no option specified
    Check for updates for existing ISOs, download + update distro if necessary.
    (LP: #850892)

  [ Andres Rodriguez ]
  * debian/ubuntu-orchestra-provisioning-server.postinst. Do not use args for
    orchestra-import-isos to maintain backwards compatibility.
 -- Andres Rodriguez <email address hidden> Mon, 28 Nov 2011 18:19:59 -0500

Changed in orchestra (Ubuntu):
status: In Progress → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers