Hardy images fail to build with 0.12.2-0ubuntu3

Bug #539460 reported by Kevin McDermott
40
This bug affects 8 people
Affects Status Importance Assigned to Milestone
Landscape Server
Fix Released
Undecided
Kevin McDermott
VMBuilder
Fix Committed
Undecided
Kevin McDermott
vm-builder (Ubuntu)
Fix Released
Undecided
Unassigned
Lucid
Fix Released
Undecided
Soren Hansen

Bug Description

2010-03-12 17:02:46,616 INFO :
Traceback (most recent call last):
  File "/usr/bin/vmbuilder", line 24, in <module>
    cli.main()
  File "/usr/lib/python2.6/dist-packages/VMBuilder/contrib/cli.py", line 106, in main
    hypervisor.install_os()
  File "/usr/lib/python2.6/dist-packages/VMBuilder/hypervisor.py", line 57, in install_os
    self.call_hooks('install_bootloader', self.chroot_dir, self.disks)
  File "/usr/lib/python2.6/dist-packages/VMBuilder/distro.py", line 66, in call_hooks
    call_hooks(self, *args, **kwargs)
  File "/usr/lib/python2.6/dist-packages/VMBuilder/util.py", line 158, in call_hooks
    getattr(plugin, func, log_no_such_method)(*args, **kwargs)
  File "/usr/lib/python2.6/dist-packages/VMBuilder/plugins/ubuntu/distro.py", line 222, in install_bootloader
    self.suite.install_menu_lst(disks)
  File "/usr/lib/python2.6/dist-packages/VMBuilder/plugins/ubuntu/dapper.py", line 214, in install_menu_lst
    self.mangle_grub_menu_lst(disks)
TypeError: mangle_grub_menu_lst() takes exactly 1 argument (2 given)
make[1]: *** [build/appliance/appliance.qcow2] Error 1
make[1]: Leaving directory `/home/kevin/src/canonical/landscape/standalone/standalone'
make: *** [standalone-appliance] Error 2

the base Dapper distro plugin requires the disks parameter, but the later ones don't.

Related branches

Changed in landscape:
assignee: nobody → Kevin McDermott (bigkevmcd)
Changed in vmbuilder:
assignee: nobody → Kevin McDermott (bigkevmcd)
status: New → In Progress
Changed in landscape:
status: New → In Progress
Soren Hansen (soren)
Changed in vmbuilder:
status: In Progress → Fix Committed
Revision history for this message
Soren Hansen (soren) wrote :

This is a severe regression from Karmic, so I'm going to SRU this.

It was fixed by http://bazaar.launchpad.net/~ubuntu-virt/vmbuilder/0.12/revision/436 which is included in the new 0.12.4 release upstream.

TEST CASE: sudo vmbuilder kvm ubuntu --suite hardy

Changed in vm-builder (Ubuntu):
status: New → Triaged
Changed in vm-builder (Ubuntu Lucid):
assignee: nobody → Soren Hansen (soren)
status: New → Triaged
Revision history for this message
Gunnar Thielebein (lorem-ipsum) wrote :

I tried to apply the patch from above link to lucids current package:

$ cd /usr/lib/python2.5/site-packages
$ patch -p0 < ~/436_435.diff

Error message still comes up with TEST CASE:

Traceback (most recent call last):
  File "/usr/bin/vmbuilder", line 24, in <module>
    cli.main()
  File "/usr/lib/python2.6/dist-packages/VMBuilder/contrib/cli.py", line 116, in main
    hypervisor.install_os()
  File "/usr/lib/python2.6/dist-packages/VMBuilder/hypervisor.py", line 68, in install_os
    self.call_hooks('install_bootloader', self.chroot_dir, self.disks)
  File "/usr/lib/python2.6/dist-packages/VMBuilder/distro.py", line 66, in call_hooks
    call_hooks(self, *args, **kwargs)
  File "/usr/lib/python2.6/dist-packages/VMBuilder/util.py", line 158, in call_hooks
    getattr(plugin, func, log_no_such_method)(*args, **kwargs)
  File "/usr/lib/python2.6/dist-packages/VMBuilder/plugins/ubuntu/distro.py", line 222, in install_bootloader
    self.suite.install_menu_lst(disks)
  File "/usr/lib/python2.6/dist-packages/VMBuilder/plugins/ubuntu/dapper.py", line 211, in install_menu_lst
    self.mangle_grub_menu_lst(disks)
  File "/usr/lib/python2.6/dist-packages/VMBuilder/plugins/ubuntu/edgy.py", line 33, in mangle_grub_menu_lst
    run_cmd('sed', '-ie', 's/^# kopt=root=\([^ ]*\)\(.*\)/# kopt=root=UUID=%s\\2/g' % bootdev.fs.uuid, '%s/boot/grub/menu.lst' % self.destdir)
AttributeError: 'Hardy' object has no attribute 'destdir'

Revision history for this message
Kevin McDermott (bigkevmcd) wrote :

Gunnar...

> $ cd /usr/lib/python2.5/site-packages
> $ patch -p0 < ~/436_435.diff

Traceback (most recent call last):
  File "/usr/bin/vmbuilder", line 24, in <module>
    cli.main()
  File "/usr/lib/python2.6/dist-packages/VMBuilder/contrib/cli.py", line 116, in main
                     ^^^^^^^^^^^
You might want to check that those are the same files!

Also, there's no Python2.5 on Lucid, so am skeptical that this will work at all...

Revision history for this message
Gunnar Thielebein (lorem-ipsum) wrote :

Thanks Kevin pointing that out,

after patching against the correct python version I am a bit further but still not completed:

  File "/usr/lib/python2.6/dist-packages/VMBuilder/util.py", line 120, in run_cmd
    raise VMBuilderException, "Process (%s) returned %d. stdout: %s, stderr: %s" % (args.__repr__(), status, mystdout.buf, mystderr.buf)
VMBuilder.exception.VMBuilderException: Process (['kpartx', '-av', '/tmp/tmpK_gMPL']) returned 1. stdout: , stderr: mount: could not find any free loop deviceBad address
can't set up loop

Revision history for this message
Adam Collard (adam-collard) wrote :

@Gunnar: if you're still getting that traceback you may want to check out your loop devices using "losetup -a", deleting any unused ones with "losetup -d" then try again

Is this SRU still in progress? I really need this fix and avoided patching locally because I saw the SRU had started. Is there anything I can do to speed this up?

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

This bug was fixed in the package vm-builder - 0.12.4-0ubuntu1

---------------
vm-builder (0.12.4-0ubuntu1) maverick; urgency=low

  * New upstream, bugfix release. (LP: #539460, #536942, #535397,
    #550689, #410521, #550691, others)
 -- Soren Hansen <email address hidden> Fri, 09 Jul 2010 22:58:32 +0200

Changed in vm-builder (Ubuntu):
status: Triaged → Fix Released
Revision history for this message
John Dong (jdong) wrote :

Looked at 0.12.4-0ubuntu0.1 in the SRU queue, and the diff looks pretty reasonable. ACK from SRU for the patch, though it's unclear how exactly we plan on the verification procedure being carried out.

Revision history for this message
Gunnar Thielebein (lorem-ipsum) wrote :

@Adam, sorry for some reason I missed notification. Issue does not show up when patch is applied to correct python version. Issue with stalled loop devices is described in #592236 .

Revision history for this message
Jonathan Riddell (jr) wrote : Please test proposed package

Accepted into lucid-proposed, the package will build now and be available in a few hours. Please test and give feedback here. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Thank you in advance!

Changed in vm-builder (Ubuntu Lucid):
status: Triaged → Fix Committed
tags: added: verification-needed
Revision history for this message
Paul Elliott (omahn) wrote :

Successfully verified that 0.12.4-0ubuntu0.1 fixes the issue and can successfully build hardy images again.

tags: added: verification-done
removed: verification-needed
Changed in landscape:
status: In Progress → Fix Committed
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package vm-builder - 0.12.4-0ubuntu0.1

---------------
vm-builder (0.12.4-0ubuntu0.1) lucid-proposed; urgency=low

  * New upstream, bugfix release. (LP: #539460, #536942, #535397,
    #550689, #410521, #550691, others)
 -- Soren Hansen <email address hidden> Fri, 09 Jul 2010 23:03:27 +0200

Changed in vm-builder (Ubuntu Lucid):
status: Fix Committed → Fix Released
Changed in landscape:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.