using progress mod w/ net files crashes

Bug #1459872 reported by dann frazier
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
grub2 (Ubuntu)
Medium
Mathieu Trudel-Lapierre
Trusty
Medium
Unassigned
Vivid
Medium
Unassigned
Wily
Medium
Mathieu Trudel-Lapierre

Bug Description

[Impact]
If the progress module is loaded, GRUB will crash when loading files over the network. A common scenario where this occurs is when building a GRUB image for EFI netbooting w/ all modules included. MAAS does this when generating it's grubnet EFI binary. MAAS currently works around this by explicitly blacklisting the progress module - but only on arm64 (we'd only observed this on arm64 at the time, and didn't yet know the root cause).

While the easy workaround is to just omit the progress module, it isn't at all obvious from the crash that progress.mod is the cause.

[Test Case]
The simple case is to create a grub image with *just* the progress module and netboot it. For arm64:

$ grub-mkimage -v -o grubaa64.efi -O arm64-efi -d /home/dannf/x/usr/lib/grub/arm64-efi progress

Booting the resulting image:

[1] PXE
[2] ubuntu
[3] Shell
[4] Boot Manager
Start: 1
..

Synchronous Exception at 0x0000000FF7C3DDC8

Synchronous Exception at 0x0000000FF7C3DDC8

Synchronous Exception at 0x0000000FF7C3DDC8

Synchronous Exception at 0x0000000FF7C3DDC8
[...]

[Regression Risk]
The upstream fix for this is a pretty surgical fix to check for NULL before dereferencing a pointer.

Revision history for this message
dann frazier (dannf) wrote :

The attached patch fixes the problem for me. I'll try and upstream it, though a pure upstream build is crashing elsewhere for me at the moment.

tags: added: patch
dann frazier (dannf)
summary: - arm64 images built w/ the progress module crash GRUB
+ crash when progress mod used w/ net files
summary: - crash when progress mod used w/ net files
+ using progress mod w/ net files crashes
dann frazier (dannf)
description: updated
Changed in grub2 (Ubuntu Wily):
status: New → In Progress
importance: Undecided → Medium
assignee: nobody → Mathieu Trudel-Lapierre (mathieu-tl)
Revision history for this message
Mathieu Trudel-Lapierre (cyphermox) wrote :

This bug was fixed in the package grub2 - 2.02~beta2-29

---------------
grub2 (2.02~beta2-29) unstable; urgency=medium

  [ Linn Crosetto ]
  * Clean up docs, mpi, and other files (closes: #798607).

  [ dann frazier ]
  * progress: avoid NULL dereference for net files. (LP: #1459872)

 -- Colin Watson <email address hidden> Tue, 13 Oct 2015 23:36:46 +0100

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

This bug was fixed in the package grub2 - 2.02~beta2-29

---------------
grub2 (2.02~beta2-29) unstable; urgency=medium

  [ Linn Crosetto ]
  * Clean up docs, mpi, and other files (closes: #798607).

  [ dann frazier ]
  * progress: avoid NULL dereference for net files. (LP: #1459872)

 -- Colin Watson <email address hidden> Tue, 13 Oct 2015 23:36:46 +0100

Changed in grub2 (Ubuntu Wily):
status: Fix Committed → Fix Released
Mathew Hodson (mhodson)
Changed in grub2 (Ubuntu Trusty):
importance: Undecided → Medium
Changed in grub2 (Ubuntu Vivid):
importance: Undecided → Medium
tags: added: trusty
Revision history for this message
Sebastien Bacher (seb128) wrote :

(unsubscribing sponsors, Mathieu is dealing with it)

Revision history for this message
Steve Langasek (vorlon) wrote : Please test proposed package

Hello dann, or anyone else affected,

Accepted grub2 into trusty-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/grub2/2.02~beta2-9ubuntu1.5 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested, and change the tag from verification-needed to verification-done. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed. In either case, details of your testing will help us make a better decision.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance!

Changed in grub2 (Ubuntu Trusty):
status: New → Fix Committed
tags: added: verification-needed
Revision history for this message
Steve Langasek (vorlon) wrote :

Hello dann, or anyone else affected,

Accepted grub2 into vivid-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/grub2/2.02~beta2-22ubuntu1.3 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested, and change the tag from verification-needed to verification-done. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed. In either case, details of your testing will help us make a better decision.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance!

Changed in grub2 (Ubuntu Vivid):
status: New → Fix Committed
Revision history for this message
Chris J Arges (arges) wrote :

Hello dann, or anyone else affected,

Accepted grub2-signed into trusty-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/grub2-signed/1.34.6 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested, and change the tag from verification-needed to verification-done. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed. In either case, details of your testing will help us make a better decision.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance!

Revision history for this message
Chris J Arges (arges) wrote :

Hello dann, or anyone else affected,

Accepted grub2-signed into vivid-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/grub2-signed/1.46.3 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested, and change the tag from verification-needed to verification-done. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed. In either case, details of your testing will help us make a better decision.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance!

Revision history for this message
dann frazier (dannf) wrote :

I've verified this by creating a maas-capable grub image from the update and verified that it works (and I even see progress info now!)

tags: added: verification-done
removed: verification-needed
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package grub2 - 2.02~beta2-9ubuntu1.5

---------------
grub2 (2.02~beta2-9ubuntu1.5) trusty; urgency=medium

  * d/p/arm64-set-correct-length-of-device-path-end-entry.patch: Fixes
    booting arm64 kernels on certain UEFI implementations. (LP: #1476882)
  * progress: avoid NULL dereference for net files. (LP: #1459872)
  * arm64/setjmp: Add missing license macro. (LP: #1459871)
  * Cherry-pick patch to add SAS disks to the device list from the ofdisk
    module. (LP: #1517586)
  * Cherry-pick patch to open Simple Network Protocol exclusively.
    (LP: #1508893)

 -- dann frazier <email address hidden> Wed, 25 Nov 2015 13:13:35 -0700

Changed in grub2 (Ubuntu Trusty):
status: Fix Committed → Fix Released
Revision history for this message
Steve Langasek (vorlon) wrote : Update Released

The verification of the Stable Release Update for grub2 has completed successfully and the package has now been released to -updates. Subsequently, the Ubuntu Stable Release Updates Team is being unsubscribed and will not receive messages about this bug report. In the event that you encounter a regression using the package from -updates please report a new bug using ubuntu-bug and tag the bug report regression-update so we can easily find any regressions.

Revision history for this message
Chris J Arges (arges) wrote : Please test proposed package

Hello dann, or anyone else affected,

Accepted grub2 into vivid-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/grub2/2.02~beta2-22ubuntu1.5 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested, and change the tag from verification-needed to verification-done. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed. In either case, details of your testing will help us make a better decision.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance!

tags: removed: verification-done
tags: added: verification-needed
Revision history for this message
Chris J Arges (arges) wrote :

Hello dann, or anyone else affected,

Accepted grub2-signed into vivid-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/grub2-signed/1.46.5 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested, and change the tag from verification-needed to verification-done. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed. In either case, details of your testing will help us make a better decision.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance!

dann frazier (dannf)
tags: added: verification-done verification-vivid-done
removed: verification-needed
Colin Watson (cjwatson)
tags: added: verification-done-vivid
removed: verification-vivid-done
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package grub2 - 2.02~beta2-22ubuntu1.5

---------------
grub2 (2.02~beta2-22ubuntu1.5) vivid; urgency=medium

  * Merge in changes from 2.02~beta2-22ubuntu1.3:
    - d/p/arm64-set-correct-length-of-device-path-end-entry.patch: Fixes
      booting arm64 kernels on certain UEFI implementations. (LP: #1476882)
    - progress: avoid NULL dereference for net files. (LP: #1459872)
    - arm64/setjmp: Add missing license macro. (LP: #1459871)
    - Cherry-pick patch to add SAS disks to the device list from the ofdisk
      module. (LP: #1517586)
    - Cherry-pick patch to open Simple Network Protocol exclusively.
      (LP: #1508893)
  * Cherry-picks to better handle TFTP timeouts on some arches: (LP: #1521612)
    - (7b386b7) efidisk: move device path helpers in core for efinet
    - (c52ae40) efinet: skip virtual IP devices when enumerating cards
    - (f348aee) efinet: enable hardware filters when opening interface
  * Update quick boot logic to handle abstractions for which there is no
    write support. (LP: #1274320)

 -- dann frazier <email address hidden> Wed, 16 Dec 2015 13:31:15 -0700

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

Other bug subscribers