mirror of
https://github.com/XRPLF/rippled.git
synced 2025-11-25 05:25:55 +00:00
Finish it.
This commit is contained in:
24
LEVELDB.txt
Normal file
24
LEVELDB.txt
Normal file
@@ -0,0 +1,24 @@
|
||||
|
||||
To use LevelDB, follow these steps:
|
||||
|
||||
1) Obtain the latest LevelDB package from http://code.google.com/p/leveldb/
|
||||
1.9.0 is known to work. Build it.
|
||||
|
||||
2) In the SConstruct file, change "LevelDB = bool(0)" to
|
||||
"LevelDB = bool(1)".
|
||||
|
||||
3) In your main directory, create a 'leveldb' directory with 'include' and
|
||||
'lib' subdirectories.
|
||||
|
||||
4) In the 'leveldb/lib' file, place the 'libleveldb.a' file you built.
|
||||
|
||||
5) Make a 'levedb/include/leveldb' directory. Place the leveldb header files
|
||||
(leveldb.h, slice.h, and so on) in this directory.
|
||||
|
||||
6) Compile with 'scons'.
|
||||
|
||||
There is no import or export method, so your server will have to refetch
|
||||
all nodes. For simplicity, we recommend clearing your entire 'db' directory.
|
||||
LevelDB will store the hash nodes in a 'db/hashnode' directory.
|
||||
|
||||
|
||||
@@ -157,7 +157,7 @@ void Application::setup()
|
||||
#ifdef USE_LEVELDB
|
||||
leveldb::Options options;
|
||||
options.create_if_missing = true;
|
||||
leveldb::Status status = leveldb::DB::Open(options, (theConfig.DATA_DIR / "hashnode.ldb").string(), &mHashNodeDB);
|
||||
leveldb::Status status = leveldb::DB::Open(options, (theConfig.DATA_DIR / "hashnode").string(), &mHashNodeDB);
|
||||
if (!status.ok() || !mHashNodeDB)
|
||||
{
|
||||
cLog(lsFATAL) << "Unable to open/create hash node db";
|
||||
|
||||
Reference in New Issue
Block a user