pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Bruce Momjian <pgman@candle.pha.pa.us>
To: Dmitry Morozovsky <marck@rinet.ru>
Cc: Chris White (cjwhite) <cjwhite@cisco.com>
Cc: pgsql-admin@postgresql.org
Subject: Re: 7.4.5 file write issue
Date: Thu, 10 Mar 2005 22:21:40 -0500 (EST)
Message-ID: <200503110321.j2B3Lee22234@candle.pha.pa.us> (raw)
In-Reply-To: <20050305122822.V83321@woozle.rinet.ru>

Dmitry Morozovsky wrote:
> On Tue, 22 Feb 2005, Chris White (cjwhite) wrote:
> 
> CWc> We are noticing on our 7.4.5 system the following files are being written
> CWc> approximately every 5 minutes
> CWc> 
> CWc> /tmp/.s.PGSQL.5432
> CWc> /tmp/.s.PGSQL.5432.lock
> CWc> 
> CWc> Anybody know why they are being written? The reason I ask is because we are
> CWc> running on a system that uses a laptop disk drive and requires at least 10
> CWc> minutes idle time to spindown so it can recalibrate. This did not happen
> CWc> when we were running 7.4.2, so does anybody have any idea what may have
> CWc> changed between 7.4.2 and 7.4.5 to cause this to happen.
> 
> What about switching to memory-based /tmp ?

If you take a look at postmaster.c you will see:

        /*
         * Touch the socket and lock file at least every ten minutes, to
         * ensure that they are not removed by overzealous /tmp-cleaning
         * tasks.
         */
        now = time(NULL);
        if (now - last_touch_time >= 10 * 60)
        {
            TouchSocketFile();
            TouchSocketLockFile();
            last_touch_time = now;
        }

I would change the "10" to perhaps "60" and try that.

I am now thinking we need to make this "10" a GUC variable for just such
cases.  This is not the first request for this.

-- 
  Bruce Momjian                        |  http://candle.pha.pa.us
  pgman@candle.pha.pa.us               |  (610) 359-1001
  +  If your life is a hard drive,     |  13 Roberts Road
  +  Christ can be your backup.        |  Newtown Square, Pennsylvania 19073



view thread (10+ messages)  latest in thread

Message-ID: <200503110321.j2B3Lee22234@candle.pha.pa.us>
Permalink:  ../200503110321.j2B3Lee22234@candle.pha.pa.us/
Also on:    postgresql.org/message-id/200503110321.j2B3Lee22234@candle.pha.pa.us

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-admin@postgresql.org
  Cc: pgman@candle.pha.pa.us, marck@rinet.ru, cjwhite@cisco.com
  Subject: Re: 7.4.5 file write issue
  In-Reply-To: <200503110321.j2B3Lee22234@candle.pha.pa.us>
  References: <20050305122822.V83321@woozle.rinet.ru> <200503110321.j2B3Lee22234@candle.pha.pa.us>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox