Re: pgsql: Define a separately configurable XLOG_BLCKSZ symbol for the page

From: "Qingqing Zhou" <zhouqq(at)cs(dot)toronto(dot)edu>
To: pgsql-committers(at)postgresql(dot)org
Subject: Re: pgsql: Define a separately configurable XLOG_BLCKSZ symbol for the page
Date: 2006-04-04 09:23:05
Message-ID: e0tdtm$l07$1@news.hub.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers


"Tom Lane" <tgl(at)postgresql(dot)org> wrote
> xlog.c (r1.231 -> r1.232)
>
> (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/access/transam/xlog.c.diff?r1=1.231&r2=1.232)
>

Sorry for my after-fact idea ... I noticed this line in the patch:

@@ -2708,7 +2708,7 @@ ReadRecord(XLogRecPtr *RecPtr, int emode
readId, readSeg, readOff)));
goto next_record_is_invalid;
}
- if (read(readFile, readBuf, BLCKSZ) != BLCKSZ)
+ if (read(readFile, readBuf, XLOG_BLCKSZ) != XLOG_BLCKSZ)
{
ereport(emode,
(errcode_for_file_access(),

This is a patch for write performance, but here theoretically decreases the
read performance due to the possible setting of XLOG_BLCKSZ (say 512 as
sector size, which is << BLCKSZ). It maybe avoidable by still using BLCKSZ
or even more aggresive block size, but may also need some local tweak here.

Regards,
Qingqing

In response to

Responses

Browse pgsql-committers by date

  From Date Subject
Next Message Tom Lane 2006-04-04 13:36:09 Re: pgsql: Define a separately configurable XLOG_BLCKSZ symbol for the page
Previous Message James William Pye 2006-04-04 04:53:03 python - fe: Fix relation reference for notify warning.