mdb_copy.1 1.5 KB
Newer Older
Howard Chu's avatar
Howard Chu committed
1
.TH MDB_COPY 1 "2014/07/01" "LMDB 0.9.14"
Quanah Gibson-Mount's avatar
Quanah Gibson-Mount committed
2
.\" Copyright 2012-2020 Howard Chu, Symas Corp. All Rights Reserved.
Howard Chu's avatar
Howard Chu committed
3
4
5
6
.\" Copying restrictions apply.  See COPYRIGHT/LICENSE.
.SH NAME
mdb_copy \- LMDB environment copy tool
.SH SYNOPSIS
Howard Chu's avatar
Howard Chu committed
7
.B mdb_copy
Hallvard Furuseth's avatar
Hallvard Furuseth committed
8
[\c
Howard Chu's avatar
Howard Chu committed
9
10
.BR \-V ]
[\c
Howard Chu's avatar
Howard Chu committed
11
12
.BR \-c ]
[\c
Hallvard Furuseth's avatar
Hallvard Furuseth committed
13
14
15
16
.BR \-n ]
.B srcpath
[\c
.BR dstpath ]
Howard Chu's avatar
Howard Chu committed
17
18
19
20
21
.SH DESCRIPTION
The
.B mdb_copy
utility copies an LMDB environment. The environment can
be copied regardless of whether it is currently in use.
22
No lockfile is created, since it gets recreated at need.
Howard Chu's avatar
Howard Chu committed
23
24
25
26
27
28

If
.I dstpath
is specified it must be the path of an empty directory
for storing the backup. Otherwise, the backup will be
written to stdout.
29

Hallvard Furuseth's avatar
Hallvard Furuseth committed
30
.SH OPTIONS
Howard Chu's avatar
Howard Chu committed
31
32
33
34
.TP
.BR \-V
Write the library version number to the standard output, and exit.
.TP
Howard Chu's avatar
Howard Chu committed
35
36
37
38
.BR \-c
Compact while copying. Only current data pages will be copied; freed
or unused pages will be omitted from the copy. This option will
slow down the backup process as it is more CPU-intensive.
39
Currently it fails if the environment has suffered a page leak.
Howard Chu's avatar
Howard Chu committed
40
.TP
Hallvard Furuseth's avatar
Hallvard Furuseth committed
41
42
43
.BR \-n
Open LDMB environment(s) which do not use subdirectories.

Howard Chu's avatar
Howard Chu committed
44
45
46
47
.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.
48
49
50
51
.SH CAVEATS
This utility can trigger significant file size growth if run
in parallel with write transactions, because pages which they
free during copying cannot be reused until the copy is done.
Howard Chu's avatar
Howard Chu committed
52
53
54
55
.SH "SEE ALSO"
.BR mdb_stat (1)
.SH AUTHOR
Howard Chu of Symas Corporation <http://www.symas.com>