Re: OID and filesystem issues - Mailing list pgsql-admin

From Tom Lane
Subject Re: OID and filesystem issues
Date
Msg-id 13347.1208270636@sss.pgh.pa.us
Whole thread Raw
In response to OID and filesystem issues  (lfedden@contextworld.com)
List pgsql-admin
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
withfilesystem. 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

pgsql-admin by date:

Previous
From: "Dmitry Shubin"
Date:
Subject: Re: postgres 8.1 usermanagement problem
Next
From: lfedden@contextworld.com
Date:
Subject: Re: OID and filesystem issues