Re: "global/pgstat.stat" corrupt - Mailing list pgsql-performance

From Tom Lane
Subject Re: "global/pgstat.stat" corrupt
Date
Msg-id 17700.1340394540@sss.pgh.pa.us
Whole thread Raw
In response to "global/pgstat.stat" corrupt  (David Kerr <dmk@mr-paradox.net>)
Responses Re: "global/pgstat.stat" corrupt
List pgsql-performance
David Kerr <dmk@mr-paradox.net> writes:
> I just restored a DB from a cold backup (pg_ctl stop -m fast)

> When starting the DB I see:
> LOG:  corrupted statistics file "global/pgstat.stat"

Is that repeatable?  It wouldn't be too surprising to see this once when
starting from a filesystem backup, if you'd managed to capture a
partially written stats file in the backup.

> When I look at the filesystem I don't see a global/pgstat.stat file but i do see a
> pg_stat_tmp/pgstat.stat

This is normal --- global/pgstat.stat is only supposed to exist when the
system is shut down.  Transient updates are written into pg_stat_tmp/

> Are those stats related to pg_stats style statistics?

No, this file is for the stats collection subsystem,
http://www.postgresql.org/docs/9.1/static/monitoring-stats.html

            regards, tom lane

pgsql-performance by date:

Previous
From: David Kerr
Date:
Subject: "global/pgstat.stat" corrupt
Next
From: David Kerr
Date:
Subject: Re: "global/pgstat.stat" corrupt