# Configuration

A Doltgres SQL server can be configured at server start time, or by setting system variables in the SQL session. The simplest way to configure server behavior is to provide a config file with the `--config` flag. Here's an example file:

```yaml
log_level: info

behavior:
  read_only: false

listener:
  host: localhost
  port: 5432
  read_timeout_millis: 28800000
  write_timeout_millis: 28800000
  
data_dir: /var/doltgres/dbs

cfg_dir: .doltcfg
```

The full list of supported fields can be found by running `doltgres --help`.

## System variables

Doltgres defines system variables that you can set in your session via the `SET` syntax. Many of these can be persisted, so they remain set after a server restart.

```sql
set dolt_transaction_commit 1;
```

A full list of available system variables can be found in the [docs on system variables](/reference/version-control/dolt-sysvars.md).


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.doltgres.com/reference/server/configuration.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
