Re: The function of lock file named ".s.PGSQL.<port>.lock" on Linux?

From: Greg Smith <greg(at)2ndquadrant(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: xsun <xu2002261(at)163(dot)com>, pgsql-admin(at)postgresql(dot)org
Subject: Re: The function of lock file named ".s.PGSQL.<port>.lock" on Linux?
Date: 2010-08-11 00:51:11
Message-ID: 4C61F3FF.1080303@2ndquadrant.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

Tom Lane wrote:
> We can't portably lock the socket file itself, so we make a separate
> ordinary file for locking purposes.
>

It looks to me like the fact that the .lock file is created is only
documented in src/backend/utils/init/miscinit.c , and even there the
reason why (what you wrote above) isn't mentioned. Seems like noting
this file is created in the unix_socket_directory entry of the docs, and
the rationale for why in the source code, would make a useful
improvement. Anybody want to write a little documentation patch?

--
Greg Smith 2ndQuadrant US Baltimore, MD
PostgreSQL Training, Services and Support
greg(at)2ndQuadrant(dot)com www.2ndQuadrant.us

In response to

Responses

Browse pgsql-admin by date

  From Date Subject
Next Message Tom Lane 2010-08-11 01:09:55 Re: The function of lock file named ".s.PGSQL.<port>.lock" on Linux?
Previous Message Kasia Tuszynska 2010-08-10 22:02:48 Re: postgres function does not handle PUBLIC - expected?