mirror of
https://github.com/berkeleydb/libdb.git
synced 2024-11-16 09:06:25 +00:00
92 lines
4.2 KiB
HTML
92 lines
4.2 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>Log file limits</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="log.html" title="Chapter 17. The Logging Subsystem" />
|
||
<link rel="prev" href="log_config.html" title="Configuring logging" />
|
||
<link rel="next" href="mp.html" title="Chapter 18. The Memory Pool Subsystem" />
|
||
</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">Log file limits</th>
|
||
</tr>
|
||
<tr>
|
||
<td width="20%" align="left"><a accesskey="p" href="log_config.html">Prev</a> </td>
|
||
<th width="60%" align="center">Chapter 17.
|
||
The Logging Subsystem
|
||
</th>
|
||
<td width="20%" align="right"> <a accesskey="n" href="mp.html">Next</a></td>
|
||
</tr>
|
||
</table>
|
||
<hr />
|
||
</div>
|
||
<div class="sect1" lang="en" xml:lang="en">
|
||
<div class="titlepage">
|
||
<div>
|
||
<div>
|
||
<h2 class="title" style="clear: both"><a id="log_limits"></a>Log file limits</h2>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
<p>Log filenames and sizes impose a limit on how long databases may be
|
||
used in a Berkeley DB database environment. It is quite unlikely that an
|
||
application will reach this limit; however, if the limit is reached,
|
||
the Berkeley DB environment's databases must be dumped and reloaded.</p>
|
||
<p>The log filename consists of <span class="bold"><strong>log.</strong></span> followed by 10 digits, with
|
||
a maximum of 2,000,000,000 log files. Consider an application performing
|
||
6000 transactions per second for 24 hours a day, logged into 10MB log
|
||
files, in which each transaction is logging approximately 500 bytes of data.
|
||
The following calculation:</p>
|
||
<pre class="programlisting">(10 * 2^20 * 2000000000) / (6000 * 500 * 365 * 60 * 60 * 24) = ~221</pre>
|
||
<p>indicates that the system will run out of log filenames in roughly 221
|
||
years.</p>
|
||
<p>There is no way to reset the log filename space in Berkeley DB. If your
|
||
application is reaching the end of its log filename space, you must do
|
||
the following:</p>
|
||
<div class="orderedlist">
|
||
<ol type="1">
|
||
<li>Archive your databases as if to prepare for catastrophic failure (see
|
||
<a class="xref" href="transapp_archival.html" title="Database and log file archival">Database and log file archival</a>
|
||
for more information).</li>
|
||
<li>Reset the database's log sequence numbers (see the <span class="bold"><strong>-r</strong></span> option
|
||
to the <a href="../api_reference/C/db_load.html" class="olink">db_load</a> utility for more information).</li>
|
||
<li>Remove all of the log files from the database environment. (This is the
|
||
only situation in which all the log files are removed from an environment;
|
||
in all other cases, at least a single log file is retained.)</li>
|
||
<li>Restart your application.</li>
|
||
</ol>
|
||
</div>
|
||
</div>
|
||
<div class="navfooter">
|
||
<hr />
|
||
<table width="100%" summary="Navigation footer">
|
||
<tr>
|
||
<td width="40%" align="left"><a accesskey="p" href="log_config.html">Prev</a> </td>
|
||
<td width="20%" align="center">
|
||
<a accesskey="u" href="log.html">Up</a>
|
||
</td>
|
||
<td width="40%" align="right"> <a accesskey="n" href="mp.html">Next</a></td>
|
||
</tr>
|
||
<tr>
|
||
<td width="40%" align="left" valign="top">Configuring logging </td>
|
||
<td width="20%" align="center">
|
||
<a accesskey="h" href="index.html">Home</a>
|
||
</td>
|
||
<td width="40%" align="right" valign="top"> Chapter 18.
|
||
The Memory Pool Subsystem
|
||
</td>
|
||
</tr>
|
||
</table>
|
||
</div>
|
||
</body>
|
||
</html>
|