this is my first post - I could not find anybody mentioning a similar problem here - maybe the community can help (and I guess this topic is also interesting for others).
My name is Birk, I’m utilizing quiet some raspberry for different purposes (Video recorder, pihole, home automation, octoprint) and I really like the lightweight dietPi distribution.
My goal it to create a dietpi read only system. Application would be something like a small webradio using mpd, maybe an octoprint, printserver etc.
Major goal: I just want to “switch it off” (This also increases highly the WAF (woman acceptance factor)) without shutting the system down.
I got more or less everything working using my script which I published here:
https://github.com/bdynamic/raspberry_tools/blob/master/readonly/system_readonly_prep.sh (relevant lines: 46-73)
only thing missing is the resolv.conf
I tried several solutions:
- Simply move it to /tmp and create a symbolic link to it
- Create a dhclient-enter-hooks (seems to create the destination file to late)
- Modify the /sbin/dhclient-script
The symbolic link solution is recommended in a lot of Linux posts but unfortunately doesn’t do the trick.
I using some Raspberry first generation and 3rd generation systems.
Hope somebody can give a hint.