update_flash fails on Ubuntu in PowerVM mode

Bug #1491977 reported by bugproxy
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
powerpc-ibm-utils (Ubuntu)
Fix Released
High
Adam Conrad

Bug Description

---Problem Description---
update_flash (PowerVM mode) from Ubuntu fails with a 'bad variable name'.

---uname output---
Linux neo33-2 3.19.0-21-generic #21-Ubuntu SMP Sun Jun 14 19:33:37 UTC 2015 ppc64le ppc64le ppc64le GNU/Linux

Machine Type = type_model=8247-22L

---Steps to Reproduce---
 # update_flash -f 01SV840_016_016.img
/usr/sbin/update_flash: 185: local: FW830.00: bad variable name

If I comment out line 252 and run it again, things do work (but there is checking that doesn't happen in that case)

# echo_validate_return_status "$output"

Upstream commit ID :

commit 546174be41c74894126414515644888ed8b31584
Author: Vasant Hegde <email address hidden>
Date: Wed Sep 2 10:23:21 2015 -0400

    update_flash: Fix bad variable issue

    Shells like dash throws error if we try to assign string with space
    without double quote. ex:
     local bug=ML FW830.00 FW830.00

> [PATCH] update_flash: Stop kexec service before starting firmware update on
> PowerVM LPAR

I've posted this patch to upstream today...

-Vasant

Revision history for this message
bugproxy (bugproxy) wrote : [PATCH] Fix bad vriable issue

Default Comment by Bridge

tags: added: architecture-ppc64le bugnameltc-126660 severity-critical targetmilestone-inin1504
Revision history for this message
bugproxy (bugproxy) wrote : [PATCH] update_flash: Stop kexec service before starting firmware update on PowerVM LPAR

Default Comment by Bridge

Luciano Chavez (lnx1138)
affects: ubuntu → powerpc-ibm-utils (Ubuntu)
Changed in powerpc-ibm-utils (Ubuntu):
assignee: nobody → Taco Screen team (taco-screen-team)
Steve Langasek (vorlon)
Changed in powerpc-ibm-utils (Ubuntu):
assignee: Taco Screen team (taco-screen-team) → Adam Conrad (adconrad)
importance: Undecided → High
milestone: none → ubuntu-15.10
status: New → Triaged
Revision history for this message
bugproxy (bugproxy) wrote : Comment bridged from LTC Bugzilla

------- Comment From <email address hidden> 2015-09-04 11:55 EDT-------
Hello Canonical,

Please pull these two patches for 15.04, 14.04.03 and 15.10 series..

Let me know if you want separate bug for each distro version..

-Vasant

Revision history for this message
bugproxy (bugproxy) wrote :

------- Comment From <email address hidden> 2015-09-11 06:47 EDT-------
Hello Canonical,

All the patches are accepted in upstream.. Please pull below three patches..

commit 546174be41c74894126414515644888ed8b31584
Author: Vasant Hegde <email address hidden>
Date: Wed Sep 2 10:23:21 2015 -0400

update_flash: Fix bad variable issue
Shells like dash throws error if we try to assign string with space
without double quote. ex:
local bug=ML FW830.00 FW830.00
Sample output without this patch:
update_flash -f 01SV840_016_016.img
/usr/sbin/update_flash: 185: local: FW830.00: bad variable name

commit 62dc6d38de177588f205e01cec15b93b3e2b9a30
Author: Vasant Hegde <email address hidden>
Date: Wed Sep 2 10:26:23 2015 -0400

update_flash: Stop kexec service before starting firmware update
We run 'reboot' call before initiating firmware update. If kexec service
is enabled, then we endup booting into new kernel instead of starting
firmware update.
This patch validates kexec service and if required stops this service
before starting code update.

commit 8ff5144da07985cd84508465007f9031840d4ecd
Author: Vasant Hegde <email address hidden>
Date: Tue Sep 8 11:33:24 2015 -0400

update_flash: Stop kexec service before starting firmware update on PowerVM LPAR
We run 'reboot' call before initiating firmware update. If kexec service
is enabled, then we endup booting into new kernel instead of starting
firmware update.
Commit 62dc6d38 fix this issue on PowerNV platform.. but missed to fix
PowerVM LPAR. This patch fixes above described issue on PowerVM LPAR.
Signed-off-by: Vasant Hegde <email address hidden>

-Vasant

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

This bug was fixed in the package powerpc-ibm-utils - 1.2.26-2

---------------
powerpc-ibm-utils (1.2.26-2) unstable; urgency=medium

  * bad_variable.patch: Add extra quoting to update_flash (LP: #1491977)
  * stop_kexec_nv.patch: Stop kexec before starting flash (LP: #1491063)
  * stop_kexec_vm.patch: Likewise, but also do it for PowerVM platforms.

 -- Adam Conrad <adconrad@0c3.net> Thu, 15 Oct 2015 21:46:32 -0600

Changed in powerpc-ibm-utils (Ubuntu):
status: Triaged → Fix Released
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.