LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   Ignore ext4 errors and force mount read-write (with broken fsck)? (https://www.linuxquestions.org/questions/linux-software-2/ignore-ext4-errors-and-force-mount-read-write-with-broken-fsck-4175618257/)

Jason_25 11-23-2017 07:31 PM

Ignore ext4 errors and force mount read-write (with broken fsck)?
 
I frequently get into a position with my Raspberry Pi devices where the OS becomes read-only. The actual reason for the corruption is varied.

I did not make this decision but the version of fsck shipped is incompatible with the installed filesystem.

The most important point here is that I am unwilling to fix the problem by updating fsck because I want the system to boot always without trying to run fsck. I refuse to accept that the only way to fix this problem is through fsck. The OS did something (without the use of fsck because it won't run) to mark the drive read-only - I want to reverse this no matter what!!!

To be more clear:
1. I want to ignore filesystem errors in every situation and try to boot EVERY TIME without ever remounting read-only.
2. I don't care if the entire system melts down as long as it tries to mount the freaking disk read-write every time.
3. My only concern is setting the system to favor absolute uptime vs absolute data integrity.

How may I (preferably permanently) mark the disk as read write, considering the installed version of fsck is broken?

syg00 11-23-2017 08:01 PM

So you deliberately haven't told what the filesystem is, because you don't want help, you just want to continue using potentially corrupt data, and probably make it worse. That's ok, it's your data.
"man fstab".

If you really want consistent data, don't use sdcards.

Edit: oops, missed ext4 in the subject. My bad. You can run ext4 without a journal, so it acts like ext2 did. Not that I'm recommending it.

Jason_25 11-24-2017 09:17 AM

I'm not sure removing the journal is what I want to do. When manually remounting read-write it says the micro sd card is write protected. I would like to find out the mechanism that sets the micro sd to "write protected" in the first place. Is the kernel itself setting the filesystem to write protected? There is no damage to the micro sd cards. If you reformat, repartition or dd them they work fine.

edit:
It seems that the problem was simply with the fstab file. If you remove errors=remount,ro then no more holding up the boot. What a relief.


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