Bug 5164

Summary: Live image's initramfs should distinguish between iso and hddimg
Product: [Build System, Metadata & Runtime] OE-Core Reporter: Chen Qi <Qi.Chen>
Component: coreAssignee: Chen Qi <Qi.Chen>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: Medium+ CC: liezhi.yang, mark.hatle, meta.mr.watcher, meta.watcher, ross.burton, sgw, yi.zhao
Version: 1.5   
Target Milestone: 1.5 M5   
Hardware: x86   
OS: Multiple   
Whiteboard:
OS type for building Yocto: --- Type of Regression: ---
Verified: Documentation change: No (bug/feature does not impact docs)

Description Chen Qi 2013-09-11 04:48:58 UTC
Problem description:
"atom-pc/genericx86 with hddimg used to be read-write, now its read-only with a tmpfs"

I guess the problem has been there for a long time. Things just happened to work correctly. Now that aufs has been enabled by default in our kernel, this problem is revealed.

The root cause is that our iso and hddimg share a common concept of 'live image', and they actually use the same initramfs and thus the same init.

That init script in initramfs made a wrong assumption that the rootfs image was 'read-only' by itself. This assumption apparently doesn't apply to hddimg.

So at a minimum, the init script in initramfs should distinguish between iso and hddimg, or in other words, it should check whether the rootfs image is read-only by itself.

//Chen Qi
Comment 1 Chen Qi 2013-09-12 06:04:57 UTC
Branch: master
Commit: 29f869b68a9017502f75915784a924f0fe9d4be1
URL:    http://git.openembedded.org/?p=openembedded-core.git&a=commit;h=29f869b68a9017502f75915784a924f0fe9d4be1

P.S.
This is a workaround for now. In the future, I think we should rework some of code, add recipes (maybe initramfs related) to achieve this goal.

Valentin's patch of separating iso and hddimg in image types should be the first step to achieve this goal.
patch titile: image types: split live into iso and hddimg