This site is in read only mode

From time to time after working for about two days site ends up in read only mode. Forum is completely empty, there are almost no users using it, so website is definitely not overloaded anyhow. I tried suggestions from the following thread Discourse stuck in maintenance mode

Is doesn’t help:

# cd /media/data/discourse/
root@main:/media/data/discourse# ./launcher enter app
x86_64 arch detected.
root@main-app:/var/www/discourse# rails c
Loading production environment (Rails 7.2.2.1)
discourse(prod)> Discourse.disable_readonly_mode
=> true
discourse(prod)> Discourse.disable_readonly_mode(Discourse::READONLY_MODE_KEY)
=> true
discourse(prod)> Discourse.disable_readonly_mode
=> true

Server is not overloaded with any other app / service:

Restarting redis along with database helps. But is there any logs that I should check or how can I troubleshoot this problem?

Discourse version is 3.5.0.beta3-dev

There’s some info here: Read Only Modes in Discourse

Is your service provider for redis or postgres reliable? A bad connection to those services may cause your forum to go into readonly. Another thing is if your disk space is reaching capacity. If your backups run every 2 days and you’re seeing this happen, then it could be a related cause.