# read-only-mode-already-enabled

**Read-only mode** is **on already**, so enabling it changes nothing.

- **Route:** `enable-read-only-mode`
- **Description:** `read-only mode is already enabled: it lasts until the store is restarted without read-only mode`
- **Details:** None; `details` is an empty object.

## Why It Happens

**[Read-only mode](/docs/eventsourcingdb/read-only-mode)** was switched on before, either when the server started, with the **`--read-only`** flag, or through an earlier request to `enable-read-only-mode`. It **never ends while the server runs**, so enabling it again finds it on. Of several requests that enable it at the same time, exactly one succeeds, and the others receive this error.

Only read-only mode itself counts. A database that refuses writes for another reason, such as one that reports **[`disk-full`](/docs/eventsourcingdb/errors/disk-full)** or **[`store-failed`](/docs/eventsourcingdb/errors/store-failed)**, enters read-only mode as usual, since read-only mode outlasts such a cause.

## How to Fix It

There is nothing to fix: the database is in read-only mode, as the request asks for, so a client that only wants read-only mode can **take this error as success**. Sending the request again answers the same way until the server is restarted without read-only mode.

## Example

For a request to enable read-only mode while it is on already, EventSourcingDB answers with this error:

```json
{
  "type": "error",
  "data": {
    "code": "https://docs.eventsourcingdb.io/errors/read-only-mode-already-enabled",
    "description": "read-only mode is already enabled: it lasts until the store is restarted without read-only mode",
    "details": {}
  }
}
```
