mirror of
https://github.com/EnterpriseDB/repmgr.git
synced 2026-03-22 22:56:29 +00:00
209 lines
6.4 KiB
XML
209 lines
6.4 KiB
XML
<refentry id="repmgr-daemon-start">
|
|
<indexterm>
|
|
<primary>repmgr daemon start</primary>
|
|
</indexterm>
|
|
|
|
<indexterm>
|
|
<primary>repmgrd</primary>
|
|
<secondary>starting</secondary>
|
|
</indexterm>
|
|
|
|
<refmeta>
|
|
<refentrytitle>repmgr daemon start</refentrytitle>
|
|
</refmeta>
|
|
|
|
<refnamediv>
|
|
<refname>repmgr daemon start</refname>
|
|
<refpurpose>Start the &repmgrd; daemon on the local node</refpurpose>
|
|
</refnamediv>
|
|
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<para>
|
|
This command starts the &repmgrd; service on the
|
|
local node.
|
|
</para>
|
|
<para>
|
|
By default, &repmgr; will wait for up to 15 seconds to confirm that &repmgrd;
|
|
started. This behaviour can be overridden by specifying a different value using the <option>--wait</option>
|
|
option, or disabled altogether with the <option>--no-wait</option> option.
|
|
</para>
|
|
|
|
<important>
|
|
<para>
|
|
The <filename>repmgr.conf</filename> parameter <varname>repmgrd_service_start_command</varname>
|
|
must be set for <command>repmgr daemon start</command> to work; see section
|
|
<xref linkend="repmgr-daemon-start-configuration"/> for details.
|
|
</para>
|
|
</important>
|
|
</refsect1>
|
|
|
|
|
|
|
|
<refsect1>
|
|
|
|
<title>Options</title>
|
|
|
|
<variablelist>
|
|
|
|
<varlistentry>
|
|
<term><option>--dry-run</option></term>
|
|
<listitem>
|
|
<para>
|
|
Check prerequisites but don't actually attempt to start &repmgrd;.
|
|
</para>
|
|
<para>
|
|
This action will output the command which would be executed.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry>
|
|
<term><option>-w</option></term>
|
|
<term><option>--wait</option></term>
|
|
<listitem>
|
|
<para>
|
|
Wait for the specified number of seconds to confirm that &repmgrd;
|
|
started successfully.
|
|
</para>
|
|
<para>
|
|
Note that providing <option>--wait=0</option> is the equivalent of <option>--no-wait</option>.
|
|
</para>
|
|
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry>
|
|
<term><option>--no-wait</option></term>
|
|
<listitem>
|
|
<para>
|
|
Don't wait to confirm that &repmgrd;
|
|
started successfully.
|
|
</para>
|
|
<para>
|
|
This is equivalent to providing <option>--wait=0</option>.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
</variablelist>
|
|
</refsect1>
|
|
|
|
<refsect1 id="repmgr-daemon-start-configuration" xreflabel="repmgr daemon start configuration">
|
|
<title>Configuration file settings</title>
|
|
<para>
|
|
The following parameter in <filename>repmgr.conf</filename> is relevant
|
|
to <command>repmgr daemon start</command>:
|
|
</para>
|
|
|
|
<variablelist>
|
|
|
|
<varlistentry>
|
|
|
|
<term><option>repmgrd_service_start_command</option></term>
|
|
<listitem>
|
|
<indexterm>
|
|
<primary>repmgrd_service_start_command</primary>
|
|
<secondary>with "repmgr daemon start"</secondary>
|
|
</indexterm>
|
|
|
|
<para>
|
|
<command>repmgr daemon start</command> will execute the command defined by the
|
|
<varname>repmgrd_service_start_command</varname> parameter in <filename>repmgr.conf</filename>.
|
|
This must be set to a shell command which will start &repmgrd;;
|
|
if &repmgr; was installed from a package, this will be the service command defined by the
|
|
package. For more details see <link linkend="appendix-packages">Appendix: &repmgr; package details</link>.
|
|
</para>
|
|
<important>
|
|
<para>
|
|
If &repmgr; was installed from a system package, and you do not configure
|
|
<varname>repmgrd_service_start_command</varname> to an appropriate service command, this may
|
|
result in the system becoming confused about the state of the &repmgrd;
|
|
service; this is particularly the case with <literal>systemd</literal>.
|
|
</para>
|
|
</important>
|
|
</listitem>
|
|
</varlistentry>
|
|
</variablelist>
|
|
|
|
</refsect1>
|
|
|
|
|
|
<refsect1>
|
|
<title>Exit codes</title>
|
|
<para>
|
|
One of the following exit codes will be emitted by <command>repmgr daemon start</command>:
|
|
</para>
|
|
<variablelist>
|
|
|
|
<varlistentry>
|
|
<term><option>SUCCESS (0)</option></term>
|
|
<listitem>
|
|
<para>
|
|
The &repmgrd; start command (defined in
|
|
<varname>repmgrd_service_start_command</varname>) was successfully executed.
|
|
</para>
|
|
<para>
|
|
If the <option>--wait</option> option was provided, &repmgr; will confirm that
|
|
&repmgrd; has actually started up.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry>
|
|
<term><option>ERR_BAD_CONFIG (1)</option></term>
|
|
<listitem>
|
|
<para>
|
|
<varname>repmgrd_service_start_command</varname> is not defined in
|
|
<filename>repmgr.conf</filename>.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
|
|
<varlistentry>
|
|
<term><option>ERR_DB_CONN (6)</option></term>
|
|
<listitem>
|
|
<para>
|
|
&repmgr; was unable to connect to the local PostgreSQL node.
|
|
</para>
|
|
<para>
|
|
PostgreSQL must be running before &repmgrd;
|
|
can be started. Additionally, unless the <option>--no-wait</option> option was
|
|
provided, &repmgr; needs to be able to connect to the local PostgreSQL node
|
|
to determine the state of &repmgrd;.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
|
|
<varlistentry>
|
|
<term><option>ERR_REPMGRD_SERVICE (27)</option></term>
|
|
<listitem>
|
|
<para>
|
|
The &repmgrd; start command (defined in
|
|
<varname>repmgrd_service_start_command</varname>) was not successfully executed.
|
|
</para>
|
|
<para>
|
|
This can also mean that &repmgr; was unable to confirm whether &repmgrd;
|
|
successfully started (unless the <option>--no-wait</option> option was provided).
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
</variablelist>
|
|
</refsect1>
|
|
|
|
<refsect1>
|
|
<title>See also</title>
|
|
<para>
|
|
<xref linkend="repmgr-daemon-stop"/>,
|
|
<xref linkend="repmgrd-daemon"/>,
|
|
<xref linkend="repmgr-service-status"/>,
|
|
<xref linkend="repmgr-service-pause"/>,
|
|
<xref linkend="repmgr-service-unpause"/>
|
|
</para>
|
|
</refsect1>
|
|
|
|
</refentry>
|