Re: "recovering prepared transaction" after server restart message
От | Tom Lane |
---|---|
Тема | Re: "recovering prepared transaction" after server restart message |
Дата | |
Msg-id | 27067.1162536485@sss.pgh.pa.us обсуждение исходный текст |
Ответ на | "recovering prepared transaction" after server restart message ("Joachim Wieland" <joe@mcknight.de>) |
Ответы |
Re: "recovering prepared transaction" after serverrestart message
|
Список | pgsql-hackers |
"Joachim Wieland" <joe@mcknight.de> writes: > There have been several reports that people could not vacuum any more or > observed strange locks even after server restart. The reason was that they > still had uncommitted prepared transactions around. > I wonder if it could help to change the log level from > ereport(LOG, > (errmsg("recovering prepared transaction %u", xid))); > to WARNING maybe in order to make that message more striking within the > normal startup messages. That doesn't seem like a good idea. In the first place, recovering prepared xacts is exactly what system restart is *supposed* to do, and so calling it a WARNING seems out of line. (I'm not real sure why that message is even LOG level, rather than DEBUG1 or below.) In the second place, this wouldn't help anyone unless they tried to fix their problem by restarting the server --- a mentality suited only for Windows users, and certainly not something a production system is going to do lightly --- and then thought to look in the postmaster log, which the average Windows user wouldn't. I agree that there's a usability issue here though; I've been burnt by forgotten prepared xacts myself (eg by control-C'ing pg_regress at just the wrong time). Would it help if we included prepared xacts in the pg_stat_activity view? Is there any other place we could make them more visible during normal server operation? regards, tom lane
В списке pgsql-hackers по дате отправления: