import_boot_images task fails on utopic

Bug #1328659 reported by Diogo Matsubara on 2014-06-10
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
MAAS
Critical
Julian Edwards
maas (Ubuntu)
Critical
Diogo Matsubara

Bug Description

As seen here: http://d-jenkins.ubuntu-ci:8080/view/MAAS/job/utopic-adt-maas-manual/24/artifact/results/artifacts/maas-logs/var/log/maas/celery.log/*view*/ import_boot_images task failed with the following traceback:

[2014-06-10 19:15:15,731: INFO/Worker-2] Installing boot images snapshot /var/lib/maas/boot-resources/snapshot-20140610-190204.
[2014-06-10 19:15:16,643: ERROR/Worker-2] import_boot_images: [Errno 2] No such file or directory: u'/usr/lib/syslinux/pxelinux.0'
[2014-06-10 19:15:16,698: INFO/MainProcess] Discarding revoked task: provisioningserver.tasks.upload_dhcp_leases[7e21109f-af21-4a1a-b031-5ef3af1a77db]
[2014-06-10 19:15:16,699: INFO/MainProcess] Discarding revoked task: provisioningserver.tasks.periodic_probe_dhcp[4a2c2605-d42a-4462-97bc-17f824ea3d51]
[2014-06-10 19:15:16,700: INFO/MainProcess] Discarding revoked task: provisioningserver.tasks.upload_dhcp_leases[f77e1dad-404e-42e1-9f79-94d37e506367]
[2014-06-10 19:15:16,702: ERROR/MainProcess] Task provisioningserver.tasks.import_boot_images[1d8ab057-5bdc-4950-8598-771f0fd87a5f] raised unexpected: IOError(2, 'No such file or directory')
Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/celery/app/trace.py", line 240, in trace_task
    R = retval = fun(*args, **kwargs)
  File "/usr/lib/python2.7/dist-packages/celery/app/trace.py", line 437, in __protected_call__
    return self.run(*args, **kwargs)
  File "/usr/lib/python2.7/dist-packages/provisioningserver/tasks.py", line 97, in wrapper
    func(*args, **kwargs)
  File "/usr/lib/python2.7/dist-packages/provisioningserver/tasks.py", line 469, in import_boot_images
    boot_resources.import_images(sources)
  File "/usr/lib/python2.7/dist-packages/provisioningserver/import_images/boot_resources.py", line 246, in import_images
    install_boot_loaders(snapshot_path)
  File "/usr/lib/python2.7/dist-packages/provisioningserver/import_images/boot_resources.py", line 94, in install_boot_loaders
    method.install_bootloader(destination)
  File "/usr/lib/python2.7/dist-packages/provisioningserver/boot/pxe.py", line 117, in install_bootloader
    install_bootloader(bootloader_src, bootloader_dst)
  File "/usr/lib/python2.7/dist-packages/provisioningserver/boot/install_bootloader.py", line 78, in install_bootloader
    copyfile(loader, temp_file)
  File "/usr/lib/python2.7/shutil.py", line 82, in copyfile
    with open(src, 'rb') as fsrc:
IOError: [Errno 2] No such file or directory: u'/usr/lib/syslinux/pxelinux.0'

MAAS packages: 1.6+bzr2367+2412+278-0ubuntu1 running on utopic

Related branches

description: updated
description: updated

Does the 'syslinux-common' install the /usr/lib/syslinux/pxelinux.0 file
on utopic?

Diogo Matsubara (matsubara) wrote :

Apparently no. Here's the output on utopic:

ubuntu@autopkgtest:~$ dpkg -l \*syslinux-common\*
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name Version Architecture Description
+++-========================-=================-=================-=====================================================
ii syslinux-common 3:6.03~pre1+dfsg- amd64 collection of bootloaders (common)
ubuntu@autopkgtest:~$ dpkg -L syslinux-common | grep pxe
/usr/lib/syslinux/modules/bios/pxechn.c32
/usr/lib/syslinux/modules/bios/gpxecmd.c32
/usr/lib/syslinux/modules/efi64/pxechn.c32
/usr/lib/syslinux/modules/efi64/gpxecmd.c32
/usr/lib/syslinux/modules/efi32/pxechn.c32
/usr/lib/syslinux/modules/efi32/gpxecmd.c32
/usr/share/doc/syslinux-common/txt/pxechn.txt.gz

And on trusty:
$ dpkg -l syslinux-common
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name Version Architecture Description
+++-========================-=================-=================-=====================================================
ii syslinux-common 3:4.05+dfsg-6+deb all collection of boot loaders (common files)
$ dpkg -L syslinux-common|grep pxe
/usr/bin/pxelinux-options
/usr/lib/syslinux/pxelinux.0
/usr/lib/syslinux/gpxelinux.0
/usr/lib/syslinux/com32/include/syslinux/pxe_api.h
/usr/lib/syslinux/com32/include/syslinux/pxe.h
/usr/lib/syslinux/com32/include/sys/gpxe.h
/usr/lib/syslinux/gpxelinuxk.0
/usr/lib/syslinux/gpxecmd.c32
/usr/lib/syslinux/pxechain.com
/usr/share/doc/syslinux/pxelinux.txt.gz
/usr/share/man/man1/pxelinux-options.1.gz

Diogo Matsubara (matsubara) wrote :

On utopic, that file is provided by the syslinux-dev package instead so I think the MAAS packages need a dependency update.

ubuntu@maas:~$ dpkg -L syslinux-dev|grep pxe
/usr/lib/syslinux/com32/include/syslinux/pxe.h
/usr/lib/syslinux/com32/include/syslinux/pxe_api.h
/usr/lib/syslinux/com32/include/sys/gpxe.h
/usr/lib/syslinux/gpxelinux.0
/usr/lib/syslinux/lpxelinux.0
/usr/lib/syslinux/pxelinux.0
/usr/lib/syslinux/gpxelinuxk.0
/usr/share/doc/syslinux-dev/asciidoc/pxelinux.txt.gz

Diogo Matsubara (matsubara) wrote :

I ran the tests again[1] with an updated packaging branch[2] which adds the syslinux-dev package as dependency but got another failure, this time a missing /usr/lib/syslinux/chain.c32 file.
Looks like the path for that file changed on utopic's syslinux-common:

ubuntu@utopic:~$ dpkg -L syslinux-common|grep chain
/usr/lib/syslinux/modules/bios/chain.c32
/usr/lib/syslinux/modules/efi64/chain.c32
/usr/lib/syslinux/modules/efi32/chain.c32
/usr/share/doc/syslinux-common/txt/chain.txt.gz

So I think there are two bugs here, one is the missing dependency, so import_boot_images can find the pxelinux.0 file. Another one is the hardcoded /usr/lib/syslinux path in provisioningserver/boot/pxe.py which ends up pointing to the wrong place on utopic.

[1] http://d-jenkins.ubuntu-ci:8080/view/MAAS/job/utopic-adt-maas-manual/30/artifact/results/artifacts/maas-logs/var/log/maas/celery.log
[2] lp:~matsubara/maas/syslinux-dev-dep-utopic

Gavin Panella (allenap) on 2014-06-11
Changed in maas:
status: New → Triaged
importance: Undecided → Critical
Julian Edwards (julian-edwards) wrote :

Ok, so we're either going to have to detect which file should be used or make the switch to utopic on trunk. Since we want to continue to deploy trunk to trusty, we'll have to detect the file's location.

tags: added: provisioning
Changed in maas (Ubuntu):
status: New → Fix Committed
importance: Undecided → Critical
assignee: nobody → Diogo Matsubara (matsubara)
Andres Rodriguez (andreserl) wrote :

We need to make sure that MAAS supports both, looking for the files in the previous location (for backwards compatibility and SRUablity), and also for utopic+.

Julian, are you comfortable moving this forward?

Changed in maas:
assignee: nobody → Julian Edwards (julian-edwards)
status: Triaged → In Progress
Changed in maas:
milestone: none → 1.6.0
Changed in maas:
status: In Progress → Fix Committed
Changed in maas:
status: Fix Committed → Fix Released
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package maas - 1.7.0~beta1+bzr2781-0ubuntu1

---------------
maas (1.7.0~beta1+bzr2781-0ubuntu1) utopic; urgency=medium

  * New upstream release, 1.7.0 Beta 1

  [Diogo Matsubara]
  * debian/control:
    - maas-cluster-controller depends on syslinux-dev |
      syslinux-common (LP: #1328659)
    - python-maas-provisioningserver depends on
      python-paramiko (LP: #1334401)

  [Jeroen Vermeulen]
  * debian/extras/99-maas-sudoers:
    - Let maas user import, including sudo tgt-admin and sudo uec2roottar.
  * debian/maas-cluster-controller.install:
    - Stop installing obsolete file bootresources.yaml.

  [ Raphaël Badin ]
  * debian/control:
    - maas-cluster-controller depends on python-pexpect
  * debian/extras/99-maas-sudoers:
    - Add rule 'maas-dhcp-server stop' job.

  [ Greg Lutostanski ]
  * debian/control:
    - maas-cluster-controller depends on grub-common
    - maas-provisioningserver not maas-cluster-controller depends on
      python-pexpect (LP: #1352273)
    - maas-provisioningserver not maas-cluster-controller depends on
      python-seamicroclient (LP: #1332532)

  [ Gavin Panella ]
  * debian/maas-cluster-controller.postinst
    - Allow maas-pserv to bind to all IPv6 addresses too.

  [ Julian Edwards ]
  * debian/maas-region-controller-min.apport
    debian/maas-region-controller-min.logrotate
    debian/maas-region-controller-min.postinst
    debian/maas-region-controller.postinst
    - Change the log file name maas.log to maas-django.log
  * debian/maas-cluster-controller.postinst
    debian/maas-common.install
    debian/maas-region-controller-min.postinst
    debian/maas-region-controller.postinst
    - Install /var/log/maas/maas.log as a syslog file.
    - Ensure logging is set up for upgrades

  [ Graham Binns ]
  * debian/maas-region-controller.postinst:
    - Add symlinks for squid3, squid-deb-proxy and apache log directories to
      /var/log/maas.

  [ Andres Rodriguez ]
  * debian/maas-region-controller.postinst: Force symlink creation
    for external logs.
  * debian/maas-region-controller.postinst: Do not change celery's
    rabbitmq password on upgrade that to not lock remote
    Cluster Controllers if upgrading from 1.5+. (LP: #1300507)
 -- Andres Rodriguez <email address hidden> Thu, 21 Aug 2014 14:05:40 -0400

Changed in maas (Ubuntu):
status: Fix Committed → Fix Released
tags: added: verification-done
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers