From: Peter T Mount <peter@retep.org.uk>
To: Bruce Momjian <maillist@candle.pha.pa.us>
Cc: perdue@raccoon.com
Cc: tim@perdue.net
Cc: pgsql-hackers@hub.org
Cc: PostgreSQL Patches <pgsql-patches@postgreSQL.org>
Subject: Re: [HACKERS] URGENT - "CANNOT EXTEND"
Date: Sun, 14 Mar 1999 11:00:53 +0000 (GMT)
Message-ID: <Pine.LNX.4.04.9903141056560.16622-200000@maidast.retep.org.uk> (raw)
In-Reply-To: <199903140507.AAA09619@candle.pha.pa.us>
On Sun, 14 Mar 1999, Bruce Momjian wrote:
[snip]
> Peter Mount made the change. I don't see anything on our FTP server
> about that patch, so perhaps Peter will have to supply one, or we will
> have to grab one. If you search the hackers archive on the ftp site,
> you will see discussion about it, and perhaps a patch.
I've dug this out of my mail archives. It splits the relations at 1Gb.
This diff is from this mornings cvs.
Good job I don't delete what I send out ;-)
Peter
--
Peter T Mount peter@retep.org.uk
Main Homepage: http://www.retep.org.uk
PostgreSQL JDBC Faq: http://www.retep.org.uk/postgres
Java PDF Generator: http://www.retep.org.uk/pdfAttachments:psql-1gb-fix.diff (text/plain, 1.5K) download
*** ./backend/storage/smgr/md.c.orig Sun Mar 14 10:41:08 1999
--- ./backend/storage/smgr/md.c Sun Mar 14 10:54:07 1999
***************
*** 66,86 ****
* has to be calculated at compile time. Otherwise, the file
* size limit would not work out to 2-gig (2147483648).
*
! * The number needs to be (2 ** 31) / BLCKSZ, but to be keep
! * the math under MAXINT, pre-divide by 256 and use ...
*
! * (((2 ** 23) / BLCKSZ) * (2 ** 8))
*
* 07 Jan 98 darrenk
*
* Now possibly let the OS handle it...
*
* 19 Mar 98 darrenk
*
*/
#ifndef LET_OS_MANAGE_FILESIZE
! #define RELSEG_SIZE ((8388608 / BLCKSZ) * 256)
#endif
/* routines declared here */
--- 66,94 ----
* has to be calculated at compile time. Otherwise, the file
* size limit would not work out to 2-gig (2147483648).
*
! * The number needs to be MAX_FILE_SIZE / BLCKSZ, but to be
! * keep the math under MAXINT, pre-divide by 256 and use ...
*
! * (7812500 / BLCKSZ) * 256
*
* 07 Jan 98 darrenk
+ * 07 Feb 99 peter (rewrite)
*
* Now possibly let the OS handle it...
*
* 19 Mar 98 darrenk
*
+ * Reduced the maximum file size from 2147483648 (2Gb) to 1073741824 (1Gb)+ * to prevent a possible overflow in the OS (You can't have a file exactly+ * 2Gb in size).+ *+ * 07 Feb 99 peter+ * 14 Mar 99 peter (resubmitted lost patch)+ *
*/
#ifndef LET_OS_MANAGE_FILESIZE
! #define RELSEG_SIZE ((4194304 / BLCKSZ) * 256)
#endif
/* routines declared here */
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-sql@postgresql.org
Cc: peter@retep.org.uk, maillist@candle.pha.pa.us, perdue@raccoon.com, tim@perdue.net, pgsql-hackers@hub.org, pgsql-patches@postgreSQL.org
Subject: Re: [HACKERS] URGENT - "CANNOT EXTEND"
In-Reply-To: <Pine.LNX.4.04.9903141056560.16622-200000@maidast.retep.org.uk>
References: <199903140507.AAA09619@candle.pha.pa.us> <Pine.LNX.4.04.9903141056560.16622-200000@maidast.retep.org.uk>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox