<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugzilla.yoctoproject.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.6"
          urlbase="https://bugzilla.yoctoproject.org/"
          
          maintainer="it-coreprojects-helpdesk@linuxfoundation.org"
>

    <bug>
          <bug_id>4104</bug_id>
          
          <creation_ts>2013-03-25 16:22:31 +0000</creation_ts>
          <short_desc>Need a method for install/update of bzImage</short_desc>
          <delta_ts>2013-11-26 12:30:37 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>7</classification_id>
          <classification>Build System, Metadata &amp; Runtime</classification>
          <product>OE-Core</product>
          <component>deployment</component>
          <version>unspecified</version>
          <rep_platform>x86</rep_platform>
          <op_sys>Multiple</op_sys>
          <bug_status>VERIFIED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>Medium+</priority>
          <bug_severity>enhancement</bug_severity>
          <target_milestone>1.6</target_milestone>
          <dependson>4756</dependson>
          <blocked>4106</blocked>
    
    <blocked>4694</blocked>
          <everconfirmed>1</everconfirmed>
          <reporter name="Jason Wessel">jason.wessel</reporter>
          <assigned_to name="Hongxu Jia">hongxu.jia</assigned_to>
          <cc>dvhart</cc>
    
    <cc>holger</cc>
    
    <cc>ionutx.chisanovici</cc>
    
    <cc>jessica.zhang</cc>
    
    <cc>liezhi.yang</cc>
    
    <cc>Qi.Chen</cc>
    
    <cc>song.liu</cc>
          
          
          <cf_os>---</cf_os>
          <cf_regression_type>---</cf_regression_type>
          
          <cf_docchange>No (bug/feature does not impact docs)</cf_docchange>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>31132</commentid>
    <comment_count>0</comment_count>
    <who name="Jason Wessel">jason.wessel</who>
    <bug_when>2013-03-25 16:22:31 +0000</bug_when>
    <thetext>Presently the installer automatically copies the bzImage and optional initrd into the /boot area and populates the initial boot menu.

This should be managed by a post deploy method such that a board can get an new kernel but also have the previous fall back kernel as well.  A good example would be the Fedora Linux updates where you receive and rpm which has the kernel and when installed it will update the boot area and the boot menu with the kernel as the priority but allow you to fall back to the original kernel as well.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>31738</commentid>
    <comment_count>1</comment_count>
    <who name="Song Liu">song.liu</who>
    <bug_when>2013-04-08 21:55:01 +0000</bug_when>
    <thetext>This should be &apos;enhancement&apos; since it&apos;s a feature request.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>34811</commentid>
    <comment_count>2</comment_count>
    <who name="Darren Hart">dvhart</who>
    <bug_when>2013-07-24 15:57:44 +0000</bug_when>
    <thetext>4756 calls out a problem with using symlinks when a FAT partition is involved. I suspect that will be a problem here as well, marking is dependent.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>34825</commentid>
    <comment_count>3</comment_count>
    <who name="Bruce Ashfield">bruce.ashfield</who>
    <bug_when>2013-07-24 19:39:31 +0000</bug_when>
    <thetext>I&apos;m not the right person to work on this, I&apos;ll be updating to the new
kernel in M4 and won&apos;t have the cycles. I&apos;m looking for a new assignee and
will get the case updated.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>36882</commentid>
    <comment_count>4</comment_count>
    <who name="Darren Hart">dvhart</who>
    <bug_when>2013-09-18 15:13:26 +0000</bug_when>
    <thetext>*** Bug 4756 has been marked as a duplicate of this bug. ***</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>36883</commentid>
    <comment_count>5</comment_count>
    <who name="Darren Hart">dvhart</who>
    <bug_when>2013-09-18 15:14:03 +0000</bug_when>
    <thetext>From 4756, now a dup of this, Holger Freyther said:



Currently I am using the &quot;boot-directdisk&quot; bbclass to create a raw image for an x86 based system. My target system does not have EFI support which means that syslinux is used. I am using the boot-directdisk because this allows me to &quot;install&quot; the image using wget -O/dd on the compact flash card before assembling the unit.

The issue with this approach is that currently I am unable to upgrade the kernel image (which results in still shipping a kernel with many known security issues). By default the kernel recipe will use update-alternatives to create/update a symlink to point to the new kernel image. If I update the kernel package the installed kernel and the modules will not match.

My proposal would be to use another boot loader. I asked about grub but Darren Hart pointed me to extlinux. In case of extlinux I could do one of the following:

I could either have a dedicated /boot partition for extlinux or include it directly in my system.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>38621</commentid>
    <comment_count>6</comment_count>
    <who name="Hongxu Jia">hongxu.jia</who>
    <bug_when>2013-11-07 01:24:55 +0000</bug_when>
    <thetext>Merged into master ecf98b4288870be7ab62c3b040896b7877b50b35</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>38622</commentid>
    <comment_count>7</comment_count>
    <who name="Hongxu Jia">hongxu.jia</who>
    <bug_when>2013-11-07 01:27:03 +0000</bug_when>
    <thetext>Testing Case:
-----------------
1. Do configure and build a new kernel image rpm package.

2. Prepare a deployed target, and make sure your boot area has enough disk
   space (free space &gt;= 5MB).

3. Download the new kernel image rpm to the target.

4. Before install/update, check boot area and menu
root@qemux86-64:~# ls /boot/
grub        vmlinuz

root@qemux86-64:~# cat /boot/grub/grub.cfg
menuentry &quot;Linux&quot; {
    set root=(hd0,1)
    linux /vmlinuz root=/dev/hdb2  rw  console=tty0  quiet
}

4. Install/update bzImage
root@qemux86-64:~# rpm -i kernel-image-3.10.11-yocto-standard-3.10.12+git0+285f93bf94_702040ac7c-r0.qemux86_64.rpm 
Caution! Update kernel may affect kernel-module!
update-alternatives: Linking //boot/bzImage to bzImage-3.10.11-yocto-standard

5. After install/update, check boot area and menu
root@qemux86-64:~# ls /boot/ -al
drwxr-xr-x    4 root     root          1024 Sep 18 06:58 .
drwxr-xr-x   17 root     root          4096 Sep 18 06:41 ..
lrwxrwxrwx    1 root     root            30 Sep 18 06:58 bzImage -&gt; bzImage-3.10.11-yocto-standard
-rw-r--r--    1 root     root       5601808 Sep 18 06:45 bzImage-3.10.11-yocto-standard
drwxr-xr-x    4 root     root          1024 Sep 18 06:58 grub
-rwxr-x---    1 root     root       5601776 Sep 18 06:38 vmlinuz

root@qemux86-64:~# cat /boot/grub/grub.cfg 
menuentry &quot;Update bzImage-3.10.11-yocto-standard-3.10.12+gitAUTOINC+285f93bf94_702040ac7c&quot; {
    set root=(hd0,1)
    linux /bzImage-3.10.11-yocto-standard root=/dev/hdb2  rw  console=tty0  quiet
}
menuentry &quot;Linux&quot; {
    set root=(hd0,1)
    linux /vmlinuz root=/dev/hdb2  rw  console=tty0  quiet
}


6. Reboot target, &apos;Update bzImage-3.10.11-yocto-standard-3.10.12+gitAUTOINC+285f93bf94_702040ac7c&apos;
   will be in the boot menu.

7. It supports GRUB 0.97 in which use menu.lst rather than grub.cfg as config
   file.

8. If you install the same rpm more than one time with &apos;--force&apos;, there will
   be multiple kernel images in boot area and menu.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>38623</commentid>
    <comment_count>8</comment_count>
    <who name="Hongxu Jia">hongxu.jia</who>
    <bug_when>2013-11-07 01:28:34 +0000</bug_when>
    <thetext>(In reply to comment #7)
&gt; Testing Case:
&gt; -----------------
&gt; 1. Do configure and build a new kernel image rpm package.
&gt; 
Add INHERIT_append = &quot; kernel-grub&quot; in local.conf and build</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>39091</commentid>
    <comment_count>9</comment_count>
    <who name="Ionut Chisanovici">ionutx.chisanovici</who>
    <bug_when>2013-11-26 12:30:37 +0000</bug_when>
    <thetext>Tested and verified.
Multiple kernels are there, grub.cfg is updated, the option to choose between the kernels is available.

Ionut C.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>