<div dir="ltr">Every directory, which needs to be writable and persistent, needs to be mounted as unionfs or AUFS, with one branch in read-only partition, and the second one somewhere in /var. It's good to mount /etc that way and place the factory defaults in the read-only branch of this. An alternative is to allow only several files in /etc to be writable and move them to someplace in /var (e.g. /var/etc) and leave symlinks in /etc (e.g. /etc/resolv.conf -> /var/etc/resolv.conf).<br> </div><div class="gmail_extra"><br><br><div class="gmail_quote">On Wed, Oct 16, 2013 at 2:48 PM, Francisco Ares <span dir="ltr"><<a href="mailto:frares@gmail.com" target="_blank">frares@gmail.com</a>></span> wrote:<br> <blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><div><div><div>Hi.<br><br></div>I am planning to build a system to be deployed in a SATA flash disk, and most of the file system will be read-only. There will be a tempfs on /temp and a read-write partition for /var (perhaps a unionfs with the static part of /var and that read-write partition)<br> <br></div>Is there any resources on how to do this using Gentoo?<br><br></div>There is already a development system with everything working as expected on the final system. But when I put it to a squashfs, the system boots with several errors, like when trying to write to /etc and /var.<br> <br></div><div>Looking on the new issue regarding /usr and / being on a different partitions, I have found the file in /etc/initramfs.mounts. I have added the needed fstab entries to be mounted before the system switches to the real-root, (as the comments on top of this file claims) but there are still errors during boot.<br> </div><div><br></div>Thanks<span class="HOEnZb"><font color="#888888"><br>Francisco<br></font></span></div> </blockquote></div><br></div>