initdb

initdb — создать кластер баз данных Postgres Pro Shardman

Синтаксис

initdb [параметр...] [ --pgdata | -D ]каталог

Описание #

Команда initdb создаёт новый кластер баз данных Postgres Pro Shardman.

Создание кластера баз данных заключается в создании каталогов для хранения данных кластера, формировании общих системных таблиц (относящихся ко всему кластеру, а не к какой-либо базе) и создании баз данных postgres, template1 и template0. База postgres используется пользователями, утилитами и сторонними приложениями по умолчанию. Базы template1 и template0 предназначены для использования в качестве исходных баз данных, копии которых будут создавать последующие команды CREATE DATABASE. Базу template0 не следует изменять никогда, но вы можете добавлять объекты в template1, и они по умолчанию будут копироваться в базы данных, создаваемые позже. За подробностями обратитесь к Разделу 21.4.

При попытке создать каталог для хранения данных initdb может столкнуться с нехваткой прав доступа, если этот каталог принадлежит суперпользователю root. В таком случае необходимо назначить пользователя базы данных владельцем этого каталога при помощи chown. Затем выполнить su для смены пользователя и дальнейшего выполнения initdb.

Команда initdb должна выполняться от имени пользователя, под которым будет запускаться сервер, так как ему необходим полный доступ к файлам и каталогам, создаваемым initdb. Сервер не может запускаться от имени суперпользователя, поэтому выполнение команды initdb от его лица будет отклонено.

Из соображений безопасности новый кластер, созданный программой initdb, будет доступен только для владельца кластера. Ключ --allow-group-access позволяет разрешить чтение файлов в кластере всем пользователям, входящим в группу владельца кластера. Это полезно для выполнения резервного копирования от имени непривилегированного пользователя.

initdb инициализирует локали и кодировки баз данных кластера, которые будут использоваться по умолчанию. Они могут устанавливаться раздельно при создании новой базы данных. initdb определяет параметры локали для шаблонных баз данных, применяющиеся по умолчанию для новых баз.

По умолчанию initdb получает параметры локали из переменных среды и определяет кодировку, исходя из параметров локали. Если провайдер локалей не задан, он выбирается автоматически на основании значения lc_collate для кластера: для локалей C и POSIX выбирается libc, а для других локалей — icu.

Выбрать другую локаль для кластера позволяет параметр --locale. Существуют также отдельные параметры --lc-* и --icu-locale (см. ниже), позволяющие задать значения для отдельных категорий локали. Учтите, что с неподходящими значениями для разных категорий локали результаты могут быть бессмысленными, поэтому эти значения следует выбирать продуманно.

В качестве библиотеки, реализующей поддержку локалей, initdb может также использовать библиотеку ICU, если указать --locale-provider=icu. При этом сервер должен быть собран с поддержкой ICU. Выбрать определённую локаль ICU позволяет параметр --icu-locale. Заметьте, что даже когда используется провайдер локалей ICU, initdb в любом случае выбирает и инициализирует локали libc в связи с особенностями реализации и для поддержки старого кода.

Когда команда initdb выполняется, она показывает, какие параметры локали выбраны. Если вы задавали комбинацию параметров или у вас есть особые требования, рекомендуется проверить, соответствует ли результат ожиданиям.

Подробнее о параметрах локали можно узнать в Разделе 22.1.

Для изменения кодировки по умолчанию используется параметр --encoding. Узнать об этом больше можно в Разделе 22.3.

Параметры

-A authmethod
--auth=authmethod #

Параметр определяет метод аутентификации по умолчанию для локальных пользователей, используемый в файле pg_hba.conf (строки host и local). Допустимые значения описаны в Разделе 19.1.

Программа initdb предварительно внесёт указанный метод аутентификации в pg_hba.conf в записи как обычных соединений, так и соединений репликации.

Не используйте trust, если не можете доверять всем локальным пользователям в вашей системе. Режим trust используется по умолчанию для облегчения процесса установки.

--auth-host=authmethod #

Параметр указывает метод аутентификации для локальных пользователей, подключающихся по TCP/IP, используемый в pg_hba.conf (строки host).

--auth-local=authmethod #

Параметр выбирает метод аутентификации локальных пользователей, подключающихся через Unix-сокет, используемый в pg_hba.conf (строки local).

-D каталог
--pgdata=каталог #

Параметр указывает каталог хранения данных кластера. Это единственный обязательный параметр для команды initdb. При этом его можно указать в переменной окружения PGDATA, что будет удобным при дальнейшем использовании (postgres обращается к этой же переменной).

-E кодировка
--encoding=кодировка #

Устанавливает кодировку по умолчанию для баз-шаблонов. Эта кодировка будет по умолчанию выбираться и для баз данных, создаваемых позже, если вы не переопределите её. Наборы символов, поддерживаемые сервером Postgres Pro Shardman, описаны в Подразделе 22.3.1.

По умолчанию кодировка для баз-шаблонов выбирается, исходя из указанной локали. Если задан параметр --no-locale (или, что равнозначно, задана локаль C или POSIX), по умолчанию используется UTF8 для провайдера ICU и SQL_ASCII для провайдера libc.

-g
--allow-group-access #

Позволяет пользователям, входящим в группу владельца кластера, читать все файлы кластера, создаваемые программой initdb.

--icu-locale=локаль #

Указывает локаль ICU, если используется провайдер локалей ICU. Поддержка локали описана в Разделе 22.1. По умолчанию используется значение --locale, если оно указано, в противном случае — значение lc_collate.

--icu-rules=правила #

Указывает дополнительные правила для настройки поведения сортировки по умолчанию. Параметр поддерживается только для ICU.

-k
--data-checksums #

Применять контрольные суммы на страницах данных для выявления сбоев при вводе-выводе, которые иначе останутся незамеченными. Этот режим включён по умолчанию; используйте --no-data-checksums, чтобы отключить расчёт контрольных сумм.

Расчёт контрольных сумм может повлечь незначительное снижение производительности. Когда контрольные суммы включены, они рассчитываются для всех объектов и во всех базах данных. Все ошибки контрольных сумм будут видны в представлении pg_stat_database. За подробностями обратитесь к Разделу 28.2.

По умолчанию кластеры Postgres Pro Shardman инициализируются с включёнными контрольными суммами. Чтобы изменить это поведение, добавьте параметр --no-data-checksums.

--locale=локаль #

Устанавливает локаль кластера по умолчанию. Если флаг не указан, локаль устанавливается согласно окружению, в котором исполняется команда initdb. Поддерживаемые локали описаны в Разделе 22.1.

Если для параметра --locale-provider установлено значение builtin, то также должен быть задан --locale или --builtin-locale со значением C, C.UTF-8 или PG_UNICODE_FAST.

--lc-collate=локаль
--lc-ctype=локаль
--lc-messages=локаль
--lc-monetary=локаль
--lc-numeric=локаль
--lc-time=локаль #

Аналогично --locale устанавливает локаль, но только для заданной категории. Параметр --lc-collate переопределяет параметр --locale независимо от того, указан ли провайдер правил сортировки.

--no-locale #

Аналогично флагу --locale=C.

--builtin-locale=локаль #

Указывает имя локали при использовании провайдера builtin. Поддержка локалей описана в Разделе 22.1.

--locale-provider={builtin|libc|icu} #

Этот параметр выбирает провайдера локалей для баз данных, создаваемых в новом кластере. Его можно переопределить для создаваемых впоследствии баз в команде CREATE DATABASE. См. Подраздел 22.1.4.

--no-data-checksums #

Не включать расчёт контрольных сумм данных.

--pwfile=имя_файла #

Принуждает initdb читать пароль начального суперпользователя из файла, первая строка которого используется в качестве пароля.

--no-tune #

По умолчанию использование утилиты pgpro_tune в initdb включено. Чтобы её отключить, используйте этот параметр.

--tune=параметры #

Устанавливает параметры для pgpro_tune. За дополнительной информацией обратитесь к их описанию.

-T конфигурация
--text-search-config=конфигурация #

Устанавливает конфигурацию текстового поиска по умолчанию. За дополнительными сведениями обратитесь к default_text_search_config.

-U имя_пользователя
--username=имя_пользователя #

Задаёт имя пользователя для начального суперпользователя. По умолчанию это имя пользователя ОС, запускающего initdb.

-W
--pwprompt #

Указывает initdb запросить пароль, который будет назначен начальному суперпользователю. Это не важно, если не планируется использовать аутентификацию по паролю. В ином случае этот режим аутентификации оказывается неприменимым, пока пароль не задан.

-X каталог
--waldir=каталог #

Этот параметр указывает каталог для хранения журнала предзаписи.

--wal-segsize=размер #

Задаёт размер сегмента WAL, в мегабайтах. Такой размер будет иметь каждый отдельный файл в журнале WAL. По умолчанию размер равен 16 мегабайтам. Значение должно задаваться степенью 2 от 1 до 1024 (в мегабайтах). Этот параметр можно установить только во время инициализации и нельзя изменить позже.

Этот размер бывает полезно поменять при тонкой настройке трансляции или архивации WAL. Кроме того, в базах данных с WAL большого объёма огромное количество файлов WAL в каталоге может стать проблемой с точки зрения производительности и администрирования. Увеличение размера файлов WAL приводит к уменьшению числа этих файлов.

Другие реже используемые параметры описаны здесь:

-c имя=значение
--set имя=значение #

Принудительно устанавливает заданное значение для серверного параметра с указанным именем во время initdb, а также переопределяет этот параметр в файле postgresql.conf, чтобы использовать его при последующих запусках сервера. Этот параметр initdb можно задавать несколько раз, чтобы переопределить несколько серверных параметров. В основном он используется в случаях, когда сервер не может запуститься со значениями параметров по умолчанию.

-d
--debug #

Выводит отладочные сообщения загрузчика и ряд других сообщений, не очень интересных широкой публике. Загрузчик — это приложение initdb, используемое для создания каталога таблиц. С этим параметром выдаётся очень много крайне скучных сообщений.

--discard-caches #

Запустить загрузчик с параметром debug_discard_caches=1. Это очень сильно замедлит выполнение и полезно только для низкоуровневой отладки.

-L каталог #

Указывает initdb, где необходимо искать входные файлы для развёртывания кластера. Обычно это не требуется. Приложение само запросит эти данные, если будет необходимо.

-n
--no-clean #

По умолчанию, при выявлении ошибки на этапе развёртывания кластера, initdb удаляет все файлы, которые к тому моменту были созданы. Параметр предотвращает очистку файлов для целей отладки.

-N
--no-sync #

По умолчанию initdb ждёт, пока все файлы не будут надёжно записаны на диск. С данным параметром initdb завершается быстрее, без ожидания, но в случае неожиданного сбоя операционной системы каталог данных может оказаться испорченным. Этот параметр может быть полезен при тестировании; в производственной среде применять его не следует.

--no-sync-data-files #

По умолчанию initdb безопасно записывает все файлы базы данных на диск. С этим параметром initdb пропускает синхронизацию всех файлов в каталогах отдельных баз данных, самих каталогов баз данных, а также каталогов табличных пространств, то есть всего содержимого подкаталога base и любых других каталогов табличных пространств. Другие файлы, такие как файлы в pg_wal и pg_xact, будут синхронизированы, если только не указан параметр --no-sync.

Заметьте, что если параметр --no-sync-data-files используется в сочетании с --sync-method=syncfs, некоторые или все вышеупомянутые файлы и каталоги будут синхронизированы, потому что syncfs обрабатывает файловые системы целиком.

Этот параметр в основном предназначен для внутреннего использования инструментами, которые самостоятельно обеспечивают синхронизацию пропущенных файлов с диском.

--no-instructions #

По умолчанию initdb после всех сообщений выводит инструкции по запуску кластера. С этим ключом данные инструкции выводиться не будут. Этот ключ предназначен в первую очередь для применения на платформах, где initdb используется в специальных высокоуровневых процедурах, в рамках которых данные инструкции оказываются некорректными.

-s
--show #

Вывести внутренние параметры и завершить команду. Может использоваться для отладки во время установки initdb.

--sync-method=метод #

Со значением fsync (это значение по умолчанию), initdb будет рекурсивно открывать и синхронизировать все файлы в каталоге данных. Поиск файлов будет осуществляться по символическим ссылкам для каталога WAL и каждого настроенного табличного пространства.

В Linux возможен вариант syncfs, когда от ОС требуется синхронизировать целиком каждую из файловых систем, содержащих каталог данных, файлы WAL и табличные пространства. Более подробно особенности использования syncfs описаны в recovery_init_sync_method.

В режиме --no-sync этот параметр не оказывает никакого влияния.

-S
--sync-only #

Безопасно записывает все файлы базы на диск и останавливается. Другие операции initdb при этом не выполняются. В целом, этот параметр полезен для обеспечения надёжного восстановления после изменения значения fsync с off на on.

Другие параметры для тестирования 64-битных идентификаторов транзакций:

-m START_MX_ID
--multixact-id=START_MX_ID

Задаёт для нового экземпляра БД начальный идентификатор мультитранзакций в десятичном виде для тестирования обновлений БД, значение по умолчанию — 0.

-o START_MX_OFFSET
--multixact-offset=START_MX_OFFSET

Задаёт для нового экземпляра БД начальное смещение мультитранзакций в десятичном виде для тестирования обновлений БД, значение по умолчанию — 0.

-x START_XID
--xid=START_XID

Задаёт для нового экземпляра БД начальный идентификатор транзакций в десятичном виде для тестирования обновлений БД, значение по умолчанию — 0.

Прочие параметры:

-V
--version #

Выводит версию initdb и останавливается.

-?
--help #

Показывает помощь по аргументам команды initdb и останавливается.

Переменные окружения

PGDATA #

Указывает каталог хранения данных кластера, можно изменить параметром -D.

PG_COLOR #

Выбирает вариант использования цвета в диагностических сообщениях. Возможные значения: always (всегда), auto (автоматически) и never (никогда).

PGPRO_TUNE #

Указывает, нужно ли использовать утилиту pgpro_tune без изменения параметров в командной строке. Возможные значения: enable/disable, true/false, on/off и yes/no. Если установлено значение disable, false, off или no, действие этой переменной окружения аналогично установлению параметра --no-tune, то есть отключает pgpro_tune. Если задано другое значение и параметр --tune или --no-tune в командной строке явным образом не указан, поведение будет таким же, как если бы для параметра --tune было задано значение PGPRO_TUNE.

TZ #

Указывает часовой пояс кластера по умолчанию. Значение — это полное имя часового пояса (см. Подраздел 8.5.3).

Примечания

initdb можно выполнить командой pg_ctl initdb.

initdb

initdb — create a new Postgres Pro Shardman database cluster

Synopsis

initdb [option...] [ --pgdata | -D ] directory

Description #

initdb creates a new Postgres Pro Shardman database cluster.

Creating a database cluster consists of creating the directories in which the cluster data will live, generating the shared catalog tables (tables that belong to the whole cluster rather than to any particular database), and creating the postgres, template1, and template0 databases. The postgres database is a default database meant for use by users, utilities and third party applications. template1 and template0 are meant as source databases to be copied by later CREATE DATABASE commands. template0 should never be modified, but you can add objects to template1, which by default will be copied into databases created later. See Section 21.4 for more details.

Although initdb will attempt to create the specified data directory, it might not have permission if the parent directory of the desired data directory is root-owned. To initialize in such a setup, create an empty data directory as root, then use chown to assign ownership of that directory to the database user account, then su to become the database user to run initdb.

initdb must be run as the user that will own the server process, because the server needs to have access to the files and directories that initdb creates. Since the server cannot be run as root, you must not run initdb as root either. (It will in fact refuse to do so.)

For security reasons the new cluster created by initdb will only be accessible by the cluster owner by default. The --allow-group-access option allows any user in the same group as the cluster owner to read files in the cluster. This is useful for performing backups as a non-privileged user.

initdb initializes the database cluster's default locale and character set encoding. These can also be set separately for each database when it is created. initdb determines those settings for the template databases, which will serve as the default for all other databases.

By default, initdb takes the locale settings from the environment, and determines the encoding from the locale settings. If the locale provider is not specified, it is set automatically based on the lc_collate value for the cluster: libc is used for the C or POSIX locales, and icu is used for other locales.

To choose a different locale for the cluster, use the option --locale. There are also individual options --lc-* and --icu-locale (see below) to set values for the individual locale categories. Note that inconsistent settings for different locale categories can give nonsensical results, so this should be used with care.

Alternatively, initdb can use the ICU library to provide locale services by specifying --locale-provider=icu. The server must be built with ICU support. To choose the specific ICU locale ID to apply, use the option --icu-locale. Note that for implementation reasons and to support legacy code, initdb will still select and initialize libc locale settings when the ICU locale provider is used.

When initdb runs, it will print out the locale settings it has chosen. If you have complex requirements or specified multiple options, it is advisable to check that the result matches what was intended.

More details about locale settings can be found in Section 22.1.

To alter the default encoding, use the --encoding. More details can be found in Section 22.3.

Options

-A authmethod
--auth=authmethod #

This option specifies the default authentication method for local users used in pg_hba.conf (host and local lines). See Section 19.1 for an overview of valid values.

initdb will prepopulate pg_hba.conf entries using the specified authentication method for non-replication as well as replication connections.

Do not use trust unless you trust all local users on your system. trust is the default for ease of installation.

--auth-host=authmethod #

This option specifies the authentication method for local users via TCP/IP connections used in pg_hba.conf (host lines).

--auth-local=authmethod #

This option specifies the authentication method for local users via Unix-domain socket connections used in pg_hba.conf (local lines).

-D directory
--pgdata=directory #

This option specifies the directory where the database cluster should be stored. This is the only information required by initdb, but you can avoid writing it by setting the PGDATA environment variable, which can be convenient since the database server (postgres) can find the data directory later by the same variable.

-E encoding
--encoding=encoding #

Selects the encoding of the template databases. This will also be the default encoding of any database you create later, unless you override it then. The character sets supported by the Postgres Pro Shardman server are described in Section 22.3.1.

By default, the template database encoding is derived from the locale. If --no-locale is specified (or equivalently, if the locale is C or POSIX), then the default is UTF8 for the ICU provider and SQL_ASCII for the libc provider.

-g
--allow-group-access #

Allows users in the same group as the cluster owner to read all cluster files created by initdb.

--icu-locale=locale #

Specifies the ICU locale when the ICU provider is used. Locale support is described in Section 22.1. The default is the setting of --locale if specified and otherwise the value of lc_collate.

--icu-rules=rules #

Specifies additional collation rules to customize the behavior of the default collation. This is supported for ICU only.

-k
--data-checksums #

Use checksums on data pages to help detect corruption by the I/O system that would otherwise be silent. This is enabled by default; use --no-data-checksums to disable checksums.

Enabling checksums might incur a small performance penalty. If set, checksums are calculated for all objects, in all databases. All checksum failures will be reported in the pg_stat_database view. See Section 28.2 for details.

By default, Postgres Pro Shardman clusters are initialized with checksums enabled. To change this behavior, provide the --no-data-checksums option.

--locale=locale #

Sets the default locale for the database cluster. If this option is not specified, the locale is inherited from the environment that initdb runs in. Locale support is described in Section 22.1.

If --locale-provider is builtin, --locale or --builtin-locale must be specified and set to C, C.UTF-8 or PG_UNICODE_FAST.

--lc-collate=locale
--lc-ctype=locale
--lc-messages=locale
--lc-monetary=locale
--lc-numeric=locale
--lc-time=locale #

Like --locale, but only sets the locale in the specified category. The --lc-collate option overrides the --locale setting, regardless of whether the collation provider is specified.

--no-locale #

Equivalent to --locale=C.

--builtin-locale=locale #

Specifies the locale name when the builtin provider is used. Locale support is described in Section 22.1.

--locale-provider={builtin|libc|icu} #

This option sets the locale provider for databases created in the new cluster. It can be overridden in the CREATE DATABASE command when new databases are subsequently created. See Section 22.1.4.

--no-data-checksums #

Do not enable data checksums.

--pwfile=filename #

Makes initdb read the bootstrap superuser's password from a file. The first line of the file is taken as the password.

--no-tune #

By default, the use of pgpro_tune is enabled in initdb. Use this option to disable it.

--tune=options #

Sets parameters for pgpro_tune. See their description for further information.

-T config
--text-search-config=config #

Sets the default text search configuration. See default_text_search_config for further information.

-U username
--username=username #

Sets the user name of the bootstrap superuser. This defaults to the name of the operating-system user running initdb.

-W
--pwprompt #

Makes initdb prompt for a password to give the bootstrap superuser. If you don't plan on using password authentication, this is not important. Otherwise you won't be able to use password authentication until you have a password set up.

-X directory
--waldir=directory #

This option specifies the directory where the write-ahead log should be stored.

--wal-segsize=size #

Set the WAL segment size, in megabytes. This is the size of each individual file in the WAL log. The default size is 16 megabytes. The value must be a power of 2 between 1 and 1024 (megabytes). This option can only be set during initialization, and cannot be changed later.

It may be useful to adjust this size to control the granularity of WAL log shipping or archiving. Also, in databases with a high volume of WAL, the sheer number of WAL files per directory can become a performance and management problem. Increasing the WAL file size will reduce the number of WAL files.

Other, less commonly used, options are also available:

-c name=value
--set name=value #

Forcibly set the server parameter name to value during initdb, and also install that setting in the generated postgresql.conf file, so that it will apply during future server runs. This option can be given more than once to set several parameters. It is primarily useful when the environment is such that the server will not start at all using the default parameters.

-d
--debug #

Print debugging output from the bootstrap backend and a few other messages of lesser interest for the general public. The bootstrap backend is the program initdb uses to create the catalog tables. This option generates a tremendous amount of extremely boring output.

--discard-caches #

Run the bootstrap backend with the debug_discard_caches=1 option. This takes a very long time and is only of use for deep debugging.

-L directory #

Specifies where initdb should find its input files to initialize the database cluster. This is normally not necessary. You will be told if you need to specify their location explicitly.

-n
--no-clean #

By default, when initdb determines that an error prevented it from completely creating the database cluster, it removes any files it might have created before discovering that it cannot finish the job. This option inhibits tidying-up and is thus useful for debugging.

-N
--no-sync #

By default, initdb will wait for all files to be written safely to disk. This option causes initdb to return without waiting, which is faster, but means that a subsequent operating system crash can leave the data directory corrupt. Generally, this option is useful for testing, but should not be used when creating a production installation.

--no-sync-data-files #

By default, initdb safely writes all database files to disk. This option instructs initdb to skip synchronizing all files in the individual database directories, the database directories themselves, and the tablespace directories, i.e., everything in the base subdirectory and any other tablespace directories. Other files, such as those in pg_wal and pg_xact, will still be synchronized unless the --no-sync option is also specified.

Note that if --no-sync-data-files is used in conjunction with --sync-method=syncfs, some or all of the aforementioned files and directories will be synchronized because syncfs processes entire file systems.

This option is primarily intended for internal use by tools that separately ensure the skipped files are synchronized to disk.

--no-instructions #

By default, initdb will write instructions for how to start the cluster at the end of its output. This option causes those instructions to be left out. This is primarily intended for use by tools that wrap initdb in platform-specific behavior, where those instructions are likely to be incorrect.

-s
--show #

Show internal settings and exit, without doing anything else. This can be used to debug the initdb installation.

--sync-method=method #

When set to fsync, which is the default, initdb will recursively open and synchronize all files in the data directory. The search for files will follow symbolic links for the WAL directory and each configured tablespace.

On Linux, syncfs may be used instead to ask the operating system to synchronize the whole file systems that contain the data directory, the WAL files, and each tablespace. See recovery_init_sync_method for information about the caveats to be aware of when using syncfs.

This option has no effect when --no-sync is used.

-S
--sync-only #

Safely write all database files to disk and exit. This does not perform any of the normal initdb operations. Generally, this option is useful for ensuring reliable recovery after changing fsync from off to on.

Other options for testing 64-bit XIDs:

-m START_MX_ID
--multixact-id=START_MX_ID

Specifies the initial multixact ID value in the decimal format for a new database instance to test database upgrades, default value is 0.

-o START_MX_OFFSET
--multixact-offset=START_MX_OFFSET

Specifies the initial multixact offset value in the decimal format for a new database instance to test database upgrades, default value is 0.

-x START_XID
--xid=START_XID

Specifies the initial XID value in the decimal format for a new database instance to test database upgrades, default value is 0.

Other options:

-V
--version #

Print the initdb version and exit.

-?
--help #

Show help about initdb command line arguments, and exit.

Environment

PGDATA #

Specifies the directory where the database cluster is to be stored; can be overridden using the -D option.

PG_COLOR #

Specifies whether to use color in diagnostic messages. Possible values are always, auto and never.

PGPRO_TUNE #

Specifies whether to use pgpro_tune without modifying command-line options directly. Possible values are enable/disable, true/false, on/off, and yes/no. If set to disable, false, off, or no, this environment variable has the same effect as passing --no-tune, disabling the use of pgpro_tune. If set to any other value, and neither --tune nor --no-tune is explicitly specified on the command line, the behavior is the same as if --tune is specified with the value of PGPRO_TUNE.

TZ #

Specifies the default time zone of the created database cluster. The value should be a full time zone name (see Section 8.5.3).

Notes

initdb can also be invoked via pg_ctl initdb.

FAQ