<div dir="ltr"><div>Hi Manik,</div><div><br></div><div>Thanks for your information.</div><div>I have followed the steps from the link you shared with us. And I have successfully built the image and boot the hardware. But I have a few questions about the process to build customized Linux kernel snap and include it in the image.</div><div><br></div><div>Let me explain what I have done first.</div><div>1. Use pc-kernel to build the kernel snap.</div><div>In assertion, include below field:</div><div> "kernel": "pc-kernel"</div><div><br></div><div>Result: The image works fine on hardware.</div><div><br></div><div>2. Build the kernel snap by myself. The source code is from <a href="https://git.launchpad.net/~ubuntu-kernel/ubuntu/+source/linux-snap/+git/xenial">https://git.launchpad.net/~ubuntu-kernel/ubuntu/+source/linux-snap/+git/xenial</a></div><div>Then I could build the image with the kernel snap built by myself (by modifying "kernel" field in assertion and also change the command line parameter)</div><div>#/snap/bin/ubuntu-image -c beta -o snap_test.img test.model --extra-snaps pc-kernel_4.4.0-45-4_amd64.snap</div><div><br></div><div>Result: The image works fine.</div><div><br></div><div>3. Build the kernel snap from source code. <a href="http://kernel.ubuntu.com/git/ubuntu/ubuntu-xenial.git/">http://kernel.ubuntu.com/git/ubuntu/ubuntu-xenial.git/</a>, tag Ubuntu-4.4.0-49.70.</div><div>Then I could build the image with the kernel snap built by myself.</div><div><br></div><div>Result: The image does not work. The kernel boot hangs at</div><div>================================================================================</div><div>[ 23.415517] random: udevadm: uninitialized urandom read (16 bytes read, 5 bits of entropy available)</div><div>[ 23.415735] random: udevadm: uninitialized urandom read (16 bytes read, 5 bits of entropy available)</div><div>[ 23.415982] random: udevadm: uninitialized urandom read (16 bytes read, 5 bits of entropy available)</div><div>================================================================================</div><div><br></div><div>I am confused about two repos for the kernel (2 and 3). Looks like the kernel repo in method 2 does not build everything from source code, but the repo in method 3 does.</div><div>Which repo should I use as the base to customize the kernel and add additional drivers?</div><div><br></div><div>Thanks!</div><div><br></div><div>Peng</div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Nov 15, 2016 at 11:07 PM, Manik Taneja <span dir="ltr"><<a href="mailto:manik@canonical.com" target="_blank">manik@canonical.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote"><span class="gmail-">On Tue, Nov 15, 2016 at 8:17 PM, Peng Liu <span dir="ltr"><<a href="mailto:pengliu.mail@gmail.com" target="_blank">pengliu.mail@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">Hi Folks,<div><br></div><div>I have a related question.</div><div>After we build the kernel snap, how can we replace the default kernel snap if we use the image from ubuntu?</div><div><a href="http://releases.ubuntu.com/ubuntu-core/16/" target="_blank">http://releases.ubuntu.com/ubu<wbr>ntu-core/16/</a></div><div><br></div><div>I tried that but snap command reported an error like "cannot replace signed ** snap with an unasserted one".</div><div>Thanks.</div></div></blockquote></span><div>Please follow the process to create your own custom Ubuntu Core image here-<br><br><a href="http://docs.ubuntu.com/core/en/guides/build-device/image-building" target="_blank">http://docs.ubuntu.com/core/<wbr>en/guides/build-device/image-<wbr>building</a><br><br></div><div>and let us know how that goes.<br><br></div><div>Cheers,<br></div><div>Manik<br></div></div></div></div>
</blockquote></div><br></div></div>