Re: PostgreSQL won't start

Поиск
Список
Период
Сортировка
От Kevin Grittner
Тема Re: PostgreSQL won't start
Дата
Msg-id 591533476.500736.1441921198320.JavaMail.yahoo@mail.yahoo.com
обсуждение исходный текст
Ответ на PostgreSQL won't start  (Laura Horsky <lhorsky@gwoslabs.com>)
Список pgsql-admin
Laura Horsky <lhorsky@gwoslabs.com> wrote:

> I have a PostgreSQL server that was restarted. When it was
> brought back online,

That is pretty vague.  Exactly how was it restarted?  How was it
brought back online?  Was it really just that, or was this a
restore from backup or a copy on a new machine?

Exactly what version of PostgreSQL is this?

> PostgreSQL fails to start with:
>
> ....LOG:  database system was interrupted; last known up at ....

You didn't get a clean shutdown of the database server, so
something was done that was not optimal.  We can't give very
detailed advice without knowing what.  By the way, seeing
timestamps for the startup and the "last known up at" times would
provide at least some clue what might have happened.

> I have pg_dumps that were taken prior to failure that I can
> restore to if I can get PostgreSQL running again.

That's good.  If you wrangle what you have into starting you should
hang onto those dumps for a while (maybe a few months) after you
are running again.  You may need to fish some data out of them if
you later see corruption or missing data.

> How can I fix PostgreSQL? I have seen pg_resetxlog but there are
> so many warnings, I want to make sure that this is the tool to
> use.

First thing is to make a filesystem-level copy of the $PGDATA
directory tree, in case your recovery attempts make things worse.
pg_resetxlog may well allow the database to start, but you should
heed the warnings about pg_dump and restore of the result to
eliminate hidden corruption, and review after that to look for
damaged or missing data.

--
Kevin Grittner
EDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company


В списке pgsql-admin по дате отправления:

Предыдущее
От: John Scalia
Дата:
Сообщение: Re: Cannot get extensions to load
Следующее
От: Craig James
Дата:
Сообщение: Re: Cannot get extensions to load