Re: FATAL: lock file "postmaster.pid" already exists

Поиск
Список
Период
Сортировка
От Mark Dilger
Тема Re: FATAL: lock file "postmaster.pid" already exists
Дата
Msg-id 1337794706.64291.YahooMailNeo@web39301.mail.mud.yahoo.com
обсуждение исходный текст
Ответ на Re: FATAL: lock file "postmaster.pid" already exists  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-general
We tried setting the timezone, as:

     timezone = 'US/Eastern'

in postgresql.conf, but it did not help.


From: Tom Lane <tgl@sss.pgh.pa.us>
To: Mark Dilger <markdilger@yahoo.com>
Cc: deepak <deepak.pn@gmail.com>; Alban Hertroys <haramrae@gmail.com>; "pgsql-general@postgresql.org" <pgsql-general@postgresql.org>
Sent: Wednesday, May 23, 2012 9:50 AM
Subject: Re: [GENERAL] FATAL: lock file "postmaster.pid" already exists

Mark Dilger <markdilger@yahoo.com> writes:
> I tried moving the call to RemovePgTempFiles until
> after the PID file is fully written, but it did not help.

I wonder whether you correctly identified the source of the slowness.
The thing I would have suspected is identify_system_timezone(), which
will attempt to read every file in the timezone-database directory tree,
of which there are about 600.  It's not unusual for that to take several
seconds on a cold-started machine that doesn't have any of that tree in
filesystem cache.  It's still a stretch to believe that it'd take
several minutes on any storage system more advanced than a floppy disk;
but at least we'd only be trying to pin about one order of magnitude
slowdown on the filesystem, rather than several orders.

If that is what is causing it, there is a very simple workaround, which
is to set the timezone setting explicitly in postgresql.conf instead of
leaving the postmaster to try to figure it out from the environment.

(9.2 will use a better answer, which is for initdb to do this once and
store the result in postgresql.conf.)

            regards, tom lane


В списке pgsql-general по дате отправления:

Предыдущее
От: Lonni J Friedman
Дата:
Сообщение: Re: Re: significant performance hit whenever autovacuum runs after upgrading from 9.0 -> 9.1
Следующее
От: Tom Lane
Дата:
Сообщение: Re: FATAL: lock file "postmaster.pid" already exists