Skip to content

read-only rootfs support

[email protected] openembedded-core 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest12 patches 18 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/12sysvinit: add ROOTFS_READ_ONLY variable to rcS-defaultmeta/recipes-core/sysvinit/sysvinit/rcS-default meta/recipes-core/sysvinit/sysvinit_2.88dsf.bb+5 -10 replies
2/12image.bbclass: add a hook funtion to support readonly rootfsmeta/classes/image.bbclass+18 -02 replies
3/12core-image.bbclass: support read-only rootfsmeta/classes/core-image.bbclass+4 -00 replies
4/12package.bbclass: add VOLATILE_DIR and VOLATILE_LINK to PACKAGEVARSmeta/classes/package.bbclass+3 -10 replies
5/12volatiles.bbclass: add recipemeta/classes/volatiles.bbclass+11 -06 replies
6/12volatiles_sysvinit.bbclass: add recipemeta/classes/volatiles_sysvinit.bbclass+49 -00 replies
7/12populate-volatile.sh: improve this scriptmeta/recipes-core/initscripts/initscripts-1.0/populate-volatile.sh+143 -1440 replies
8/12initscripts: let populate-volatile.sh create the /tmp linkmeta/recipes-core/initscripts/initscripts-1.0/bootmisc.sh meta/recipes-core/initscripts/initscripts-1.0/volatiles+2 -83 replies
9/12initscripts: inherit volatiles to support read-only rootfsmeta/recipes-core/initscripts/initscripts_1.0.bb+5 -14 replies
10/12dropbear: inherit volatiles to support read-only rootfsmeta/recipes-core/dropbear/dropbear.inc+5 -20 replies
11/12nfs-utils: inherit volatiles to support read-only rootfsmeta/recipes-connectivity/nfs-utils/nfs-utils_1.2.3.bb+5 -20 replies
12/12dbus: inherit volatiles to support read-only rootfsmeta/recipes-core/dbus/dbus.inc+5 -23 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCH 00/12] read-only rootfs support

From: Chen Qi <[email protected]>

The series of patches add support to read-only rootfs.

The main idea is to use symbolic links to create the illuion that some directories are writable in case of a read-only rootfs.

We use a similar stragety to update-rc.d.bbclass to manage all the recipes that need to tweak some specific directories to support a read-only rootfs. These recipes inherit volatiles.bbclass and set VOLATILE_DIR, VOLATILE_LINK and VOLATILE_PKGS properly.

The advantage of this strategy is that it deligates the task of supporting read-only rootfs to the recipes, resulting in a better management scheme.

This set of patches have been tested on minimal images with and without 'read-only-rootfs' image feature enabled. Everything is OK.

For sato images, everything is the same as before if 'read-only-rootfs' is not enabled. With 'read-only-rootfs' enabled, sato image could work if graphic interface is diabled. When all postinstall problems are resolved, sato image should work well.

The following changes since commit 37e025f6f9c410005e0f1dee0767e38eaec01cbd:

bitbake: hob: Hob should display warnings generated during parsing (2013-01-21 19:05:31 +0000)

are available in the git repository at:

git://git.pokylinux.org/poky-contrib ChenQi/readonly-rootfs
http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=ChenQi/readonly-rootfs

Chen Qi (12):
sysvinit: add ROOTFS_READ_ONLY variable to rcS-default image.bbclass: add a hook funtion to support readonly rootfs core-image.bbclass: support read-only rootfs package.bbclass: add VOLATILE_DIR and VOLATILE_LINK to PACKAGEVARS volatiles.bbclass: add recipe volatiles_sysvinit.bbclass: add recipe populate-volatile.sh: improve this script
initscripts: let populate-volatile.sh create the /tmp link
initscripts: inherit volatiles to support read-only rootfs
dropbear: inherit volatiles to support read-only rootfs
nfs-utils: inherit volatiles to support read-only rootfs
dbus: inherit volatiles to support read-only rootfs

 meta/classes/core-image.bbclass                    |    4 +
 meta/classes/image.bbclass                         |   18 ++
 meta/classes/package.bbclass                       |    4 +-
 meta/classes/volatiles.bbclass                     |   11 +
 meta/classes/volatiles_sysvinit.bbclass            |   49 ++++
 .../nfs-utils/nfs-utils_1.2.3.bb                   |    7 +-
 meta/recipes-core/dbus/dbus.inc                    |    7 +-
 meta/recipes-core/dropbear/dropbear.inc            |    7 +-
 .../initscripts/initscripts-1.0/bootmisc.sh        |    9 +-
 .../initscripts-1.0/populate-volatile.sh           |  287 ++++++++++----------
 .../initscripts/initscripts-1.0/volatiles          |    1 +
 meta/recipes-core/initscripts/initscripts_1.0.bb   |    6 +-
 meta/recipes-core/sysvinit/sysvinit/rcS-default    |    4 +
 meta/recipes-core/sysvinit/sysvinit_2.88dsf.bb     |    2 +-
 14 files changed, 255 insertions(+), 161 deletions(-)
 create mode 100644 meta/classes/volatiles.bbclass
 create mode 100644 meta/classes/volatiles_sysvinit.bbclass
Signature · 1 line
1.7.9.5