path: root/meta/recipes-core/images
diff options
authorAlejandro Hernandez <>2016-12-20 23:08:40 +0000
committerRichard Purdie <>2017-01-31 14:40:19 +0000
commit3378c322247f5c261f40d06480379da9a24e3082 (patch)
tree6c624a5bf54455e25adf0cacaf8d6bed608d6779 /meta/recipes-core/images
parent97237259a9acb9a1511823914dea52b9719fbafd (diff)
core-image-tiny-initramfs: Fix error message shown after a successful initrd boot
When booting core-image-tiny-initramfs, since we want to live on initrd, on purpose, we never find a rootfs image to switch root to, this causes init to show an error as it would with other images, this patch replaces the message shown to the user, avoiding confusion when it was indeed a successful boot. Signed-off-by: Alejandro Hernandez <>
Diffstat (limited to 'meta/recipes-core/images')
1 files changed, 12 insertions, 0 deletions
diff --git a/meta/recipes-core/images/ b/meta/recipes-core/images/
index 846d58930e..184727ddf7 100644
--- a/meta/recipes-core/images/
+++ b/meta/recipes-core/images/
@@ -28,3 +28,15 @@ BAD_RECOMMENDATIONS += "busybox-syslog"
# Use the same restriction as initramfs-live-install
COMPATIBLE_HOST = "(i.86|x86_64).*-linux"
+python tinyinitrd () {
+ # Modify our init file so the user knows we drop to shell prompt on purpose
+ newinit = None
+ with open(d.expand('${IMAGE_ROOTFS}/init'), 'r') as init:
+ newinit =
+ newinit = newinit.replace('Cannot find $ROOT_IMAGE file in /run/media/* , dropping to a shell ', 'Poky Tiny Reference Distribution:')
+ with open(d.expand('${IMAGE_ROOTFS}/init'), 'w') as init:
+ init.write(newinit)