]> granicus.if.org Git - postgresql/commitdiff
Start the stats collector at a less randomly chosen time. Bad idea
authorTom Lane <tgl@sss.pgh.pa.us>
Tue, 3 Jul 2001 16:52:12 +0000 (16:52 +0000)
committerTom Lane <tgl@sss.pgh.pa.us>
Tue, 3 Jul 2001 16:52:12 +0000 (16:52 +0000)
to start it before we have acquired the data directory lock; also a
bad idea to start it before we have set up to catch SIGCHLD signals.

src/backend/postmaster/postmaster.c

index 0d92324623cda57c879baada9fb2b95f357ad8b4..3e92f16720e76c8077b1863d130350a1711fa678 100644 (file)
@@ -37,7 +37,7 @@
  *
  *
  * IDENTIFICATION
- *       $Header: /cvsroot/pgsql/src/backend/postmaster/postmaster.c,v 1.230 2001/07/01 00:06:23 tgl Exp $
+ *       $Header: /cvsroot/pgsql/src/backend/postmaster/postmaster.c,v 1.231 2001/07/03 16:52:12 tgl Exp $
  *
  * NOTES
  *
@@ -569,14 +569,6 @@ PostmasterMain(int argc, char *argv[])
                ExitPostmaster(1);
        }
 
-       /*
-        * Initialize and startup the statistics collector process
-        */
-       if (pgstat_init() < 0)
-               ExitPostmaster(1);
-       if (pgstat_start() < 0)
-               ExitPostmaster(1);
-
        if (DebugLvl > 2)
        {
                extern char **environ;
@@ -699,6 +691,14 @@ PostmasterMain(int argc, char *argv[])
        pqsignal(SIGTTIN, SIG_IGN); /* ignored */
        pqsignal(SIGTTOU, SIG_IGN); /* ignored */
 
+       /*
+        * Initialize and startup the statistics collector process
+        */
+       if (pgstat_init() < 0)
+               ExitPostmaster(1);
+       if (pgstat_start() < 0)
+               ExitPostmaster(1);
+
        /*
         * We're ready to rock and roll...
         */