# Gateway Faulted - Attempt to write to read only database

**URL:** <https://forum.inductiveautomation.com/t/gateway-faulted-attempt-to-write-to-read-only-database/73309>\
**Category:** Ignition\
**Created:** [May 5, 2023, 5:34am UTC](https://forum.inductiveautomation.com/t/gateway-faulted-attempt-to-write-to-read-only-database/73309 "2023-05-05T05:34:41Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![lachlan.wearden](https://avatars.discourse-cdn.com/v4/letter/l/df788c/32.png) [@lachlan.wearden](https://forum.inductiveautomation.com/u/lachlan.wearden)\
**Post date:** [May 5, 2023, 5:34am UTC](https://forum.inductiveautomation.com/t/gateway-faulted-attempt-to-write-to-read-only-database/73309/1 "2023-05-05T05:34:42Z")

</div>

Hello, I previously had a ignition gateway running on a raspberry pi 4b. Opon a restart of the pi I get this error when trying to start the gateway. I'm very new to Linux so any help on how to resolve this would be appreciated!

```auto
INFO | jvm 1 | 2023/05/05 15:22:10 | 15:22:10,273 |-ERROR in com.inductiveautomation.logging.SQLiteAppender[DB] - problem appending event org.sqlite.SQLiteException: [SQLITE_READONLY] Attempt to write a readonly database (attempt to write a readonly database)
INFO | jvm 1 | 2023/05/05 15:22:10 | at org.sqlite.SQLiteException: [SQLITE_READONLY] Attempt to write a readonly database (attempt to write a readonly database)
INFO | jvm 1 | 2023/05/05 15:22:10 | at at org.sqlite.core.DB.newSQLException(DB.java:1141)
INFO | jvm 1 | 2023/05/05 15:22:10 | at at org.sqlite.core.DB.newSQLException(DB.java:1152)
INFO | jvm 1 | 2023/05/05 15:22:10 | at at org.sqlite.core.DB.execute(DB.java:950)
INFO | jvm 1 | 2023/05/05 15:22:10 | at at org.sqlite.core.DB.executeUpdate(DB.java:1016)
INFO | jvm 1 | 2023/05/05 15:22:10 | at at org.sqlite.jdbc3.JDBC3PreparedStatement.executeUpdate(JDBC3PreparedStatement.java:90)
INFO | jvm 1 | 2023/05/05 15:22:10 | at at com.inductiveautomation.logging.SQLiteAppender.subAppend(SQLiteAppender.java:564)
INFO | jvm 1 | 2023/05/05 15:22:10 | at at com.inductiveautomation.logging.SQLiteAppender.batchAppend(SQLiteAppender.java:503)
INFO | jvm 1 | 2023/05/05 15:22:10 | at at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
INFO | jvm 1 | 2023/05/05 15:22:10 | at at java.base/java.util.concurrent.FutureTask.runAndReset(Unknown Source)
INFO | jvm 1 | 2023/05/05 15:22:10 | at at java.base/java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(Unknown Source)
INFO | jvm 1 | 2023/05/05 15:22:10 | at at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
INFO | jvm 1 | 2023/05/05 15:22:10 | at at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
INFO | jvm 1 | 2023/05/05 15:22:10 | at at java.base/java.lang.Thread.run(Unknown Source)

```

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [May 5, 2023, 12:35pm UTC](https://forum.inductiveautomation.com/t/gateway-faulted-attempt-to-write-to-read-only-database/73309/2 "2023-05-05T12:35:47Z")

</div>

That looks like a folder permissions issue. Like the prior install was set to run as root, and the current install is set to run as an unprivileged (or less-privileged) user. The latter is wise, but can take some extra setup (or a completely clean install with the service user parameter set).
