mdb_dump.1 2.15 KB
Newer Older
Howard Chu's avatar
Howard Chu committed
1
.TH MDB_DUMP 1 "2015/09/30" "LMDB 0.9.17"
Quanah Gibson-Mount's avatar
Quanah Gibson-Mount committed
2
.\" Copyright 2014-2018 Howard Chu, Symas Corp. All Rights Reserved.
Howard Chu's avatar
Howard Chu committed
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
.\" Copying restrictions apply.  See COPYRIGHT/LICENSE.
.SH NAME
mdb_dump \- LMDB environment export tool
.SH SYNOPSIS
.B mdb_dump
[\c
.BR \-V ]
[\c
.BI \-f \ file\fR]
[\c
.BR \-l ]
[\c
.BR \-n ]
[\c
.BR \-p ]
[\c
.BR \-a \ |
.BI \-s \ subdb\fR]
Howard Chu's avatar
Howard Chu committed
21
.BR \ envpath
Howard Chu's avatar
Howard Chu committed
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
.SH DESCRIPTION
The
.B mdb_dump
utility reads a database and writes its contents to the
standard output using a portable flat-text format
understood by the
.BR mdb_load (1)
utility.
.SH OPTIONS
.TP
.BR \-V
Write the library version number to the standard output, and exit.
.TP
.BR \-f \ file
Write to the specified file instead of to the standard output.
.TP
.BR \-l
List the databases stored in the environment. Just the
names will be listed, no data will be output.
.TP
.BR \-n
Dump an LMDB database which does not use subdirectories.
.TP
.BR \-p
Howard Chu's avatar
Howard Chu committed
46
47
48
If characters in either the key or data items are printing characters (as
defined by isprint(3)), output them directly. This option permits users to
use standard text editors and tools to modify the contents of databases.
Howard Chu's avatar
Howard Chu committed
49

Howard Chu's avatar
Howard Chu committed
50
51
52
Note: different systems may have different notions about what characters
are considered printing characters, and databases dumped in this manner may
be less portable to external systems. 
Howard Chu's avatar
Howard Chu committed
53
54
55
56
57
58
59
60
61
62
63
.TP
.BR \-a
Dump all of the subdatabases in the environment.
.TP
.BR \-s \ subdb
Dump a specific subdatabase. If no database is specified, only the main database is dumped.
.SH DIAGNOSTICS
Exit status is zero if no errors occur.
Errors result in a non-zero exit status and
a diagnostic message being written to standard error.

Howard Chu's avatar
Howard Chu committed
64
65
66
67
Dumping and reloading databases that use user-defined comparison functions
will result in new databases that use the default comparison functions.
\fBIn this case it is quite likely that the reloaded database will be
damaged beyond repair permitting neither record storage nor retrieval.\fP
Howard Chu's avatar
Howard Chu committed
68
69
70
71
72
73
74
75

The only available workaround is to modify the source for the
.BR mdb_load (1)
utility to load the database using the correct comparison functions.
.SH "SEE ALSO"
.BR mdb_load (1)
.SH AUTHOR
Howard Chu of Symas Corporation <http://www.symas.com>