Commit d69ef83f authored by David Disseldorp's avatar David Disseldorp

ntdb: next-generation trivial key-value database

ntdb is a partial rewrite of Samba's Trivial Database, providing > 4GB
database scalability and an improved API.
Obtained from the Samba repository at git://git.samba.org/samba.git, as
of bd13405e8570e9a5942165a8c52a2bc3fdc9d96e.

See Samba's Git changelog for authorship details.
Signed-off-by: default avatarDavid Disseldorp <ddiss@suse.de>
parent ed95d860
ntdb_add_flag: void (struct ntdb_context *, unsigned int)
ntdb_append: enum NTDB_ERROR (struct ntdb_context *, NTDB_DATA, NTDB_DATA)
ntdb_chainlock: enum NTDB_ERROR (struct ntdb_context *, NTDB_DATA)
ntdb_chainlock_read: enum NTDB_ERROR (struct ntdb_context *, NTDB_DATA)
ntdb_chainunlock: void (struct ntdb_context *, NTDB_DATA)
ntdb_chainunlock_read: void (struct ntdb_context *, NTDB_DATA)
ntdb_check_: enum NTDB_ERROR (struct ntdb_context *, enum NTDB_ERROR (*)(NTDB_DATA, NTDB_DATA, void *), void *)
ntdb_close: int (struct ntdb_context *)
ntdb_delete: enum NTDB_ERROR (struct ntdb_context *, NTDB_DATA)
ntdb_errorstr: const char *(enum NTDB_ERROR)
ntdb_exists: bool (struct ntdb_context *, NTDB_DATA)
ntdb_fd: int (const struct ntdb_context *)
ntdb_fetch: enum NTDB_ERROR (struct ntdb_context *, NTDB_DATA, NTDB_DATA *)
ntdb_firstkey: enum NTDB_ERROR (struct ntdb_context *, NTDB_DATA *)
ntdb_foreach_: void (int (*)(struct ntdb_context *, void *), void *)
ntdb_get_attribute: enum NTDB_ERROR (struct ntdb_context *, union ntdb_attribute *)
ntdb_get_flags: unsigned int (struct ntdb_context *)
ntdb_get_seqnum: int64_t (struct ntdb_context *)
ntdb_lockall: enum NTDB_ERROR (struct ntdb_context *)
ntdb_lockall_read: enum NTDB_ERROR (struct ntdb_context *)
ntdb_name: const char *(const struct ntdb_context *)
ntdb_nextkey: enum NTDB_ERROR (struct ntdb_context *, NTDB_DATA *)
ntdb_open: struct ntdb_context *(const char *, int, int, mode_t, union ntdb_attribute *)
ntdb_parse_record_: enum NTDB_ERROR (struct ntdb_context *, NTDB_DATA, enum NTDB_ERROR (*)(NTDB_DATA, NTDB_DATA, void *), void *)
ntdb_remove_flag: void (struct ntdb_context *, unsigned int)
ntdb_repack: enum NTDB_ERROR (struct ntdb_context *)
ntdb_set_attribute: enum NTDB_ERROR (struct ntdb_context *, const union ntdb_attribute *)
ntdb_store: enum NTDB_ERROR (struct ntdb_context *, NTDB_DATA, NTDB_DATA, int)
ntdb_summary: enum NTDB_ERROR (struct ntdb_context *, enum ntdb_summary_flags, char **)
ntdb_transaction_cancel: void (struct ntdb_context *)
ntdb_transaction_commit: enum NTDB_ERROR (struct ntdb_context *)
ntdb_transaction_prepare_commit: enum NTDB_ERROR (struct ntdb_context *)
ntdb_transaction_start: enum NTDB_ERROR (struct ntdb_context *)
ntdb_traverse_: int64_t (struct ntdb_context *, int (*)(struct ntdb_context *, NTDB_DATA, NTDB_DATA, void *), void *)
ntdb_unlockall: void (struct ntdb_context *)
ntdb_unlockall_read: void (struct ntdb_context *)
ntdb_unset_attribute: void (struct ntdb_context *, enum ntdb_attribute_type)
ntdb_wipe_all: enum NTDB_ERROR (struct ntdb_context *)
ntdb_add_flag: void (struct ntdb_context *, unsigned int)
ntdb_append: enum NTDB_ERROR (struct ntdb_context *, NTDB_DATA, NTDB_DATA)
ntdb_chainlock: enum NTDB_ERROR (struct ntdb_context *, NTDB_DATA)
ntdb_chainlock_read: enum NTDB_ERROR (struct ntdb_context *, NTDB_DATA)
ntdb_chainunlock: void (struct ntdb_context *, NTDB_DATA)
ntdb_chainunlock_read: void (struct ntdb_context *, NTDB_DATA)
ntdb_check_: enum NTDB_ERROR (struct ntdb_context *, enum NTDB_ERROR (*)(NTDB_DATA, NTDB_DATA, void *), void *)
ntdb_close: int (struct ntdb_context *)
ntdb_delete: enum NTDB_ERROR (struct ntdb_context *, NTDB_DATA)
ntdb_errorstr: const char *(enum NTDB_ERROR)
ntdb_exists: bool (struct ntdb_context *, NTDB_DATA)
ntdb_fd: int (const struct ntdb_context *)
ntdb_fetch: enum NTDB_ERROR (struct ntdb_context *, NTDB_DATA, NTDB_DATA *)
ntdb_firstkey: enum NTDB_ERROR (struct ntdb_context *, NTDB_DATA *)
ntdb_foreach_: void (int (*)(struct ntdb_context *, void *), void *)
ntdb_get_attribute: enum NTDB_ERROR (struct ntdb_context *, union ntdb_attribute *)
ntdb_get_flags: unsigned int (struct ntdb_context *)
ntdb_get_seqnum: int64_t (struct ntdb_context *)
ntdb_lockall: enum NTDB_ERROR (struct ntdb_context *)
ntdb_lockall_read: enum NTDB_ERROR (struct ntdb_context *)
ntdb_name: const char *(const struct ntdb_context *)
ntdb_nextkey: enum NTDB_ERROR (struct ntdb_context *, NTDB_DATA *)
ntdb_open: struct ntdb_context *(const char *, int, int, mode_t, union ntdb_attribute *)
ntdb_parse_record_: enum NTDB_ERROR (struct ntdb_context *, NTDB_DATA, enum NTDB_ERROR (*)(NTDB_DATA, NTDB_DATA, void *), void *)
ntdb_remove_flag: void (struct ntdb_context *, unsigned int)
ntdb_repack: enum NTDB_ERROR (struct ntdb_context *)
ntdb_set_attribute: enum NTDB_ERROR (struct ntdb_context *, const union ntdb_attribute *)
ntdb_store: enum NTDB_ERROR (struct ntdb_context *, NTDB_DATA, NTDB_DATA, int)
ntdb_summary: enum NTDB_ERROR (struct ntdb_context *, enum ntdb_summary_flags, char **)
ntdb_transaction_cancel: void (struct ntdb_context *)
ntdb_transaction_commit: enum NTDB_ERROR (struct ntdb_context *)
ntdb_transaction_prepare_commit: enum NTDB_ERROR (struct ntdb_context *)
ntdb_transaction_start: enum NTDB_ERROR (struct ntdb_context *)
ntdb_traverse_: int64_t (struct ntdb_context *, int (*)(struct ntdb_context *, NTDB_DATA, NTDB_DATA, void *), void *)
ntdb_unlockall: void (struct ntdb_context *)
ntdb_unlockall_read: void (struct ntdb_context *)
ntdb_unset_attribute: void (struct ntdb_context *, enum ntdb_attribute_type)
ntdb_wipe_all: enum NTDB_ERROR (struct ntdb_context *)
GNU LESSER GENERAL PUBLIC LICENSE
Version 3, 29 June 2007
Copyright (C) 2007 Free Software Foundation, Inc. <http://fsf.org/>
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
This version of the GNU Lesser General Public License incorporates
the terms and conditions of version 3 of the GNU General Public
License, supplemented by the additional permissions listed below.
0. Additional Definitions.
As used herein, "this License" refers to version 3 of the GNU Lesser
General Public License, and the "GNU GPL" refers to version 3 of the GNU
General Public License.
"The Library" refers to a covered work governed by this License,
other than an Application or a Combined Work as defined below.
An "Application" is any work that makes use of an interface provided
by the Library, but which is not otherwise based on the Library.
Defining a subclass of a class defined by the Library is deemed a mode
of using an interface provided by the Library.
A "Combined Work" is a work produced by combining or linking an
Application with the Library. The particular version of the Library
with which the Combined Work was made is also called the "Linked
Version".
The "Minimal Corresponding Source" for a Combined Work means the
Corresponding Source for the Combined Work, excluding any source code
for portions of the Combined Work that, considered in isolation, are
based on the Application, and not on the Linked Version.
The "Corresponding Application Code" for a Combined Work means the
object code and/or source code for the Application, including any data
and utility programs needed for reproducing the Combined Work from the
Application, but excluding the System Libraries of the Combined Work.
1. Exception to Section 3 of the GNU GPL.
You may convey a covered work under sections 3 and 4 of this License
without being bound by section 3 of the GNU GPL.
2. Conveying Modified Versions.
If you modify a copy of the Library, and, in your modifications, a
facility refers to a function or data to be supplied by an Application
that uses the facility (other than as an argument passed when the
facility is invoked), then you may convey a copy of the modified
version:
a) under this License, provided that you make a good faith effort to
ensure that, in the event an Application does not supply the
function or data, the facility still operates, and performs
whatever part of its purpose remains meaningful, or
b) under the GNU GPL, with none of the additional permissions of
this License applicable to that copy.
3. Object Code Incorporating Material from Library Header Files.
The object code form of an Application may incorporate material from
a header file that is part of the Library. You may convey such object
code under terms of your choice, provided that, if the incorporated
material is not limited to numerical parameters, data structure
layouts and accessors, or small macros, inline functions and templates
(ten or fewer lines in length), you do both of the following:
a) Give prominent notice with each copy of the object code that the
Library is used in it and that the Library and its use are
covered by this License.
b) Accompany the object code with a copy of the GNU GPL and this license
document.
4. Combined Works.
You may convey a Combined Work under terms of your choice that,
taken together, effectively do not restrict modification of the
portions of the Library contained in the Combined Work and reverse
engineering for debugging such modifications, if you also do each of
the following:
a) Give prominent notice with each copy of the Combined Work that
the Library is used in it and that the Library and its use are
covered by this License.
b) Accompany the Combined Work with a copy of the GNU GPL and this license
document.
c) For a Combined Work that displays copyright notices during
execution, include the copyright notice for the Library among
these notices, as well as a reference directing the user to the
copies of the GNU GPL and this license document.
d) Do one of the following:
0) Convey the Minimal Corresponding Source under the terms of this
License, and the Corresponding Application Code in a form
suitable for, and under terms that permit, the user to
recombine or relink the Application with a modified version of
the Linked Version to produce a modified Combined Work, in the
manner specified by section 6 of the GNU GPL for conveying
Corresponding Source.
1) Use a suitable shared library mechanism for linking with the
Library. A suitable mechanism is one that (a) uses at run time
a copy of the Library already present on the user's computer
system, and (b) will operate properly with a modified version
of the Library that is interface-compatible with the Linked
Version.
e) Provide Installation Information, but only if you would otherwise
be required to provide such information under section 6 of the
GNU GPL, and only to the extent that such information is
necessary to install and execute a modified version of the
Combined Work produced by recombining or relinking the
Application with a modified version of the Linked Version. (If
you use option 4d0, the Installation Information must accompany
the Minimal Corresponding Source and Corresponding Application
Code. If you use option 4d1, you must provide the Installation
Information in the manner specified by section 6 of the GNU GPL
for conveying Corresponding Source.)
5. Combined Libraries.
You may place library facilities that are a work based on the
Library side by side in a single library together with other library
facilities that are not Applications and are not covered by this
License, and convey such a combined library under terms of your
choice, if you do both of the following:
a) Accompany the combined library with a copy of the same work based
on the Library, uncombined with any other library facilities,
conveyed under the terms of this License.
b) Give prominent notice with the combined library that part of it
is a work based on the Library, and explaining where to find the
accompanying uncombined form of the same work.
6. Revised Versions of the GNU Lesser General Public License.
The Free Software Foundation may publish revised and/or new versions
of the GNU Lesser General Public License from time to time. Such new
versions will be similar in spirit to the present version, but may
differ in detail to address new problems or concerns.
Each version is given a distinguishing version number. If the
Library as you received it specifies that a certain numbered version
of the GNU Lesser General Public License "or any later version"
applies to it, you have the option of following the terms and
conditions either of that published version or of any later version
published by the Free Software Foundation. If the Library as you
received it does not specify a version number of the GNU Lesser
General Public License, you may choose any version of the GNU Lesser
General Public License ever published by the Free Software Foundation.
If the Library as you received it specifies that a proxy can decide
whether future versions of the GNU Lesser General Public License shall
apply, that proxy's public statement of acceptance of any version is
permanent authorization for you to choose that version for the
Library.
# simple makefile wrapper to run waf
WAF=WAF_MAKE=1 PATH=buildtools/bin:../../buildtools/bin:$$PATH waf
all:
$(WAF) build
install:
$(WAF) install
uninstall:
$(WAF) uninstall
test: FORCE
$(WAF) test $(TEST_OPTIONS)
testenv:
$(WAF) test --testenv $(TEST_OPTIONS)
quicktest:
$(WAF) test --quick $(TEST_OPTIONS)
dist:
touch .tmplock
WAFLOCK=.tmplock $(WAF) dist
distcheck:
touch .tmplock
WAFLOCK=.tmplock $(WAF) distcheck
clean:
$(WAF) clean
distclean:
$(WAF) distclean
reconfigure: configure
$(WAF) reconfigure
show_waf_options:
$(WAF) --help
# some compatibility make targets
everything: all
testsuite: all
.PHONY: check
check: test
torture: all
# this should do an install as well, once install is finished
installcheck: test
etags:
$(WAF) etags
ctags:
$(WAF) ctags
pydoctor:
$(WAF) pydoctor
bin/%:: FORCE
$(WAF) --targets=`basename $@`
FORCE:
This diff is collapsed.
#!/bin/sh
PREVPATH=`dirname $0`
if [ -f $PREVPATH/../../buildtools/bin/waf ]; then
WAF=../../buildtools/bin/waf
elif [ -f $PREVPATH/buildtools/bin/waf ]; then
WAF=./buildtools/bin/waf
else
echo "replace: Unable to find waf"
exit 1
fi
# using JOBS=1 gives maximum compatibility with
# systems like AIX which have broken threading in python
JOBS=1
export JOBS
cd . || exit 1
$WAF configure "$@" || exit 1
cd $PREVPATH
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN" "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd">
<refentry id="ntdbdump.8">
<refmeta>
<refentrytitle>ntdbdump</refentrytitle>
<manvolnum>8</manvolnum>
<refmiscinfo class="source">Samba</refmiscinfo>
<refmiscinfo class="manual">System Administration tools</refmiscinfo>
<refmiscinfo class="version">4.1</refmiscinfo>
</refmeta>
<refnamediv>
<refname>ntdbdump</refname>
<refpurpose>tool for printing the contents of an NTDB file</refpurpose>
</refnamediv>
<refsynopsisdiv>
<cmdsynopsis>
<command>ntdbdump</command>
<arg choice="opt">-k <replaceable>keyname</replaceable></arg>
<arg choice="opt">-e</arg>
<arg choice="opt">-h</arg>
<arg choice="req">filename</arg>
</cmdsynopsis>
</refsynopsisdiv>
<refsect1>
<title>DESCRIPTION</title>
<para>This tool is part of the <citerefentry><refentrytitle>samba</refentrytitle>
<manvolnum>1</manvolnum></citerefentry> suite.</para>
<para><command>ntdbdump</command> is a very simple utility that 'dumps' the
contents of a NTDB (New Trivial DataBase) file to standard output in a
human-readable format.
</para>
<para>This tool can be used when debugging problems with NTDB files. It is
intended for those who are somewhat familiar with Samba internals.
</para>
</refsect1>
<refsect1>
<title>OPTIONS</title>
<variablelist>
<varlistentry>
<term>-h</term>
<listitem><para>
Get help information.
</para></listitem>
</varlistentry>
<varlistentry>
<term>-k <replaceable>keyname</replaceable></term>
<listitem><para>
The <command>-k</command> option restricts dumping to a single key, if found.
</para> </listitem>
</varlistentry>
</variablelist>
</refsect1>
<refsect1>
<title>SEE ALSO</title>
<para>
tdbdump(8), ntdbtool(8)
</para>
</refsect1>
<refsect1>
<title>VERSION</title>
<para>This man page is correct for version 4 of the Samba suite.</para>
</refsect1>
<refsect1>
<title>AUTHOR</title>
<para>
The original Samba software and related utilities were created by Andrew Tridgell.
Samba is now developed by the Samba Team as an Open Source project similar to the way
the Linux kernel is developed.
</para>
<para>The ntdbdump man page was written by Rusty Russell, base on the tdbdump man page by Jelmer Vernooij.</para>
</refsect1>
</refentry>
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
prefix=@prefix@
exec_prefix=@exec_prefix@
libdir=@libdir@
includedir=@includedir@
Name: ntdb
Description: A (not-so) trivial database
Version: @PACKAGE_VERSION@
Libs: @LIB_RPATH@ -L${libdir} -lntdb
Cflags: -I${includedir}
URL: http://tdb.samba.org/
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
#ifndef NTDB_NO_FSYNC_H
#define NTDB_NO_FSYNC_H
/* Obey $TDB_NO_FSYNC, a bit like tdb does (only note our NTDB_NOSYNC
* does less) */
#define MAYBE_NOSYNC (getenv("TDB_NO_FSYNC") ? NTDB_NOSYNC : 0)
#endif
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment