mirror of
https://github.com/berkeleydb/libdb.git
synced 2024-11-16 09:06:25 +00:00
186 lines
7.4 KiB
HTML
186 lines
7.4 KiB
HTML
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||
<head>
|
||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
|
||
<title>Chapter 9. The Berkeley DB Environment</title>
|
||
<link rel="stylesheet" href="gettingStarted.css" type="text/css" />
|
||
<meta name="generator" content="DocBook XSL Stylesheets V1.73.2" />
|
||
<link rel="start" href="index.html" title="Berkeley DB Programmer's Reference Guide" />
|
||
<link rel="up" href="index.html" title="Berkeley DB Programmer's Reference Guide" />
|
||
<link rel="prev" href="arch_utilities.html" title="Supporting utilities" />
|
||
<link rel="next" href="env_create.html" title="Creating a database environment" />
|
||
</head>
|
||
<body>
|
||
<div xmlns="" class="navheader">
|
||
<div class="libver">
|
||
<p>Library Version 11.2.5.3</p>
|
||
</div>
|
||
<table width="100%" summary="Navigation header">
|
||
<tr>
|
||
<th colspan="3" align="center">Chapter 9.
|
||
The Berkeley DB Environment
|
||
</th>
|
||
</tr>
|
||
<tr>
|
||
<td width="20%" align="left"><a accesskey="p" href="arch_utilities.html">Prev</a> </td>
|
||
<th width="60%" align="center"> </th>
|
||
<td width="20%" align="right"> <a accesskey="n" href="env_create.html">Next</a></td>
|
||
</tr>
|
||
</table>
|
||
<hr />
|
||
</div>
|
||
<div class="chapter" lang="en" xml:lang="en">
|
||
<div class="titlepage">
|
||
<div>
|
||
<div>
|
||
<h2 class="title"><a id="env"></a>Chapter 9.
|
||
The Berkeley DB Environment
|
||
</h2>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
<div class="toc">
|
||
<p>
|
||
<b>Table of Contents</b>
|
||
</p>
|
||
<dl>
|
||
<dt>
|
||
<span class="sect1">
|
||
<a href="env.html#env_intro">Database environment introduction</a>
|
||
</span>
|
||
</dt>
|
||
<dt>
|
||
<span class="sect1">
|
||
<a href="env_create.html">Creating a database environment</a>
|
||
</span>
|
||
</dt>
|
||
<dt>
|
||
<span class="sect1">
|
||
<a href="env_size.html">Sizing a database environment</a>
|
||
</span>
|
||
</dt>
|
||
<dt>
|
||
<span class="sect1">
|
||
<a href="env_open.html">Opening databases within the environment</a>
|
||
</span>
|
||
</dt>
|
||
<dt>
|
||
<span class="sect1">
|
||
<a href="env_error.html">Error support</a>
|
||
</span>
|
||
</dt>
|
||
<dt>
|
||
<span class="sect1">
|
||
<a href="env_db_config.html">DB_CONFIG configuration file</a>
|
||
</span>
|
||
</dt>
|
||
<dt>
|
||
<span class="sect1">
|
||
<a href="env_naming.html">File naming</a>
|
||
</span>
|
||
</dt>
|
||
<dd>
|
||
<dl>
|
||
<dt>
|
||
<span class="sect2">
|
||
<a href="env_naming.html#idp1570112">Specifying file naming to Berkeley DB</a>
|
||
</span>
|
||
</dt>
|
||
<dt>
|
||
<span class="sect2">
|
||
<a href="env_naming.html#idp1584200">Filename resolution in Berkeley DB</a>
|
||
</span>
|
||
</dt>
|
||
<dt>
|
||
<span class="sect2">
|
||
<a href="env_naming.html#idp1605872">Examples</a>
|
||
</span>
|
||
</dt>
|
||
</dl>
|
||
</dd>
|
||
<dt>
|
||
<span class="sect1">
|
||
<a href="env_region.html">Shared memory regions</a>
|
||
</span>
|
||
</dt>
|
||
<dt>
|
||
<span class="sect1">
|
||
<a href="env_security.html">Security</a>
|
||
</span>
|
||
</dt>
|
||
<dt>
|
||
<span class="sect1">
|
||
<a href="env_encrypt.html">Encryption</a>
|
||
</span>
|
||
</dt>
|
||
<dt>
|
||
<span class="sect1">
|
||
<a href="env_remote.html">Remote filesystems</a>
|
||
</span>
|
||
</dt>
|
||
<dt>
|
||
<span class="sect1">
|
||
<a href="env_faq.html">Environment FAQ</a>
|
||
</span>
|
||
</dt>
|
||
</dl>
|
||
</div>
|
||
<div class="sect1" lang="en" xml:lang="en">
|
||
<div class="titlepage">
|
||
<div>
|
||
<div>
|
||
<h2 class="title" style="clear: both"><a id="env_intro"></a>Database environment introduction</h2>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
<p>A Berkeley DB environment is an encapsulation of one or more databases, log
|
||
files and region files. Region files are the shared memory areas that
|
||
contain information about the database environment such as memory pool
|
||
cache pages. Only databases are byte-order independent and only
|
||
database files can be moved between machines of different byte orders.
|
||
Log files can be moved between machines of the same byte order. Region
|
||
files are usually unique to a specific machine and potentially to a
|
||
specific operating system release.</p>
|
||
<p>The simplest way to administer a Berkeley DB application environment is to
|
||
create a single <span class="bold"><strong>home</strong></span> directory that stores the files for the
|
||
applications that will share the environment. The environment home
|
||
directory must be created before any Berkeley DB applications are run. Berkeley DB
|
||
itself never creates the environment home directory. The environment can
|
||
then be identified by the name of that directory.</p>
|
||
<p>An environment may be shared by any number of processes, as well as by
|
||
any number of threads within those processes. It is possible for an
|
||
environment to include resources from other directories on the system,
|
||
and applications often choose to distribute resources to other
|
||
directories or disks for performance or other reasons. However, by
|
||
default, the databases, shared regions (the locking, logging, memory
|
||
pool, and transaction shared memory areas) and log files will be stored
|
||
in a single directory hierarchy.</p>
|
||
<p>It is important to realize that all applications sharing a database
|
||
environment implicitly trust each other. They have access to each
|
||
other's data as it resides in the shared regions, and they will share
|
||
resources such as buffer space and locks. At the same time, any
|
||
applications using the same databases <span class="bold"><strong>must</strong></span> share an environment
|
||
if consistency is to be maintained between them.</p>
|
||
<p>For more information on the operations supported by the database environment handle, see the <a href="../api_reference/C/env.html#envlist" class="olink">Database Environments and Related Methods</a> section in the <em class="citetitle">Berkeley DB C API Reference Guide.</em> </p>
|
||
</div>
|
||
</div>
|
||
<div class="navfooter">
|
||
<hr />
|
||
<table width="100%" summary="Navigation footer">
|
||
<tr>
|
||
<td width="40%" align="left"><a accesskey="p" href="arch_utilities.html">Prev</a> </td>
|
||
<td width="20%" align="center"> </td>
|
||
<td width="40%" align="right"> <a accesskey="n" href="env_create.html">Next</a></td>
|
||
</tr>
|
||
<tr>
|
||
<td width="40%" align="left" valign="top">Supporting utilities </td>
|
||
<td width="20%" align="center">
|
||
<a accesskey="h" href="index.html">Home</a>
|
||
</td>
|
||
<td width="40%" align="right" valign="top"> Creating a database environment</td>
|
||
</tr>
|
||
</table>
|
||
</div>
|
||
</body>
|
||
</html>
|