.\" Process this file with
.\" groff -man -Tascii foo.1
.\"
.\" Copyright (c) 2007 Tokutek.  All Rights Reserved.
.TH DB_ENV->set_cachesize 3 "November 2007" Tokutek "TokuDB Programmer's Manual"
.SH NAME
DB->set_cachesize
.SH SYNOPSIS
.LP
\fB #include <db.h>
.br
.sp
.HP 13
.BI "int DB_ENV->set_cachesize(DB_ENV *" dbenv ", u_int32_t " gbytes ", u_int32_t " bytes ", int " ncache ");"
.br
.SH DESCRIPTION
\fBDB_ENV->set_cachesize\fr sets the size of the shared-memory buffer
pool (the cache) to \fIgbytes\fR* gibibytes plus \fIbytes\fR bytes.

.SH PARAMETERS
.IP \fIdbenv
The environment (which must have been created but not yet opened).

The environment is modified, not just this particular handle.  If some
other thread or process has opened the same environment, then this call
is ignored.
.IP \fIgbytes
The number of gibibytes (gibi equals 2^30, giga equals 10^9) to allocate.
.IP \fIbytes
The number of additional bytes to allocate.
.IP \fIncache
Ignored in TokuDB.
.SH RETURN VALUE
.LP
Returns zero on success.  The following non-zero errors can be returned:
.IP \fBEINVAL
You passed invalid parameters to this operation.  In many cases
\fBEINVAL\fR
is not a very helpful error code, indicating only that you did something wrong.
.SH CONFORMING TO
The TokuDB embedded database provides a subset of the functionality of
the Berkeley DB.  Programs that work with TokuDB probably work with
with most versions of Berkeley DB with only recompilation or
relinking.  The database files are incompatible, however, so to
convert from one library to the other you would need to dump the
database with one library's tool and load it with the other's.
.SH AUTHOR
Tokutek, Inc.
.SH COPYRIGHT
Copyright (c) 2007 Tokutek.  All Rights Reserved.