On Tue, May 24, 2016 at 3:57 PM, Fred Parkinson <FredP@xxxxxxxxxxx> wrote:
I want to do a server restart, so I issued the commandpg-ctl -w restart -D /usr/local/pgsql/dataHowever, the shut down fails:pg_ctl: server does not shut down.Unfortunately, when I try to see who is connected with psql, I getFATAL: the database system is shutting down.Is there any other way to see who is still connected?Thanks --Fred
ABAG is moving.Effective Monday May 23, 2016 our mailing address and location will be:Association of Bay Area Governments375 Beale Street, Suite 700San Francisco, CA 94105My email address will remain the same.My phone number will be (415) 820-79XX (last two digits remain the same).We look forward to seeing you at our new location along with our regional partners, the Metropolitan Transportation Commission and the Bay Area Air Quality Management District.
In the meantime, it's business as usual at our current location in Oakland.
Try using the option "-m fast" to either the shutdown or restart command to pg_ctl
pg-ctl -w restart -D /usr/local/pgsql/data -m fast
pg-ctl -w restart -D /usr/local/pgsql/data -m fast
This disconnects any sessions currently connected. Thankfully in 9.5, this has become the default shutdown mode. Prior to 9.5, "-m smart" was the default which waits for all active connections to disconnect themselves.