Start/Stop/Restart PostgreSQL server
July 01, 2010 16:57:31 Last update: July 01, 2010 16:57:31
Use the
Environment variable
pg_ctl command to start/stop/restart the PostgreSQL server:
$ bin/pg_ctl -D /usr/local/pgsql/data -l logs/postgres.log start $ bin/pg_ctl -D /usr/local/pgsql/data stop $ bin/pg_ctl -D /usr/local/pgsql/data restart $ bin/pg_ctl -D /usr/local/pgsql/data status
Environment variable
PGDATA can be set in lieu of the -D switch.