tracking down temp files

Started by Robert Treatover 22 years ago4 messagesgeneral
Jump to latest
#1Robert Treat
xzilla@users.sourceforge.net

is there some way to determine the query that creates the file
pgsql_tmp15041.0? i thought maybe 15041 was the procpid but apparently
not... anyone know?

Robert Treat
--
Build A Brighter Lamp :: Linux Apache {middleware} PostgreSQL

#2Bruce Momjian
bruce@momjian.us
In reply to: Robert Treat (#1)
Re: tracking down temp files

Robert Treat wrote:

is there some way to determine the query that creates the file
pgsql_tmp15041.0? i thought maybe 15041 was the procpid but apparently
not... anyone know?

It is the proc id. Perhaps the backend crashed. If so, a postmaster
restart clears those sort directories.

-- 
  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
#3Robert Treat
xzilla@users.sourceforge.net
In reply to: Bruce Momjian (#2)
Re: tracking down temp files

On Monday 17 November 2003 21:38, Bruce Momjian wrote:

Robert Treat wrote:

is there some way to determine the query that creates the file
pgsql_tmp15041.0? i thought maybe 15041 was the procpid but apparently
not... anyone know?

It is the proc id. Perhaps the backend crashed. If so, a postmaster
restart clears those sort directories.

Hmm... when I see those files created I look in pg_stat_activity, but I don't
see any corresponding query... shouldn't I?

Robert Treat
--
Build A Brighter Lamp :: Linux Apache {middleware} PostgreSQL

#4Bruce Momjian
bruce@momjian.us
In reply to: Robert Treat (#3)
Re: tracking down temp files

Robert Treat wrote:

On Monday 17 November 2003 21:38, Bruce Momjian wrote:

Robert Treat wrote:

is there some way to determine the query that creates the file
pgsql_tmp15041.0? i thought maybe 15041 was the procpid but apparently
not... anyone know?

It is the proc id. Perhaps the backend crashed. If so, a postmaster
restart clears those sort directories.

Hmm... when I see those files created I look in pg_stat_activity, but I don't
see any corresponding query... shouldn't I?

Yes, you should unless the backend died unexpectedly in which case they
would be left around until postmaster restart.

-- 
  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