Skip to content

Commit 0f8fc35

Browse files
committed
Increase default value of effective_cache_size to 128MB, per discussion.
1 parent ffae5cc commit 0f8fc35

File tree

3 files changed

+8
-8
lines changed

3 files changed

+8
-8
lines changed

doc/src/sgml/config.sgml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<!-- $PostgreSQL: pgsql/doc/src/sgml/config.sgml,v 1.88 2006/09/18 12:11:36 teodor Exp $ -->
1+
<!-- $PostgreSQL: pgsql/doc/src/sgml/config.sgml,v 1.89 2006/09/25 22:12:24 tgl Exp $ -->
22

33
<chapter Id="runtime-config">
44
<title>Server Configuration</title>
@@ -1905,21 +1905,21 @@ archive_command = 'copy "%p" /mnt/server/archivedir/"%f"' # Windows
19051905
<listitem>
19061906
<para>
19071907
Sets the planner's assumption about the effective size of the
1908-
disk cache that is available to a single index scan. This is
1908+
disk cache that is available to a single query. This is
19091909
factored into estimates of the cost of using an index; a
19101910
higher value makes it more likely index scans will be used, a
19111911
lower value makes it more likely sequential scans will be
19121912
used. When setting this parameter you should consider both
19131913
<productname>PostgreSQL</productname>'s shared buffers and the
19141914
portion of the kernel's disk cache that will be used for
19151915
<productname>PostgreSQL</productname> data files. Also, take
1916-
into account the expected number of concurrent queries using
1917-
different indexes, since they will have to share the available
1916+
into account the expected number of concurrent queries on different
1917+
tables, since they will have to share the available
19181918
space. This parameter has no effect on the size of shared
19191919
memory allocated by <productname>PostgreSQL</productname>, nor
19201920
does it reserve kernel disk cache; it is used only for
19211921
estimation purposes. The value is measured in disk pages,
1922-
which are normally 8192 bytes each. The default is 1000.
1922+
which are normally 8192 bytes each. The default is 16384 (128 MB).
19231923
</para>
19241924
</listitem>
19251925
</varlistentry>

src/backend/utils/misc/postgresql.conf.sample

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -195,7 +195,7 @@
195195
#cpu_tuple_cost = 0.01 # same scale as above
196196
#cpu_index_tuple_cost = 0.005 # same scale as above
197197
#cpu_operator_cost = 0.0025 # same scale as above
198-
#effective_cache_size = 8000kB
198+
#effective_cache_size = 128MB
199199

200200
# - Genetic Query Optimizer -
201201

src/include/optimizer/cost.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
* Portions Copyright (c) 1996-2006, PostgreSQL Global Development Group
88
* Portions Copyright (c) 1994, Regents of the University of California
99
*
10-
* $PostgreSQL: pgsql/src/include/optimizer/cost.h,v 1.80 2006/09/19 22:49:53 tgl Exp $
10+
* $PostgreSQL: pgsql/src/include/optimizer/cost.h,v 1.81 2006/09/25 22:12:24 tgl Exp $
1111
*
1212
*-------------------------------------------------------------------------
1313
*/
@@ -27,7 +27,7 @@
2727
#define DEFAULT_CPU_INDEX_TUPLE_COST 0.005
2828
#define DEFAULT_CPU_OPERATOR_COST 0.0025
2929

30-
#define DEFAULT_EFFECTIVE_CACHE_SIZE 1000 /* measured in pages */
30+
#define DEFAULT_EFFECTIVE_CACHE_SIZE 16384 /* measured in pages */
3131

3232

3333
/*

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy