update-grub-legacy-ec2 ignores kernels named -generic
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
cloud-init (Ubuntu) |
Fix Released
|
Critical
|
Unassigned | ||
Precise |
Fix Released
|
High
|
Unassigned |
Bug Description
== Begin SRU Information ==
[General Description]
Amazon's EC2 is a xen based cloud platform, the bootloader that is used is 'pvgrub'. pvgrub runs inside a xen instance, reads a /boot/grub/menu.lst file, and loads the kernels specified there. It does not support grub2 style configuration (/boot/
grub-legacy-ec2 does not simply assume all kernels are candidates for inclusion in /boot/grub/
In the development cycle of 12.10, the -virtual kernel went away. It is now simply a -generic kernel with a subset of modules.
[Impact]
In 12.04, it is now supported to run a 12.10 "enablement kernel" (https:/
The end result is that the user who installs these kernels will not be able to easily boot them on EC2 (or other xen guest).
[Test Case]
* Boot a cloud instance or cloud image
The daily build of a EC2 AMI id at http://
* install a backports kernel
sudo apt-get install linux-generic-
* verify that kernel new kernel is included in /boot/grub/menu.lst
Previously the kernel would not be included there.
Previously:
$ grep "3.5.[0-9]" /boot/grub/menu.lst || echo NOT_FOUND
NOT_FOUND
But with new update-grub, it will be.
# enable proposed
$ echo "deb http://
sudo tee /etc/apt/
$ sudo apt-get update
$ sudo apt-get install grub-legacy-ec2
$ sudo update-
$ grep "3.5.[0-9]" /boot/grub/menu.lst || echo NOT_FOUND
title Ubuntu 12.04.2 LTS, kernel 3.5.0-24-generic
kernel /boot/vmlinuz-
...
[Regression Potential]
The biggest potential for regression would be in writing an entry to /boot/grub/menu.lst for a kernel that would not boot. There is protection against this in the included patch by checking the version number as well as the name.
That amounts to:
dpkg --compare-versions ${ver_flavor%
where 'ver_flavor' is the version as found in the file name of the kernel (ie, /boot/vmlinux-
== End SRU Information ==
Quantal stopped booting on EC2 around 2012-05-25.
ben@padfoot:~$ ec2-get-
Required parameter 'INSTANCE' missing (-h for usage)
ben@padfoot:~$ ec2-get-
i-75727213
2012-05-
Xen Minimal OS!
start_info: 0xb10000(VA)
nr_pages: 0x6a400
shared_inf: 0x001a5000(MA)
pt_base: 0xb13000(VA)
nr_pt_frames: 0x9
mfn_list: 0x967000(VA)
mod_start: 0x0(VA)
mod_len: 0
flags: 0x0
cmd_line: root=/dev/sda1 ro 4
stack: 0x946780-0x966780
MM: Init
_text: 0x0(VA)
_etext: 0x61e65(VA)
_erodata: 0x76000(VA)
_edata: 0x7b6d4(VA)
stack start: 0x946780(VA)
_end: 0x966d34(VA)
start_pfn: b1f
max_pfn: 6a400
Mapping memory range 0xc00000 - 0x6a400000
setting 0x0-0x76000 readonly
skipped 0x1000
MM: Initialise page allocator for e6c000(
MM: done
Demand map pfns at 6a401000-7a401000.
Heap resides at 7a402000-ba402000.
Initialising timer interface
Initialising console ... done.
gnttab_table mapped at 0x6a401000.
Initialising scheduler
Thread "Idle": pointer: 0x7a402008, stack: 0x6a030000
Initialising xenbus
Thread "xenstore": pointer: 0x7a402478, stack: 0x6a040000
Dummy main: start_info=0x966880
Thread "main": pointer: 0x7a4028e8, stack: 0x6a050000
"main" "root=/dev/sda1" "ro" "4"
vbd 2049 is hd0
******************* BLKFRONT for device/vbd/2049 **********
backend at /local/
Failed to read /local/
Failed to read /local/
16777216 sectors of 0 bytes
*******
vbd 2050 is hd1
******************* BLKFRONT for device/vbd/2050 **********
backend at /local/
Failed to read /local/
Failed to read /local/
312705024 sectors of 0 bytes
*******
vbd 2051 is hd2
******************* BLKFRONT for device/vbd/2051 **********
backend at /local/
Failed to read /local/
Failed to read /local/
1835008 sectors of 0 bytes
*******
[H[J Booting 'Ubuntu quantal (development branch), memtest86+'
root (hd0)
Filesystem type is ext2fs, using whole disk
kernel /boot/memtest86
xc_dom_
ERROR Invalid kernel: xc_dom_find_loader: no loader found
xc_dom_core.c:536: panic: xc_dom_find_loader: no loader found
xc_dom_parse_image returned -1
Error 9: Unknown boot failure
Press any key to continue...
affects: | ubuntu → cloud-init (Ubuntu) |
Changed in cloud-init (Ubuntu Precise): | |
status: | New → Confirmed |
importance: | Undecided → High |
summary: |
- Quantal does not boot on EC2 + update-grub-legacy-ec2 ignores kernels named -generic |
description: | updated |
description: | updated |
no longer affects: | linux-lts-quantal (Ubuntu) |
no longer affects: | linux-lts-quantal (Ubuntu Precise) |
On 28.05.2012 16:25, Ben Howard wrote: console- output -i i-75727213 console- output i-75727213 28T14:17: 49+0000 e6c000) -0(6a400000) domain/ 0/backend/ vbd/126/ 2049 domain/ 0/backend/ vbd/126/ 2049/feature- barrier. domain/ 0/backend/ vbd/126/ 2049/feature- flush-cache. ******* ******* ***** domain/ 0/backend/ vbd/126/ 2050 domain/ 0/backend/ vbd/126/ 2050/feature- barrier. domain/ 0/backend/ vbd/126/ 2050/feature- flush-cache. ******* ******* ***** domain/ 0/backend/ vbd/126/ 2051 domain/ 0/backend/ vbd/126/ 2051/feature- barrier. domain/ 0/backend/ vbd/126/ 2051/feature- flush-cache. ******* ******* *****
> Public bug reported:
>
> Quantal stopped booting on EC2 around 2012-05-25.
>
> ben@padfoot:~$ ec2-get-
> Required parameter 'INSTANCE' missing (-h for usage)
> ben@padfoot:~$ ec2-get-
> i-75727213
> 2012-05-
> Xen Minimal OS!
> start_info: 0xb10000(VA)
> nr_pages: 0x6a400
> shared_inf: 0x001a5000(MA)
> pt_base: 0xb13000(VA)
> nr_pt_frames: 0x9
> mfn_list: 0x967000(VA)
> mod_start: 0x0(VA)
> mod_len: 0
> flags: 0x0
> cmd_line: root=/dev/sda1 ro 4
> stack: 0x946780-0x966780
> MM: Init
> _text: 0x0(VA)
> _etext: 0x61e65(VA)
> _erodata: 0x76000(VA)
> _edata: 0x7b6d4(VA)
> stack start: 0x946780(VA)
> _end: 0x966d34(VA)
> start_pfn: b1f
> max_pfn: 6a400
> Mapping memory range 0xc00000 - 0x6a400000
> setting 0x0-0x76000 readonly
> skipped 0x1000
> MM: Initialise page allocator for e6c000(
> MM: done
> Demand map pfns at 6a401000-7a401000.
> Heap resides at 7a402000-ba402000.
> Initialising timer interface
> Initialising console ... done.
> gnttab_table mapped at 0x6a401000.
> Initialising scheduler
> Thread "Idle": pointer: 0x7a402008, stack: 0x6a030000
> Initialising xenbus
> Thread "xenstore": pointer: 0x7a402478, stack: 0x6a040000
> Dummy main: start_info=0x966880
> Thread "main": pointer: 0x7a4028e8, stack: 0x6a050000
> "main" "root=/dev/sda1" "ro" "4"
> vbd 2049 is hd0
> ******************* BLKFRONT for device/vbd/2049 **********
>
>
> backend at /local/
> Failed to read /local/
> Failed to read /local/
> 16777216 sectors of 0 bytes
> *******
> vbd 2050 is hd1
> ******************* BLKFRONT for device/vbd/2050 **********
>
>
> backend at /local/
> Failed to read /local/
> Failed to read /local/
> 312705024 sectors of 0 bytes
> *******
> vbd 2051 is hd2
> ******************* BLKFRONT for device/vbd/2051 **********
>
>
> backend at /local/
> Failed to read /local/
> Failed to read /local/
> 1835008 sectors of 0 bytes
> *******
> [H[J Booting 'Ubuntu quantal (development branch), memtest86+'
>
> root (hd0)
> Filesystem type is ext2fs, using whole disk
> kernel /boot/memtest86 +.bin
^Huh?!?
> probe_bzimage_ kernel: kernel is not a bzImage kernel- team)
> xc_dom_
> ERROR Invalid kernel: xc_dom_find_loader: no loader found
>
> xc_dom_core.c:536: panic: xc_dom_find_loader: no loader found
> xc_dom_parse_image returned -1
>
> Error 9: Unknown boot failure
>
> Press any key to continue...
>
> ** Affects: ubuntu
> Importance: Undecided
> Assignee: Canonical Kernel Team (canonical-
> Status: New
>
>
> ** Tags: cloud-images ec2
>