Re: Temp file missing during large pgbench data set

Lists: pgsql-hackers
From: Thom Brown <thom(at)linux(dot)com>
To: PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Temp file missing during large pgbench data set
Date: 2012-01-28 01:53:24
Message-ID: CAA-aLv4JkMcKFxQ-eBrkLheMVNoqb7V+ZAWpF=yuvZyNHVROGw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

Hi,

I'm using latest git master (latest entry
0816fad6eebddb8f1f0e21635e46625815d690b9) and I'm getting an error
when trying to create a large data set with pgbench:

thom(at)swift:~/Development$ createdb pgbench
thom(at)swift:~/Development$ pgbench -i -s 100 pgbench
NOTICE: table "pgbench_branches" does not exist, skipping
NOTICE: table "pgbench_tellers" does not exist, skipping
NOTICE: table "pgbench_accounts" does not exist, skipping
NOTICE: table "pgbench_history" does not exist, skipping
creating tables...
10000 tuples done.
20000 tuples done.
30000 tuples done.
40000 tuples done.

<snip>

9970000 tuples done.
9980000 tuples done.
9990000 tuples done.
10000000 tuples done.
set primary key...
NOTICE: ALTER TABLE / ADD PRIMARY KEY will create implicit index
"pgbench_branches_pkey" for table "pgbench_branches"
NOTICE: ALTER TABLE / ADD PRIMARY KEY will create implicit index
"pgbench_tellers_pkey" for table "pgbench_tellers"
NOTICE: ALTER TABLE / ADD PRIMARY KEY will create implicit index
"pgbench_accounts_pkey" for table "pgbench_accounts"
LOG: could not stat file "base/pgsql_tmp/pgsql_tmp8056.0": Success
STATEMENT: alter table pgbench_accounts add primary key (aid)
vacuum...done.

I've tried this multiple times and the result is the same. I'm not
sure what this message means, but the primary key is created
successfully. If I reduce the scale to 20 the error doesn't occur.

The following changes were made to my postgresql.conf file:

max_connections = 300
shared_buffers = 3900MB
temp_buffers = 16MB
work_mem = 16MB
maintenance_work_mem = 256MB
checkpoint_segments = 32
random_page_cost = 1.1
effective_cache_size = 12GB

All other values are at default.

Is this anything to worry about?

--
Thom


From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Thom Brown <thom(at)linux(dot)com>, Magnus Hagander <magnus(at)hagander(dot)net>
Cc: PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Temp file missing during large pgbench data set
Date: 2012-01-28 04:30:34
Message-ID: 3945.1327725034@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

Thom Brown <thom(at)linux(dot)com> writes:
> I'm using latest git master (latest entry
> 0816fad6eebddb8f1f0e21635e46625815d690b9) and I'm getting an error
> when trying to create a large data set with pgbench:

> LOG: could not stat file "base/pgsql_tmp/pgsql_tmp8056.0": Success
> STATEMENT: alter table pgbench_accounts add primary key (aid)

I'll bet lunch this is due to some bug in commit
bc3347484a7bf9eddb98e4352d84599cae9a31c6

regards, tom lane


From: Magnus Hagander <magnus(at)hagander(dot)net>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Thom Brown <thom(at)linux(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Temp file missing during large pgbench data set
Date: 2012-01-28 08:57:59
Message-ID: CABUevEwac6O75C9N=q_PXHWghDjGmF0NDEqSq5pcpg6oSQvrcw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

On Sat, Jan 28, 2012 at 05:30, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> Thom Brown <thom(at)linux(dot)com> writes:
>> I'm using latest git master (latest entry
>> 0816fad6eebddb8f1f0e21635e46625815d690b9) and I'm getting an error
>> when trying to create a large data set with pgbench:
>
>> LOG:  could not stat file "base/pgsql_tmp/pgsql_tmp8056.0": Success
>> STATEMENT:  alter table pgbench_accounts add primary key (aid)
>
> I'll bet lunch this is due to some bug in commit
> bc3347484a7bf9eddb98e4352d84599cae9a31c6

Not taking that bet. There definitely is a pretty obvious bug in that.
Will look into it. Pretty sure the else branch is at the wrong
level...

--
 Magnus Hagander
 Me: http://www.hagander.net/
 Work: http://www.redpill-linpro.com/


From: Magnus Hagander <magnus(at)hagander(dot)net>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Thom Brown <thom(at)linux(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Temp file missing during large pgbench data set
Date: 2012-01-28 09:04:09
Message-ID: CABUevExDohwSLaruv=dwU+Xm3kA3yTjKuKBngSiNhxoojzrMtA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

On Sat, Jan 28, 2012 at 09:57, Magnus Hagander <magnus(at)hagander(dot)net> wrote:
> On Sat, Jan 28, 2012 at 05:30, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
>> Thom Brown <thom(at)linux(dot)com> writes:
>>> I'm using latest git master (latest entry
>>> 0816fad6eebddb8f1f0e21635e46625815d690b9) and I'm getting an error
>>> when trying to create a large data set with pgbench:
>>
>>> LOG:  could not stat file "base/pgsql_tmp/pgsql_tmp8056.0": Success
>>> STATEMENT:  alter table pgbench_accounts add primary key (aid)
>>
>> I'll bet lunch this is due to some bug in commit
>> bc3347484a7bf9eddb98e4352d84599cae9a31c6
>
> Not taking that bet. There definitely is a pretty obvious bug in that.
> Will look into it. Pretty sure the else branch is at the wrong
> level...

Yup, it was. Patch applied, can you confirm if that fixes your problem?

--
 Magnus Hagander
 Me: http://www.hagander.net/
 Work: http://www.redpill-linpro.com/


From: Thom Brown <thom(at)linux(dot)com>
To: Magnus Hagander <magnus(at)hagander(dot)net>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Temp file missing during large pgbench data set
Date: 2012-01-28 10:27:24
Message-ID: CAA-aLv76eaDw1FPMgXZotnF1iaHGZBOp7cnEROttK_2+DnKzQg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

On 28 January 2012 09:04, Magnus Hagander <magnus(at)hagander(dot)net> wrote:
> On Sat, Jan 28, 2012 at 09:57, Magnus Hagander <magnus(at)hagander(dot)net> wrote:
>> On Sat, Jan 28, 2012 at 05:30, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
>>> Thom Brown <thom(at)linux(dot)com> writes:
>>>> I'm using latest git master (latest entry
>>>> 0816fad6eebddb8f1f0e21635e46625815d690b9) and I'm getting an error
>>>> when trying to create a large data set with pgbench:
>>>
>>>> LOG:  could not stat file "base/pgsql_tmp/pgsql_tmp8056.0": Success
>>>> STATEMENT:  alter table pgbench_accounts add primary key (aid)
>>>
>>> I'll bet lunch this is due to some bug in commit
>>> bc3347484a7bf9eddb98e4352d84599cae9a31c6
>>
>> Not taking that bet. There definitely is a pretty obvious bug in that.
>> Will look into it. Pretty sure the else branch is at the wrong
>> level...
>
> Yup, it was. Patch applied, can you confirm if that fixes your problem?

Yes, looks fine now.

Thanks

--
Thom