linux-version list can be NULL

Bug #1161912 reported by Robert Nelson
12
This bug affects 2 people
Affects Status Importance Assigned to Milestone
One Hundred Papercuts
Opinion
Medium
Unassigned
flash-kernel (Ubuntu)
Won't Fix
Medium
Unassigned
linux-base (Ubuntu)
Won't Fix
Medium
Unassigned

Bug Description

I've just started looking at adding Ubuntu Raring to my 'netinstall'
script: https://github.com/RobertCNelson/netinstall and just run into
a fun issue with this commit:

http://bazaar.launchpad.net/~ubuntu-branches/ubuntu/raring/flash-kernel/raring/revision/447

Since there's no way to actually stop "flash-kernel-installer" from
running, I've been faking things, just to make it happy, which has
worked very well in the last two release's.

here's the log from what i see:

Mar 15 21:18:39 in-target: Setting up flash-kernel (3.0~rc.4ubuntu29) ...
Mar 15 21:18:54 in-target: Reading package lists...
Mar 15 21:18:54 in-target:
Mar 15 21:18:54 in-target: Building dependency tree...
Mar 15 21:18:55 in-target:
Mar 15 21:18:55 in-target: Reading state information...
Mar 15 21:18:55 in-target:
Mar 15 21:18:57 in-target: u-boot-tools is already the newest version.
Mar 15 21:18:57 in-target: 0 upgraded, 0 newly installed, 0 to remove
and 0 not upgraded.
Mar 15 21:18:59 in-target: No arg for -k option
Mar 15 21:18:59 in-target: Usage: /usr/sbin/update-initramfs [OPTION]...
Mar 15 21:18:59 in-target:
Mar 15 21:18:59 in-target: Options:
Mar 15 21:18:59 in-target: -k [version] Specify kernel version or 'all'
Mar 15 21:18:59 in-target: -c Create a new initramfs
Mar 15 21:18:59 in-target: -u Update an existing initramfs
Mar 15 21:18:59 in-target: -d Remove an existing initramfs
Mar 15 21:18:59 in-target: -t Take over a custom initramfs with this one
Mar 15 21:18:59 in-target: -b Set alternate boot directory
Mar 15 21:18:59 in-target: -v Be verbose
Mar 15 21:18:59 in-target: -h This message
Mar 15 21:18:59 in-target:
Mar 15 21:18:59 main-menu[933]: WARNING **: Configuring
'flash-kernel-installer' failed with error code 1
Mar 15 21:18:59 main-menu[933]: WARNING **: Menu item
'flash-kernel-installer' failed.

When chrooting into /target/ to see what it is returning...

# linux-version list

#

Just a blank line..

#uname -r
3.7.10-x9

If i then manually patch

/var/lib/dpkg/info/flash-kernel-installer.postinst

and restart the "flash-kernel" option it finishes the install just fine..

So, going forward I'd really like to keep supporting "no longer supported by Ubuntu" boards such as the original Beagle, imx51/imx53, etc... Along with boards Ubuntu doesn't currently support BeagleBone/BeagleBoneBlack, or ANY mainline boards coming down the pipe from CM's/etc..

Regards,

Revision history for this message
Robert Nelson (robertcnelson) wrote :
Revision history for this message
Ubuntu Foundations Team Bug Bot (crichton) wrote :

The attachment "use uname -r when linux-version list is null" seems to be a patch. If it isn't, please remove the "patch" flag from the attachment, remove the "patch" tag, and if you are a member of the ~ubuntu-reviewers, unsubscribe the team.

[This is an automated message performed by a Launchpad user owned by ~brian-murray, for any issues please contact him.]

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

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in flash-kernel (Ubuntu):
status: New → Confirmed
Revision history for this message
Jarno Suni (jarnos) wrote :

`linux-version list` is empty also, if you run it on guest session in Ubuntu 14.04 or 16.04.

Revision history for this message
Jarno Suni (jarnos) wrote :

One workaround to get the sorted list is:

dpkg-query -W -f='${Status} ${Package}\n' |
sed -nr "s/^(install|hold) ok installed linux-image-([0-9]+\..+)/\2/p" |
sort -V

tags: added: trusty xenial
Changed in linux-base (Ubuntu):
status: New → Confirmed
Changed in flash-kernel (Ubuntu):
importance: Undecided → Medium
Changed in linux-base (Ubuntu):
importance: Undecided → Medium
Changed in hundredpapercuts:
status: New → Confirmed
importance: Undecided → Medium
Revision history for this message
Balint Reczey (rbalint) wrote :

You can export the FLASH_KERNEL_SKIP global variable to make flash-kernel succeed without any action. Since this serves the exact purpose of creating images I would avoid adding an other way of skipping actions.

Changed in flash-kernel (Ubuntu):
status: Confirmed → Won't Fix
Changed in linux-base (Ubuntu):
status: Confirmed → Won't Fix
Changed in hundredpapercuts:
status: Confirmed → Opinion
Revision history for this message
Balint Reczey (rbalint) wrote :

Feel free to reopen the bug if that solution does not work for you.

Revision history for this message
Robert Nelson (robertcnelson) wrote :

@rbalint cool, almost 5 years for that answer. (a completely bogus answer)

I can tell you've never actually tried FLASH_KERNEL_SKIP, as it doesn't work in an early debian-install (di) environment.

See: March 15, 2013:

https://github.com/RobertCNelson/netinstall/commit/b52cedd2c80052977f0556a3627647ab70b70102

```
export FLASH_KERNEL_SKIP=true
```

While this bug was "posted" 2013-03-29..

Regards,

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

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