pg.ddx.io pgsql-admin@postgresql.org mailing list archive
help / color / mirror / Atom feedcatalog corruption causes
6+ messages / 3 participants
[nested] [flat]
* catalog corruption causes
@ 2010-08-06 18:28 Burgholzer, Robert (DEQ) <Robert.Burgholzer@deq.virginia.gov>
2010-08-06 18:57 ` Re: catalog corruption causes Kevin Grittner <Kevin.Grittner@wicourts.gov>
2010-08-06 20:54 ` Re: catalog corruption causes Scott Marlowe <scott.marlowe@gmail.com>
2010-08-06 20:56 ` Re: catalog corruption causes Scott Marlowe <scott.marlowe@gmail.com>
0 siblings, 3 replies; 6+ messages in thread
From: Burgholzer, Robert (DEQ) @ 2010-08-06 18:28 UTC (permalink / raw)
To: pgsql-admin
I am trying to get my head around what causes catalog corruption. I
have posted before with regard to recovering from corruptions (if that
is what indeed happened to me), and was given much help.
Does anyone know why a database catalog will get corrupted? As I
mentioned previously, my db involves considerable use of temporary
tables created by php-psql connections. Other than that, I don't know
of too much that is "odd" about my use (misuse) of the database.
Thanks,
r.b.
Robert W. Burgholzer
Surface Water Modeler
Office of Water Supply and Planning
Virginia Department of Environmental Quality
rwburgholzer@deq.virginia.gov
804-698-4405
Open Source Modeling Tools:
http://sourceforge.net/projects/npsource/
^ permalink raw reply [nested|flat] 6+ messages in thread
* Re: catalog corruption causes
2010-08-06 18:28 catalog corruption causes Burgholzer, Robert (DEQ) <Robert.Burgholzer@deq.virginia.gov>
@ 2010-08-06 18:57 ` Kevin Grittner <Kevin.Grittner@wicourts.gov>
2010-08-06 18:59 ` Re: catalog corruption causes Burgholzer, Robert (DEQ) <Robert.Burgholzer@deq.virginia.gov>
2 siblings, 1 reply; 6+ messages in thread
From: Kevin Grittner @ 2010-08-06 18:57 UTC (permalink / raw)
To: Robert (DEQ) Burgholzer <Robert.Burgholzer@deq.virginia.gov>; pgsql-admin
"Burgholzer, Robert (DEQ)" <Robert.Burgholzer@deq.virginia.gov>
wrote:
> I am trying to get my head around what causes catalog corruption.
From what I've seen many are caused by things outside of PostgreSQL
-- like bad disk, bad drivers, OS bugs, running on network drives
which aren't reliable, write caches without battery back-up,
anti-virus software, etc.
Another common cause is using faster-but-unreliable PostgreSQL
configuration settings like fsync=off or full_page_writes=off. If
that's couple with a kill -9 or a crash of hardware or OS, you can
get corruption.
Then there's the possibility of PostgreSQL bugs. Make sure you use
a recent minor release of whatever major release you're on, so you
get the benefit of bug fixes. And I recommend staying away from
VACUUM FULL -- among the many other reasons there are to avoid it,
it seems to have more than it's share of odd corner cases where
things can go wrong.
Less likely, but still possible, is that there's some malicious
element involved. Keep your security tight to minimize the risk of
that.
-Kevin
^ permalink raw reply [nested|flat] 6+ messages in thread
* Re: catalog corruption causes
2010-08-06 18:28 catalog corruption causes Burgholzer, Robert (DEQ) <Robert.Burgholzer@deq.virginia.gov>
2010-08-06 18:57 ` Re: catalog corruption causes Kevin Grittner <Kevin.Grittner@wicourts.gov>
@ 2010-08-06 18:59 ` Burgholzer, Robert (DEQ) <Robert.Burgholzer@deq.virginia.gov>
0 siblings, 0 replies; 6+ messages in thread
From: Burgholzer, Robert (DEQ) @ 2010-08-06 18:59 UTC (permalink / raw)
To: pgsql-admin
Thanks Kevin, that gives me more than enough things to pepper my
sysadmin with. :)
r.b.
Robert W. Burgholzer
Surface Water Modeler
Office of Water Supply and Planning
Virginia Department of Environmental Quality
rwburgholzer@deq.virginia.gov
804-698-4405
Open Source Modeling Tools:
http://sourceforge.net/projects/npsource/
^ permalink raw reply [nested|flat] 6+ messages in thread
* Re: catalog corruption causes
2010-08-06 18:28 catalog corruption causes Burgholzer, Robert (DEQ) <Robert.Burgholzer@deq.virginia.gov>
@ 2010-08-06 20:54 ` Scott Marlowe <scott.marlowe@gmail.com>
2 siblings, 0 replies; 6+ messages in thread
From: Scott Marlowe @ 2010-08-06 20:54 UTC (permalink / raw)
To: Burgholzer, Robert (DEQ) <Robert.Burgholzer@deq.virginia.gov>; +Cc: pgsql-admin
On Fri, Aug 6, 2010 at 12:28 PM, Burgholzer, Robert (DEQ)
<Robert.Burgholzer@deq.virginia.gov> wrote:
> I am trying to get my head around what causes catalog corruption. I
> have posted before with regard to recovering from corruptions (if that
> is what indeed happened to me), and was given much help.
>
> Does anyone know why a database catalog will get corrupted? As I
> mentioned previously, my db involves considerable use of temporary
> tables created by php-psql connections. Other than that, I don't know
> of too much that is "odd" about my use (misuse) of the database.
Two most common causes are bad memory / hard drives / cpu and a
machine that doesn't fsync properly crashing and losing part of a
write to the disks.
memtest86+ will give you an idea if your hardware (cpu / mem) are
stable and reliable. SMART can tell you if your hard drives are
acting up. pgbench can tell you if your system is lying about fsync
(a single SATA drive shouldn't be able to do more than a few hundred
tps).
^ permalink raw reply [nested|flat] 6+ messages in thread
* Re: catalog corruption causes
2010-08-06 18:28 catalog corruption causes Burgholzer, Robert (DEQ) <Robert.Burgholzer@deq.virginia.gov>
@ 2010-08-06 20:56 ` Scott Marlowe <scott.marlowe@gmail.com>
2010-08-09 15:23 ` Re: catalog corruption causes Burgholzer, Robert (DEQ) <Robert.Burgholzer@deq.virginia.gov>
2 siblings, 1 reply; 6+ messages in thread
From: Scott Marlowe @ 2010-08-06 20:56 UTC (permalink / raw)
To: Burgholzer, Robert (DEQ) <Robert.Burgholzer@deq.virginia.gov>; +Cc: pgsql-admin
On Fri, Aug 6, 2010 at 12:28 PM, Burgholzer, Robert (DEQ)
<Robert.Burgholzer@deq.virginia.gov> wrote:
> I am trying to get my head around what causes catalog corruption. I
> have posted before with regard to recovering from corruptions (if that
> is what indeed happened to me), and was given much help.
>
> Does anyone know why a database catalog will get corrupted? As I
> mentioned previously, my db involves considerable use of temporary
> tables created by php-psql connections. Other than that, I don't know
> of too much that is "odd" about my use (misuse) of the database.
Note that it's also possible you've found some uncommon corner case
with pgsql code. If you have tested memory / cpu and can consistently
get corrupted catalogs by running a particular sequence of commands
against pgsql over and over then definitely report it and provide a
test case. Guidance on reporting problems here:
http://wiki.postgresql.org/wiki/Guide_to_reporting_problems
^ permalink raw reply [nested|flat] 6+ messages in thread
* Re: catalog corruption causes
2010-08-06 18:28 catalog corruption causes Burgholzer, Robert (DEQ) <Robert.Burgholzer@deq.virginia.gov>
2010-08-06 20:56 ` Re: catalog corruption causes Scott Marlowe <scott.marlowe@gmail.com>
@ 2010-08-09 15:23 ` Burgholzer, Robert (DEQ) <Robert.Burgholzer@deq.virginia.gov>
0 siblings, 0 replies; 6+ messages in thread
From: Burgholzer, Robert (DEQ) @ 2010-08-09 15:23 UTC (permalink / raw)
To: pgsql-admin
Thanks Scott,
I will look into these testing programs and file a bug if I have in fact
found a special occurrence. I suspect that there might be some issues
with our postgres install, as the initial install was via a yum, and I
recall that our sysadmin had some difficulty removing it in order to do
a compile from source install. We have also experienced one or two
cases of strange hard drive behavior, so this gives us some avenues to
explore.
r.b.
Robert W. Burgholzer
Surface Water Modeler
Office of Water Supply and Planning
Virginia Department of Environmental Quality
rwburgholzer@deq.virginia.gov
804-698-4405
Open Source Modeling Tools:
http://sourceforge.net/projects/npsource/
^ permalink raw reply [nested|flat] 6+ messages in thread
end of thread, other threads:[~2010-08-09 15:23 UTC | newest]
Thread overview: 6+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2010-08-06 18:28 catalog corruption causes Burgholzer, Robert (DEQ) <Robert.Burgholzer@deq.virginia.gov>
2010-08-06 18:57 ` Kevin Grittner <Kevin.Grittner@wicourts.gov>
2010-08-06 18:59 ` Burgholzer, Robert (DEQ) <Robert.Burgholzer@deq.virginia.gov>
2010-08-06 20:54 ` Scott Marlowe <scott.marlowe@gmail.com>
2010-08-06 20:56 ` Scott Marlowe <scott.marlowe@gmail.com>
2010-08-09 15:23 ` Burgholzer, Robert (DEQ) <Robert.Burgholzer@deq.virginia.gov>
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