# Write diagnostic logs to a file

Coordinator DB diagnostic files are configured in the server's required `logger` section. Choose a supported level, ordinary and error destinations, a rotation size and an archive count. This configuration is separate from SQL request history.

```xml
<logger>
    <level>information</level>
    <log>server.log</log>
    <errorlog>server.err.log</errorlog>
    <size>10M</size>
    <count>3</count>
</logger>
```

Place this section inside the existing `coordinator` root, then restart the server to apply it. Relative destinations start at the configuration directory, not at the directory of a database selected with `--db`. Check that the intended account can access the destination directory before restarting.

Supported diagnostic levels are `debug`, `information`, `warning`, `error`, `fatal` and `none`. A `trace` level and a client `send_logs_level` request setting are not documented interfaces. Use `debug` only when the extra detail is useful for the current investigation, and retain the rotation limits you need.

For request IDs, SQL duration, counters and exceptions, read the structured query log instead of trying to infer those fields from free-form file output.

See [logger settings](https://coordinatordb.com/docs/reference/settings/server-settings/settings/other) and [query history](https://coordinatordb.com/docs/reference/system-tables/query-log).
