Read only filesystem, can't fix permissions

Raspberry 4 4GB
openHAB 3.3.0 - Release Build

Hi there,
my logs stopped working. It isn’t the first time this was happening. Last time I was able to fix this issue when deleting the logs ending with a number. .1, .2, .3 etc.

When I tried to delete the logs a error message said “read only filesystem”.
An another thread said it could be fixed by uninstalling and resintalling zram.
Unfortunately it didn’t fix it.
I tried to use the “Fix Permissions” settings via openhabian-config, but this gives me an error, too.

Applying file permissions recommendations... FAILED (openhab folders)
FAILED (folders)

It looks like my installation is working fine, except for the logs.

Any idea how I can fix this without reinstalling my Pi?


how does the system behave when zram is deinstalled ?
In case permissions cannot be fixed once zram is deinstalled I would assume a problem with the sd card.

It is exactly the same. Uninstalling zram and trying to fix permission shows the same error :frowning:

I think I got this “read only filesystem” issue some time ago. But I can’t remember how I fixed it the last time :sweat_smile:

  • new installation on a fresh SD card ?
  • file system check with repair option ?

Does the dmesg command return any use full information about root cause ?
Does the journalctl command return anything ?
In case all these commands rely on stored message then it may not work if nothing is written to the card.

I wasn’t able to find the root cause for this issue so I decided to do a fresh install with a new sd card.
The backup script was still working fine. So the restore wasn’t too much effort…
Hopefully the problem with the non working logs is now gone.

Thanks for your help.

1 Like

I had the same issue. In my case the root cause was excessive logging from zigbee2mqtt. At a certain point the file system switched to read-only.Turning down the log level solved the problem. Maybe checking your log levels could help too.

Thank you for the hint.
I took a look into the logs before it was read only.
Maybe you are right. I got a Shelly which failed.
The „last contact channel“ was logging every second the failed connection.
I removed the channel, maybe this will help to prevent the issue from happening again.