[HACKERS] pg_upgrade vs. pg_ctl stop -m fast - Mailing list pgsql-hackers

From Peter Eisentraut
Subject [HACKERS] pg_upgrade vs. pg_ctl stop -m fast
Date
Msg-id 50365cd0-2a9c-83bc-4220-c0c5cb111735@2ndquadrant.com
Whole thread Raw
Responses Re: [HACKERS] pg_upgrade vs. pg_ctl stop -m fast  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
In 9.5, the default pg_ctl stop mode was changed from "smart" to "fast".

In pg_upgrade, there is this code:

void
stop_postmaster(bool fast)
{   ...   exec_prog(SERVER_STOP_LOG_FILE, NULL, !fast,             "\"%s/pg_ctl\" -w -D \"%s\" -o \"%s\" %s stop",
      cluster->bindir, cluster->pgconfig,             cluster->pgopts ? cluster->pgopts : "",             fast ? "-m
fast": "");   ...
 
}

So, when upgrading from 9.5 or later, code that requested a non-fast
shutdown would now always get a fast shutdown.

I think the last line should be changed to something like
             fast ? "-m fast" : "-m smart");

-- 
Peter Eisentraut              http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services



pgsql-hackers by date:

Previous
From: Pavel Stehule
Date:
Subject: Re: [HACKERS] patch: function xmltable
Next
From: Tom Lane
Date:
Subject: Re: [HACKERS] pg_upgrade vs. pg_ctl stop -m fast