1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85
|
.. _pg_autoctl_stop:
pg_autoctl stop
===============
pg_autoctl stop - signal the pg_autoctl service for it to stop
Synopsis
--------
This commands stops the processes needed to run a monitor node or a keeper
node, depending on the configuration file that belongs to the ``--pgdata``
option or ``PGDATA`` environment variable.
::
usage: pg_autoctl stop [ --pgdata --fast --immediate ]
--pgdata path to data directory
--fast fast shutdown mode for the keeper
--immediate immediate shutdown mode for the keeper
Description
-----------
The ``pg_autoctl stop`` commands finds the PID of the running service for
the given ``--pgdata``, and if the process is still running, sends a
``SIGTERM`` signal to the process.
When ``pg_autoclt`` receives a shutdown signal a shutdown sequence is
triggered. Depending on the signal received, an operation that has been
started (such as a state transition) is either run to completion, stopped as
the next opportunity, or stopped immediately even when in the middle of the
transition.
Options
-------
--pgdata
Location of the Postgres node being managed locally. Defaults to the
environment variable ``PGDATA``. Use ``--monitor`` to connect to a monitor
from anywhere, rather than the monitor URI used by a local Postgres node
managed with ``pg_autoctl``.
--fast
Fast Shutdown mode for ``pg_autoctl``. Sends the ``SIGINT`` signal to the
running service, which is the same as using ``C-c`` on an interactive
process running as a foreground shell job.
--immediate
Immediate Shutdown mode for ``pg_autoctl``. Sends the ``SIGQUIT`` signal
to the running service.
Environment
-----------
PGDATA
Postgres directory location. Can be used instead of the ``--pgdata``
option.
PG_AUTOCTL_MONITOR
Postgres URI to connect to the monitor node, can be used instead of the
``--monitor`` option.
XDG_CONFIG_HOME
The pg_autoctl command stores its configuration files in the standard
place XDG_CONFIG_HOME. See the `XDG Base Directory Specification`__.
__ https://specifications.freedesktop.org/basedir-spec/basedir-spec-latest.html
XDG_DATA_HOME
The pg_autoctl command stores its internal states files in the standard
place XDG_DATA_HOME, which defaults to ``~/.local/share``. See the `XDG
Base Directory Specification`__.
__ https://specifications.freedesktop.org/basedir-spec/basedir-spec-latest.html
|