MiSTer-devel / Linux_Image_creator_MiSTer

GNU General Public License v2.0
18 stars 10 forks source link

Add support for persistent network config files #17

Closed wizzomafizzo closed 1 year ago

wizzomafizzo commented 1 year ago

Hi. I want to propose this change, or something like this, to fix the long standing issue of network configurations on MiSTer not persisting through Linux updates.

This adds a new init script to the image which will copy custom network configuration files during boot before the network is started. They're copied from the linux/network directory on the SD card.

It copies these files over:

I'm open to suggestions on alternative ways to achieve this or ways the script could be modified to work better.

sorgelig commented 1 year ago

I don't like this solution at all. It mounts system volume as read/write and writes to it on every boot which is opposite to original idea of keeping system volume from writing as much as possible to prevent corruptions. This is why you can turn MiSTer off without safe shutdown procedure.

It's not a problem for those who can accept the risk. It needs minimum change and can be done by a script which will inject required file. So you just run this script once after linux update. But i cannot accept it as a default option.

wizzomafizzo commented 1 year ago

I don't like this solution at all. It mounts system volume as read/write and writes to it on every boot which is opposite to original idea of keeping system volume from writing as much as possible to prevent corruptions. This is why you can turn MiSTer off without safe shutdown procedure.

The idea of the copy function was to only do so if changes are made, so write would not happen every boot. But I see your point and I agree, it's an awkward exception and is a risk.

I like the idea of tackling it from the update end. Thanks for giving me your thoughts