path: root/lpsm_recover.3.in
diff options
Diffstat (limited to 'lpsm_recover.3.in')
1 files changed, 49 insertions, 0 deletions
diff --git a/lpsm_recover.3.in b/lpsm_recover.3.in
new file mode 100644
index 0000000..8e6a9af
--- /dev/null
+++ b/lpsm_recover.3.in
@@ -0,0 +1,49 @@
+.\" -*- nroff -*- ---------------------------------------------------------
+.\" Copyright 2001 H. Peter Anvin - All Rights Reserved
+.\" This program is free software; you can redistribute it and/or modify
+.\" it under the terms of the GNU Lesser General Public License as
+.\" published by the Free Software Foundation, Inc.,
+.\" 59 Temple Place Ste 330, Bostom MA 02111-1307, USA; version 2.1,
+.\" incorporated herein by reference.
+.\" -----------------------------------------------------------------------
+.\" $Id$
+.TH LPSM_RECOVER 3 "25 October 2001" "LPSM @@VERSION@@" "Linux Persistent Memory"
+lpsm_recovery \- Perform offline recovery of an LPSM database
+.B #include <lpsm.h>
+.BI "int lpsm_recover(const char *" datafile ", const char *" logfile ");"
+.B lpsm_recover()
+performs an offline log recovery of the specified pair of LPSM files.
+After log recovery is complete, the contents of
+.I datafile
+is identical to the contents of the LPSM arena, and
+.I logfile
+is truncated to its minimum size.
+It is safe to call
+.B lpsm_recovery()
+while a different arena is mapped.
+.B lpsm_recovery()
+returns 0 on success and -1 on failure; in the latter case
+.I errno
+is set to indicate the nature of the error.
+It is not required to perform a log recovery before calling
+.B lpsm_init()
+.BR lpsm_arena_init() .
+These routines perform log recovery as part of their standard startup
+.BR lpsm_init (3),
+.BR lpsm_arena_init (3).