pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: lfedden@contextworld.com
Cc: pgsql-admin@postgresql.org
Subject: Re: OID and filesystem issues
Date: Tue, 15 Apr 2008 10:43:56 -0400
Message-ID: <13347.1208270636@sss.pgh.pa.us> (raw)
In-Reply-To: <4F9161CEA8.07DC005BTFSFDCZG@contextworld.com>
References: <4F9161CEA8.07DC005BTFSFDCZG@contextworld.com>

lfedden@contextworld.com writes:
> 1) Does every relation exist in pg_class? Can we assume that if there is a file with OID which is not present in pg_class, this file can be deleted? (we have a few such files, some of them take more than 2G of space in total)

You do know it's relfilenode that counts, not OID?

As long as you are paying attention to the right column, yes, you could
remove any file that doesn't correspond to a live pg_class row.  It's
not a common situation though so I'd definitely triple-check first.

> 3) We have a relation which is unaccessible (permission denied), ls -l also prints this message so it's something with filesystem. What would be the best procedure to solve this issue ?

Fix the ownership/permissions with chown/chmod, as needed.  Pretty much
all files in a database should be alike in this regard (postgres-owned,
mode 0600).

			regards, tom lane



view thread (4+ messages)  latest in thread

Message-ID: <13347.1208270636@sss.pgh.pa.us>
Permalink:  ../13347.1208270636@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/13347.1208270636@sss.pgh.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 using the --to and --cc options:
  reply via email

  To: pgsql-admin@postgresql.org
  Cc: tgl@sss.pgh.pa.us, lfedden@contextworld.com
  Subject: Re: OID and filesystem issues
  In-Reply-To: <13347.1208270636@sss.pgh.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