diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2008-03-10 20:06:27 +0000 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2008-03-10 20:06:27 +0000 |
commit | f0828b2fc3d021ef8d64337a3593eb44bd3b6114 (patch) | |
tree | 493c0b5d4275d6d65f7ef3009dede802a607d478 /src/include/pg_config_manual.h | |
parent | b6912af22bc9e6073d2dd05789a09f7f81b18d14 (diff) |
Provide a build-time option to store large relations as single files, rather
than dividing them into 1GB segments as has been our longtime practice. This
requires working support for large files in the operating system; at least for
the time being, it won't be the default.
Zdenek Kotala
Diffstat (limited to 'src/include/pg_config_manual.h')
-rw-r--r-- | src/include/pg_config_manual.h | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/src/include/pg_config_manual.h b/src/include/pg_config_manual.h index 0a1e8233d3e..c0d546761a8 100644 --- a/src/include/pg_config_manual.h +++ b/src/include/pg_config_manual.h @@ -6,7 +6,7 @@ * for developers. If you edit any of these, be sure to do a *full* * rebuild (and an initdb if noted). * - * $PostgreSQL: pgsql/src/include/pg_config_manual.h,v 1.28 2008/02/29 20:58:33 alvherre Exp $ + * $PostgreSQL: pgsql/src/include/pg_config_manual.h,v 1.29 2008/03/10 20:06:27 tgl Exp $ *------------------------------------------------------------------------ */ @@ -27,8 +27,9 @@ /* * RELSEG_SIZE is the maximum number of blocks allowed in one disk - * file. Thus, the maximum size of a single file is RELSEG_SIZE * - * BLCKSZ; relations bigger than that are divided into multiple files. + * file when USE_SEGMENTED_FILES is defined. Thus, the maximum size + * of a single file is RELSEG_SIZE * BLCKSZ; relations bigger than that + * are divided into multiple files. * * RELSEG_SIZE * BLCKSZ must be less than your OS' limit on file size. * This is often 2 GB or 4GB in a 32-bit operating system, unless you @@ -39,9 +40,16 @@ * in the direction of a small limit. (Besides, a power-of-2 value * saves a few cycles in md.c.) * + * When not using segmented files, RELSEG_SIZE is set to zero so that + * this behavior can be distinguished in pg_control. + * * Changing RELSEG_SIZE requires an initdb. */ +#ifdef USE_SEGMENTED_FILES #define RELSEG_SIZE (0x40000000 / BLCKSZ) +#else +#define RELSEG_SIZE 0 +#endif /* * Size of a WAL file block. This need have no particular relation to BLCKSZ. |