Thread: pg_psort files

pg_psort files

From
Steven Saner
Date:
I have a fairly simple database (two tables and a few indecies). In
the data/base/xxxx directory I find the following files:

-rw-------  1 postgres  postgres    7734146 Dec 14 06:36 pg_psort.13268.0
-rw-------  1 postgres  postgres    7707487 Dec 14 06:36 pg_psort.13268.1
-rw-------  1 postgres  postgres    7776602 Dec 14 06:36 pg_psort.13268.2
-rw-------  1 postgres  postgres  936026112 Dec 14 07:20 pg_psort.13268.3
-rw-------  1 postgres  postgres    8208384 Dec 14 06:36 pg_psort.13268.4
-rw-------  1 postgres  postgres   15699116 Dec 14 06:36 pg_psort.13268.5
-rw-------  1 postgres  postgres   19002244 Dec 14 06:36 pg_psort.13268.6
-rw-------  1 postgres  postgres    2097152 Dec  9 06:33 pg_psort.25350.0
-rw-------  1 postgres  postgres    2146304 Dec  9 06:33 pg_psort.25350.1
-rw-------  1 postgres  postgres    2277376 Dec  9 06:33 pg_psort.25350.2
-rw-------  1 postgres  postgres    1597440 Dec  9 06:33 pg_psort.25350.3
-rw-------  1 postgres  postgres    1064960 Dec  9 06:33 pg_psort.25350.4
-rw-------  1 postgres  postgres    1327104 Dec  9 06:33 pg_psort.25350.5
-rw-------  1 postgres  postgres          0 Dec  9 06:32 pg_psort.25350.6

I have another database that is almost identical on a different
machine. There are no pg_psort.xxxx files there. I am wondering:

1. What are these files?
2. Do I need them?
3. If I don't need them is it safe to remove them?

--
==================================================================
Steven Saner                            SouthWind Internet Access, Inc.
ssaner@southwind.net                    Systems/Network Administrator
http://www2.southwind.net/~ssaner       http://www.southwind.net
                                        263-7963 Wichita  (800)525-7963

Re: [GENERAL] pg_psort files

From
The Hermit Hacker
Date:
On Tue, 14 Dec 1999, Steven Saner wrote:

> I have a fairly simple database (two tables and a few indecies). In
> the data/base/xxxx directory I find the following files:
>
> -rw-------  1 postgres  postgres    7734146 Dec 14 06:36 pg_psort.13268.0
> -rw-------  1 postgres  postgres    7707487 Dec 14 06:36 pg_psort.13268.1
> -rw-------  1 postgres  postgres    7776602 Dec 14 06:36 pg_psort.13268.2
> -rw-------  1 postgres  postgres  936026112 Dec 14 07:20 pg_psort.13268.3
> -rw-------  1 postgres  postgres    8208384 Dec 14 06:36 pg_psort.13268.4
> -rw-------  1 postgres  postgres   15699116 Dec 14 06:36 pg_psort.13268.5
> -rw-------  1 postgres  postgres   19002244 Dec 14 06:36 pg_psort.13268.6
> -rw-------  1 postgres  postgres    2097152 Dec  9 06:33 pg_psort.25350.0
> -rw-------  1 postgres  postgres    2146304 Dec  9 06:33 pg_psort.25350.1
> -rw-------  1 postgres  postgres    2277376 Dec  9 06:33 pg_psort.25350.2
> -rw-------  1 postgres  postgres    1597440 Dec  9 06:33 pg_psort.25350.3
> -rw-------  1 postgres  postgres    1064960 Dec  9 06:33 pg_psort.25350.4
> -rw-------  1 postgres  postgres    1327104 Dec  9 06:33 pg_psort.25350.5
> -rw-------  1 postgres  postgres          0 Dec  9 06:32 pg_psort.25350.6
>
> I have another database that is almost identical on a different
> machine. There are no pg_psort.xxxx files there. I am wondering:
>
> 1. What are these files?

sort files for stuff like ORDER BY queries...

> 2. Do I need them?

as long as you aren't running a query, you can safely remove them...

> 3. If I don't need them is it safe to remove them?

yes...

Also, what version of PostgreSQL are you running?  I swore that more
recent versions of PostgreSQL cleaned up better behind itself...

Marc G. Fournier                   ICQ#7615664               IRC Nick: Scrappy
Systems Administrator @ hub.org
primary: scrappy@hub.org           secondary: scrappy@{freebsd|postgresql}.org


Re: [GENERAL] pg_psort files

From
Bruce Momjian
Date:
> I have a fairly simple database (two tables and a few indecies). In
> the data/base/xxxx directory I find the following files:
>
> -rw-------  1 postgres  postgres    7734146 Dec 14 06:36 pg_psort.13268.0
> -rw-------  1 postgres  postgres    7707487 Dec 14 06:36 pg_psort.13268.1
> -rw-------  1 postgres  postgres    7776602 Dec 14 06:36 pg_psort.13268.2
> -rw-------  1 postgres  postgres  936026112 Dec 14 07:20 pg_psort.13268.3
> -rw-------  1 postgres  postgres    8208384 Dec 14 06:36 pg_psort.13268.4
> -rw-------  1 postgres  postgres   15699116 Dec 14 06:36 pg_psort.13268.5
> -rw-------  1 postgres  postgres   19002244 Dec 14 06:36 pg_psort.13268.6
> -rw-------  1 postgres  postgres    2097152 Dec  9 06:33 pg_psort.25350.0
> -rw-------  1 postgres  postgres    2146304 Dec  9 06:33 pg_psort.25350.1
> -rw-------  1 postgres  postgres    2277376 Dec  9 06:33 pg_psort.25350.2
> -rw-------  1 postgres  postgres    1597440 Dec  9 06:33 pg_psort.25350.3
> -rw-------  1 postgres  postgres    1064960 Dec  9 06:33 pg_psort.25350.4
> -rw-------  1 postgres  postgres    1327104 Dec  9 06:33 pg_psort.25350.5
> -rw-------  1 postgres  postgres          0 Dec  9 06:32 pg_psort.25350.6
>
> I have another database that is almost identical on a different
> machine. There are no pg_psort.xxxx files there. I am wondering:
>
> 1. What are these files?
> 2. Do I need them?
> 3. If I don't need them is it safe to remove them?

Stop postmaster, remove files, restart postmaster.  They aren't needed.

I am surprised they are not automatically cleaned up.  What version are
you using?

--
  Bruce Momjian                        |  http://www.op.net/~candle
  maillist@candle.pha.pa.us            |  (610) 853-3000
  +  If your life is a hard drive,     |  830 Blythe Avenue
  +  Christ can be your backup.        |  Drexel Hill, Pennsylvania 19026

Re: [GENERAL] pg_psort files

From
Steven Saner
Date:
I'm running 6.5.1. We've had a bit of trouble with the machine
crashing that this database is on (I don't think it is because of
postgres) so my guess is that it was unable to clean up after itself
sometimes. Today, the filesystem where postgres lives on filled up,
that may be why as well. Thanks for the response.


On Tue, Dec 14, 1999 at 11:34:40AM -0500, Bruce Momjian wrote:
> >
> > 1. What are these files?
> > 2. Do I need them?
> > 3. If I don't need them is it safe to remove them?
>
> Stop postmaster, remove files, restart postmaster.  They aren't needed.
>
> I am surprised they are not automatically cleaned up.  What version are
> you using?
>
> --
>   Bruce Momjian                        |  http://www.op.net/~candle
>   maillist@candle.pha.pa.us            |  (610) 853-3000
>   +  If your life is a hard drive,     |  830 Blythe Avenue
>   +  Christ can be your backup.        |  Drexel Hill, Pennsylvania 19026

--
==================================================================
Steven Saner                            SouthWind Internet Access, Inc.
ssaner@southwind.net                    Systems/Network Administrator
http://www2.southwind.net/~ssaner       http://www.southwind.net
                                        263-7963 Wichita  (800)525-7963