LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Debian (https://www.linuxquestions.org/questions/debian-26/)
-   -   Mounting Raspberry Pi SD card read-only (https://www.linuxquestions.org/questions/debian-26/mounting-raspberry-pi-sd-card-read-only-4175454325/)

Completely Clueless 03-16-2013 09:53 AM

Mounting Raspberry Pi SD card read-only
 
Hi all,

Got a little query about the Raspberry Pi I recently acquired which I've installed Raspbian on.
I see the system mounts the SD card r/w by default, even when the card's little switch is in the locked position.
I'd like it to be mounted r/o, however, in order to eliminate the corruption issues some of us are experiencing. But I'm not sure if this is feasible given the entire OS and everything else is on the one card.
Since the app I'm working on is for an embedded controller, I'm not bothered about losing logging, session data and such similar stuff that the system normally wants to write to the card.
Can I therefore change the defaults to mount the card r/o without adverse consequences?

Thanks, cc.

pan64 03-17-2013 03:18 AM

I suggest you to by a pendrive or split your sd into two (or more) partitions and move the log files and other files onto another (writable) partition. Changing /var to read only will probably lock the OS (there can be other dirs also).


All times are GMT -5. The time now is 12:03 PM.