| From: | Jon Nelson <jnelson+pgsql(at)jamponi(dot)net> |
|---|---|
| To: | pgsql-bugs(at)postgresql(dot)org |
| Subject: | crazy logging from PG 8.4 |
| Date: | 2013-10-23 14:00:21 |
| Message-ID: | CAKuK5J3pOn9TnZ0LvZV7G+8bT8PTzAXti4+TLpWzuAd0s+2CNA@mail.gmail.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-bugs |
After several days of running a simple query over a very large dataset
(more than a terabyte), I logged in to note that postgresql had
decided to log *billions* of log lines.
The query looks like this:
create table result_table as
select TEXTFIELD, count(distinct INTFIELD) from SOME_HUGE_TABLE group
by TEXTFIELD;
At some point, PG started logging stuff that looked like this (over
and over again):
SELECT 2704204951 user(at)dbname LOG: 00000: performsort starting: CPU 0.00....
The 2704204951 number corresponds to the "%l" (session line number)
in log_line_prefix. Thus, by the time I saw this, it had logged 2.7
billion lines.
An strace of the process showed this, over and over again:
getrusage(....)
write(2, <logging info>)
and nothing else. What happened here? It seems like PG just went
crazy and got itself into some sort of loop. I had to kill the query.
This is PostgreSQL 8.4.13 on x86_64, Linux, using Scientific Linux 6.4.
--
Jon
| From | Date | Subject | |
|---|---|---|---|
| Next Message | almir.manaus | 2013-10-23 14:36:34 | BUG #8551: Erro reinstalação |
| Previous Message | Tom Lane | 2013-10-23 13:08:04 | Re: random() generates collisions too early |