> For the complete documentation index, see [llms.txt](https://docs.postgresql.tw/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.postgresql.tw/server-administration/runtime-config/runtime-config-preset.md).

# 19.15. Preset Options \#

The following “parameters” are read-only. As such, they have been excluded from the sample `postgresql.conf` file. These options report various aspects of PostgreSQL behavior that might be of interest to certain applications, particularly administrative front-ends. Most of them are determined when PostgreSQL is compiled or when it is installed.

`block_size` (`integer`)[#](#GUC-BLOCK-SIZE) : Reports the size of a disk block. It is determined by the value of `BLCKSZ` when building the server. The default value is 8192 bytes. The meaning of some configuration variables (such as [shared\_buffers](/server-administration/runtime-config/runtime-config-resource.md#GUC-SHARED-BUFFERS)) is influenced by `block_size`. See [Section 19.4](/server-administration/runtime-config/runtime-config-resource.md) for information.

`data_checksums` (`boolean`)[#](#GUC-DATA-CHECKSUMS) : Reports whether data checksums are enabled for this cluster. See [`-k`](/reference/reference-server/app-initdb.md#APP-INITDB-DATA-CHECKSUMS) for more information.

`data_directory_mode` (`integer`)[#](#GUC-DATA-DIRECTORY-MODE) : On Unix systems this parameter reports the permissions the data directory (defined by [data\_directory](/server-administration/runtime-config/runtime-config-file-locations.md#GUC-DATA-DIRECTORY)) had at server startup. (On Microsoft Windows this parameter will always display `0700`.) See [the initdb `-g` option](/reference/reference-server/app-initdb.md#APP-INITDB-ALLOW-GROUP-ACCESS) for more information.

`debug_assertions` (`boolean`)[#](#GUC-DEBUG-ASSERTIONS) : Reports whether PostgreSQL has been built with assertions enabled. That is the case if the macro `USE_ASSERT_CHECKING` is defined when PostgreSQL is built (accomplished e.g., by the `configure` option `--enable-cassert`). By default PostgreSQL is built without assertions.

`huge_pages_status` (`enum`)[#](#GUC-HUGE-PAGES-STATUS) : Reports the state of huge pages in the current instance: `on`, `off`, or `unknown` (if displayed with `postgres -C`). This parameter is useful to determine whether allocation of huge pages was successful under `huge_pages=try`. See [huge\_pages](/server-administration/runtime-config/runtime-config-resource.md#GUC-HUGE-PAGES) for more information.

`integer_datetimes` (`boolean`)[#](#GUC-INTEGER-DATETIMES) : Reports whether PostgreSQL was built with support for 64-bit-integer dates and times. As of PostgreSQL 10, this is always `on`.

`in_hot_standby` (`boolean`)[#](#GUC-IN-HOT-STANDBY) : Reports whether the server is currently in hot standby mode. When this is `on`, all transactions are forced to be read-only. Within a session, this can change only if the server is promoted to be primary. See [Section 26.4](/server-administration/high-availability/hot-standby.md) for more information.

`max_function_args` (`integer`)[#](#GUC-MAX-FUNCTION-ARGS) : Reports the maximum number of function arguments. It is determined by the value of `FUNC_MAX_ARGS` when building the server. The default value is 100 arguments.

`max_identifier_length` (`integer`)[#](#GUC-MAX-IDENTIFIER-LENGTH) : Reports the maximum identifier length. It is determined as one less than the value of `NAMEDATALEN` when building the server. The default value of `NAMEDATALEN` is 64; therefore the default `max_identifier_length` is 63 bytes, which can be less than 63 characters when using multibyte encodings.

`max_index_keys` (`integer`)[#](#GUC-MAX-INDEX-KEYS) : Reports the maximum number of index keys. It is determined by the value of `INDEX_MAX_KEYS` when building the server. The default value is 32 keys.

`num_os_semaphores` (`integer`)[#](#GUC-NUM-OS-SEMAPHORES) : Reports the number of semaphores that are needed for the server based on the configured number of allowed connections ([max\_connections](/server-administration/runtime-config/runtime-config-connection.md#GUC-MAX-CONNECTIONS)), allowed autovacuum worker processes ([autovacuum\_max\_workers](/server-administration/runtime-config/runtime-config-vacuum.md#GUC-AUTOVACUUM-MAX-WORKERS)), allowed WAL sender processes ([max\_wal\_senders](/server-administration/runtime-config/runtime-config-replication.md#GUC-MAX-WAL-SENDERS)), allowed background processes ([max\_worker\_processes](/server-administration/runtime-config/runtime-config-resource.md#GUC-MAX-WORKER-PROCESSES)), etc.

`segment_size` (`integer`)[#](#GUC-SEGMENT-SIZE) : Reports the number of blocks (pages) that can be stored within a file segment. It is determined by the value of `RELSEG_SIZE` when building the server. The maximum size of a segment file in bytes is equal to `segment_size` multiplied by `block_size`; by default this is 1GB.

`server_encoding` (`string`)[#](#GUC-SERVER-ENCODING) : Reports the database encoding (character set). It is determined when the database is created. Ordinarily, clients need only be concerned with the value of [client\_encoding](/server-administration/runtime-config/runtime-config-client.md#GUC-CLIENT-ENCODING).

`server_version` (`string`)[#](#GUC-SERVER-VERSION) : Reports the version number of the server. It is determined by the value of `PG_VERSION` when building the server.

`server_version_num` (`integer`)[#](#GUC-SERVER-VERSION-NUM) : Reports the version number of the server as an integer. It is determined by the value of `PG_VERSION_NUM` when building the server.

`shared_memory_size` (`integer`)[#](#GUC-SHARED-MEMORY-SIZE) : Reports the size of the main shared memory area, rounded up to the nearest megabyte.

`shared_memory_size_in_huge_pages` (`integer`)[#](#GUC-SHARED-MEMORY-SIZE-IN-HUGE-PAGES) : Reports the number of huge pages that are needed for the main shared memory area based on the specified [huge\_page\_size](/server-administration/runtime-config/runtime-config-resource.md#GUC-HUGE-PAGE-SIZE). If huge pages are not supported, this will be `-1`.

```
This setting is supported only on Linux. It
is always set to `-1` on other platforms. For more
details about using huge pages on Linux, see
[Section 18.4.5](../runtime/kernel-resources.md#LINUX-HUGE-PAGES).
```

`ssl_library` (`string`)[#](#GUC-SSL-LIBRARY) : Reports the name of the SSL library that this PostgreSQL server was built with (even if SSL is not currently configured or in use on this instance), for example `OpenSSL`, or an empty string if none.

`wal_block_size` (`integer`)[#](#GUC-WAL-BLOCK-SIZE) : Reports the size of a WAL disk block. It is determined by the value of `XLOG_BLCKSZ` when building the server. The default value is 8192 bytes.

`wal_segment_size` (`integer`)[#](#GUC-WAL-SEGMENT-SIZE) : Reports the size of write ahead log segments. The default value is 16MB. See [Section 28.5](/server-administration/wal/wal-configuration.md) for more information.

***

原文：[PostgreSQL 18.6 Documentation](https://www.postgresql.org/docs/18/runtime-config-preset.html)（英文原文，待翻譯）


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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, and the optional `goal` query parameter:

```
GET https://docs.postgresql.tw/server-administration/runtime-config/runtime-config-preset.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
