Port-arm archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: Read-only FS, switch-off safety for raspberry pi



On Fri, 17 May 2019, Mayuresh wrote:
So I presume /var would be a ramdisk and root will be remounted ro or something like that?

Yes, that's one scenario.

I guess live-CD methods would require using build.sh, which is time taking on pi.

No, I don't think that'd be needed. You'll probably just want to customize some of the rc startup scripts. The way it's typically done is that you'd take a portion of your RAM to convert to read-write areas you'll need, copy the files you care about off the read-only media, then overlay mount the ramdisk on top of the area that needs write access, like say /var/log or whatever.

Is it possible to achieve the read-only mode by configuring a standard installation image?

Yes, I think it should be. It'd be easier if you are able to tolerate the file system being read/write for a short period during the boot process, but I think it'd be possible even without that help.

If it were me, I'd begin by looking at the init scripts on a NetBSD liveCD that's already been created. You can learn their secrets then fix the parts you don't like or don't work in your case. The NetBSD installation media also uses a ramdisk etc...

-Swift



Home | Main Index | Thread Index | Old Index