1
.. Licensed under the Apache License, Version 2.0 (the "License"); you may not
2
.. use this file except in compliance with the License. You may obtain a copy of
5
.. http://www.apache.org/licenses/LICENSE-2.0
7
.. Unless required by applicable law or agreed to in writing, software
8
.. distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
9
.. WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
10
.. License for the specific language governing permissions and limitations under
13
.. default-domain:: config
26
.. config:section:: couchdb :: Base CouchDB Options
29
.. config:option:: attachment_stream_buffer_size :: Attachment streaming buffer
31
Higher values may result in better read performance due to fewer read
32
operations and/or more OS page cache hits. However, they can also increase
33
overall response time for writes when there are many attachment write
39
attachment_stream_buffer_size = 4096
42
.. config:option:: database_dir :: Databases location directory
44
Specifies location of CouchDB database files (``*.couch`` named).
45
This location should be writable and readable for the user the CouchDB
46
service runs as (``couchdb`` by default).
51
database_dir = /var/lib/couchdb
54
.. config:option:: delayed_commits :: Delayed commits
56
When this config value as ``false`` the CouchDB provides guaranty of `fsync`
57
call before return :http:statuscode:`201` response on each document saving.
58
Setting this config value as ``true`` may raise some overall performance
59
with cost of losing durability - it's strongly not recommended to do such
63
delayed_commits = false
67
Delayed commits are a feature of CouchDB that allows it to achieve better
68
write performance for some workloads while sacrificing a small amount of
69
durability. The setting causes CouchDB to wait up to a full second before
70
committing new data after an update. If the server crashes before
71
the header is written then any writes since the last commit are lost.
74
.. config:option:: file_compression :: Compression method for documents
76
.. versionchanged:: 1.2 Added `Google Snappy`_ compression algorithm.
78
Method used to compress everything that is appended to database and
79
view index files, except for attachments (see the :section:`attachments`
80
section). Available methods are:
82
* ``none``: no compression
83
* ``snappy``: use Google Snappy, a very fast compressor/decompressor
84
* ``deflate_N``: use zlib's deflate; ``N`` is the compression level which
85
ranges from ``1`` (fastest, lowest compression ratio) to ``9`` (slowest,
86
highest compression ratio)
91
file_compression = snappy
93
.. _Google Snappy: http://code.google.com/p/snappy/
96
.. config:option:: fsync_options :: Fsync options
98
Specifies when to make `fsync` calls. `fsync` makes sure that
99
the contents of any file system buffers kept by the operating system are
100
flushed to disk. There is generally no need to modify this parameter.
105
fsync_options = [before_header, after_header, on_file_open]
108
.. config:option:: max_dbs_open :: Limit of simultaneously opened databases
110
This option places an upper bound on the number of databases that can be
111
open at once. CouchDB reference counts database accesses internally and will
112
close idle databases as needed. Sometimes it is necessary to keep more than
113
the default open at once, such as in deployments where many databases will
114
be replicating continuously.
122
.. config:option:: max_document_size :: Maximum document size
124
.. versionchanged:: 1.3 This option now actually works.
126
Defines a maximum size for JSON documents, in bytes. This limit does not
127
apply to attachments, since they are transferred as a stream of chunks.
128
If you set this to a small value, you might be unable to modify
129
configuration options, database security and other larger documents until
130
a larger value is restored by editing the configuration file.
135
max_document_size = 4294967296 ; 4 GB
138
.. config:option:: os_process_timeout :: External processes time limit
140
If an external process, such as a query server or external process, runs for
141
this amount of microseconds without returning any results, it will be
142
terminated. Keeping this value smaller ensures you get expedient errors, but
143
you may want to tweak it for your specific needs.
148
os_process_timeout = 5000 ; 5 sec
151
.. config:option:: uri_file :: Discovery CouchDB help file
153
This file contains the full `URI`_ that can be used to access this
154
instance of CouchDB. It is used to help discover the port CouchDB is running
155
on (if it was set to ``0`` (e.g. automatically assigned any free one).
156
This file should be writable and readable for the user that runs the CouchDB
157
service (``couchdb`` by default).
162
uri_file = /var/run/couchdb/couchdb.uri
164
.. _URI: http://en.wikipedia.org/wiki/URI
167
.. config:option:: util_driver_dir :: CouchDB binary utility drivers
169
Specifies location of binary drivers (`icu`, `ejson`, etc.). This location
170
and its contents should be readable for the user that runs the CouchDB
176
util_driver_dir = /usr/lib/couchdb/erlang/lib/couch-1.5.0/priv/lib
179
.. config:option:: uuid :: CouchDB server UUID
181
.. versionadded:: 1.3
183
Unique identifier for this CouchDB server instance.
188
uuid = 0a959b9b8227188afc2ac26ccdf345a6
191
.. config:option:: view_index_dir :: View indexes location directory
193
Specifies location of CouchDB view index files. This location should be
194
writable and readable for the user that runs the CouchDB service
195
(``couchdb`` by default).
200
view_index_dir = /var/lib/couchdb