Server Settings

Lazy loading of dictionaries.

- If `true`, then each dictionary is loaded on the first use. If the loading is failed, the function that was using the dictionary throws an exception.
- If `false`, then the server loads all dictionaries at startup.

Note

The server will wait at startup until all the dictionaries finish their loading before receiving any connections
(exception: if [`wait_dictionaries_load_at_startup`](/docs/operations/server-configuration-parameters/settings#wait_dictionaries_load_at_startup) is set to `false`).

**Example**

```
<dictionaries_lazy_load>true</dictionaries_lazy_load>
```

## dictionaries\_lib\_path[​](#dictionaries_lib_path "Direct link to dictionaries_lib_path")

The directory with dictionaries lib.

**Example**

```
<dictionaries_lib_path>/var/lib/clickhouse/dictionaries_lib/</dictionaries_lib_path>
```

## dictionary\_background\_reconnect\_interval[​](#dictionary_background_reconnect_interval "Direct link to dictionary_background_reconnect_interval")

Interval in milliseconds for reconnection attempts of failed MySQL and Postgres dictionaries having `background_reconnect` enabled.

## disable\_insertion\_and\_mutation[​](#disable_insertion_and_mutation "Direct link to disable_insertion_and_mutation")

Disable insert/alter/delete queries. This setting will be enabled if someone needs read-only nodes to prevent insertion and mutation affect reading performance. Inserts into external engines (S3, DataLake, MySQL, PostrgeSQL, Kafka, etc) are allowed despite this setting.

## disable\_internal\_dns\_cache[​](#disable_internal_dns_cache "Direct link to disable_internal_dns_cache")

Disables the internal DNS cache. Recommended for operating ClickHouse in systems with frequently changing infrastructure such as Kubernetes.

## disable\_tunneling\_for\_https\_requests\_over\_http\_proxy[​](#disable_tunneling_for_https_requests_over_http_proxy "Direct link to disable_tunneling_for_https_requests_over_http_proxy")

By default, tunneling (i.e, `HTTP CONNECT`) is used to make `HTTPS` requests over `HTTP` proxy. This setting can be used to disable it.

**no\_proxy**

By default, all requests will go through the proxy. In order to disable it for specific hosts, the `no_proxy` variable must be set.
It can be set inside the `<proxy>` clause for list and remote resolvers and as an environment variable for environment resolver.
It supports IP addresses, domains, subdomains and `'*'` wildcard for full bypass. Leading dots are stripped just like curl does.

**Example**

The below configuration bypasses proxy requests to `clickhouse.cloud` and all of its subdomains (e.g, `auth.clickhouse.cloud`).
The same applies to GitLab, even though it has a leading dot. Both `gitlab.com` and `about.gitlab.com` would bypass the proxy.

```
<proxy>
    <no_proxy>clickhouse.cloud,.gitlab.com</no_proxy>
    <http>
        <uri>http://proxy1</uri>
        <uri>http://proxy2:3128</uri>
    </http>
    <https>
        <uri>http://proxy1:3128</uri>
    </https>
</proxy>
```

## disk\_connections\_hard\_limit[​](#disk_connections_hard_limit "Direct link to disk_connections_hard_limit")

Exception is thrown at a creation attempt when this limit is reached. Set to 0 to turn off hard limitation. The limit applies to the disks connections.

## disk\_connections\_soft\_limit[​](#disk_connections_soft_limit "Direct link to disk_connections_soft_limit")

Connections above this limit have significantly shorter time to live. The limit applies to the disks connections.

## disk\_connections\_store\_limit[​](#disk_connections_store_limit "Direct link to disk_connections_store_limit")

Connections above this limit reset after use. Set to 0 to turn connection cache off. The limit applies to the disks connections.

## disk\_connections\_warn\_limit[​](#disk_connections_warn_limit "Direct link to disk_connections_warn_limit")

Warning massages are written to the logs if number of in-use connections are higher than this limit. The limit applies to the disks connections.

## disk\_transaction\_wait\_for\_blob\_removal[​](#disk_transaction_wait_for_blob_removal "Direct link to disk_transaction_wait_for_blob_removal")

Default value for the per-disk `wait_for_blob_removal` setting.
When enabled, the server waits for background blob removal to complete before acknowledging the operation.

## display\_secrets\_in\_show\_and\_select[​](#display_secrets_in_show_and_select "Direct link to display_secrets_in_show_and_select")

Enables or disables showing secrets in `SHOW` and `SELECT` queries for tables, databases, table functions, and dictionaries.

User wishing to see secrets must also have
[`format_display_secrets_in_show_and_select` format setting](/docs/operations/settings/formats#format_display_secrets_in_show_and_select)
turned on and a
[`displaySecretsInShowAndSelect`](/docs/sql-reference/statements/grant#displaysecretsinshowandselect) privilege.

Possible values:

- `0` — Disabled.
- `1` — Enabled.

## distributed\_cache\_apply\_throttling\_settings\_from\_client[​](#distributed_cache_apply_throttling_settings_from_client "Direct link to distributed_cache_apply_throttling_settings_from_client")

Whether cache server should apply throttling settings received from client.

## distributed\_cache\_keep\_up\_free\_connections\_ratio[​](#distributed_cache_keep_up_free_connections_ratio "Direct link to distributed_cache_keep_up_free_connections_ratio")

Soft limit for number of active connection distributed cache will try to keep free. After the number of free connections goes below distributed\_cache\_keep\_up\_free\_connections\_ratio \* max\_connections, connections with oldest activity will be closed until the number goes above the limit.

## distributed\_ddl[​](#distributed_ddl "Direct link to distributed_ddl")

Manage executing [distributed ddl queries](/docs/sql-reference/distributed-ddl) (`CREATE`, `DROP`, `ALTER`, `RENAME`) on cluster.
Works only if [ZooKeeper](/docs/operations/server-configuration-parameters/settings#zookeeper) is enabled.

The configurable settings within `<distributed_ddl>` include:

|  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |
| --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- |
| Setting Description Default Value|  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  | | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | | `cleanup_delay_period` cleaning starts after new node event is received if the last cleaning wasn't made sooner than `cleanup_delay_period` seconds ago. `60` seconds| `max_tasks_in_queue` the maximum number of tasks that can be in the queue. `1,000`| `path` the path in Keeper for the `task_queue` for DDL queries |  |  |  |  |  |  |  |  |  | | --- | --- | --- | --- | --- | --- | --- | --- | --- | | `pool_size` how many `ON CLUSTER` queries can be run simultaneously |  |  |  |  |  |  | | --- | --- | --- | --- | --- | --- | | `profile` the profile used to execute the DDL queries |  |  |  | | --- | --- | --- | | `task_max_lifetime` delete node if its age is greater than this value. `7 * 24 * 60 * 60` (a week in seconds) | | | | | | | | | | | | | | | | | | | | |

**Example**

```
<distributed_ddl>
    <!-- Path in ZooKeeper to queue with DDL queries -->
    <path>/clickhouse/task_queue/ddl</path>

    <!-- Settings from this profile will be used to execute DDL queries -->
    <profile>default</profile>

    <!-- Controls how much ON CLUSTER queries can be run simultaneously. -->
    <pool_size>1</pool_size>

    <!--
         Cleanup settings (active tasks will not be removed)
    -->

    <!-- Controls task TTL (default 1 week) -->
    <task_max_lifetime>604800</task_max_lifetime>

    <!-- Controls how often cleanup should be performed (in seconds) -->
    <cleanup_delay_period>60</cleanup_delay_period>

    <!-- Controls how many tasks could be in the queue -->
    <max_tasks_in_queue>1000</max_tasks_in_queue>
</distributed_ddl>
```

## distributed\_ddl.cleanup\_delay\_period[​](#distributed_ddl.cleanup_delay_period "Direct link to distributed_ddl.cleanup_delay_period")