File: intro.html

package info (click to toggle)
db 2%3A2.4.14-2.7.7.1.c
  • links: PTS
  • area: main
  • in suites: potato
  • size: 12,716 kB
  • ctags: 9,382
  • sloc: ansic: 35,556; tcl: 8,564; cpp: 4,890; sh: 2,075; makefile: 1,723; java: 1,632; sed: 419; awk: 153; asm: 41
file content (66 lines) | stat: -rw-r--r-- 3,388 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
<! "@(#)intro.so	10.1 (Sleepycat) 12/18/98">
<!Copyright 1997, 1998 by Sleepycat Software, Inc.  All rights reserved.>
<html>
<body bgcolor=white>
<head>
<title>Berkeley DB Reference Guide: Logging Subsystem</title>
<meta name="description" content="Berkeley DB: An embedded database programmatic toolkit.">
<meta name="keywords" content="embedded,database,programmatic,toolkit,b+tree,btr
ee,hash,hashing,transaction,transactions,locking,logging,access method,access me
thods,java,C,C++">
</head>
<h3>Berkeley DB Reference Guide: Logging Subsystem</h3>
<p>
<h1 align=center>Berkeley DB and logging</h1>
<p>
The logging subsystem is the somewhat general-purpose logging facility
used by Berkeley DB.  This module is potentially useful outside of the Berkeley DB
package for processes that require write-ahead logging support, but is
less likely to be generally useful than the memory pool or locking
subsystems.
<p>
A log can be shared by any number of processes and threads within
processes.  The <a href="../../api_c/DbLog/open.html">log_open</a> interface opens, and optionally creates,
a log.  When the log is no longer in use, it should be closed, using the
<a href="../../api_c/DbLog/close.html">log_close</a> interface.  Specific log entries are identified by log
sequence numbers.  Log sequence numbers are held in an opaque object, a
DB_LSN.
<p>
The <a href="../../api_c/DbLog/put.html">log_put</a> interface is used to append new log records to the
log.  Optionally, the <a href="../../api_c/DbLog/put.html#DB_CHECKPOINT">DB_CHECKPOINT</a> flag can be used to cause
any log record to include checkpoint information, such that the log is
consistent to that point and recoverable after a system or application
failure.  The <a href="../../api_c/DbLog/get.html">log_get</a> interface is used to retrieve log records
from the log.
<p>
There are additional interfaces for integrating the log subsystem with
a transaction processing system:
<p>
The <a href="../../api_c/DbLog/db_register.html">log_register</a> and <a href="../../api_c/DbLog/db_unregister.html">log_unregister</a> interfaces associate
files with identification numbers.  These identification numbers are
logged so that log recovery correctly associates database changes with
the appropriate files.
<p>
The <a href="../../api_c/DbLog/flush.html">log_flush</a> interface flushes the log up to a particular log
sequence number.
<p>
The <a href="../../api_c/DbLog/compare.html">log_compare</a> interface allows applications to compare any
two log sequence numbers.
<p>
The <a href="../../api_c/DbLog/file.html">log_file</a> interface maps a log sequence number to the specific
log file which contains it.
The <a href="../../api_c/DbLog/archive.html">log_archive</a> interface returns various sets of log file names.
These interfaces are used for database administration, e.g., to determine
if log files may be removed from the system.
<p>
The <a href="../../utility/db_stat.html">db_stat</a> utility uses the <a href="../../api_c/DbLog/stat.html">log_stat</a> interface to display
statistics about the log.
<p>
Finally, the log (but not the log files themselves) may be discarded using
the <a href="../../api_c/DbLog/unlink.html">log_unlink</a> interface.
<p>
<a href="../../ref/toc.html"><img src="../../images/toc.gif"></a>
<a href="../../ref/log/limits.html"><img src="../../images/next.gif"></a>
</tt>
</body>
</html>