Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit0f8fc35

Browse files
committed
Increase default value of effective_cache_size to 128MB, per discussion.
1 parentffae5cc commit0f8fc35

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/1812: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 singleindex scan. This is
1908+
disk cache that is available to a singlequery. 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 queriesusing
1917-
different indexes, since they will have to share the available
1916+
into account the expected number of concurrent querieson 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 is1000.
1922+
which are normally 8192 bytes each. The default is16384 (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
#defineDEFAULT_CPU_INDEX_TUPLE_COST 0.005
2828
#defineDEFAULT_CPU_OPERATOR_COST 0.0025
2929

30-
#defineDEFAULT_EFFECTIVE_CACHE_SIZE1000/* measured in pages */
30+
#defineDEFAULT_EFFECTIVE_CACHE_SIZE16384/* measured in pages */
3131

3232

3333
/*

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp