2013-07-11

Import existing LevelDB into SSDB

Views: 13604 | 4 Comments

Since 1.5.4, ssdb provides the leveldb-import tool to import a existing LevelDB into ssdb server. This tool is quite easy to use:

Example:
    ./tools/leveldb-import 127.0.0.1 8888 ./leveldb/

Usage:
    ./tools/leveldb-import ip port input_folder

Options:
    ip - ssdb server ip address
    port - ssdb server port number
    input_folder - local leveldb folder
Posted by ideawu at 2013-07-11 11:26:36 Tags:

4 Responses to "Import existing LevelDB into SSDB"

  • Is it possible to import existing leveldb faster than put items one by one? I tried to copy binary files but failed. SSDB could not find any elements in it. Reply
    @Pavel: Hi, you could not just copy leveldb binary files, you have to copy leveldb dabase into ssdb by leveldb-import tool. Reply
    @ideawu: Thank you for the quick reply. But this tool is too slow for me. It imported 750M elements (36GB) for about 6 hours. And I need to do it on daily basis. Do you have any other ways for bulk importing large massive of data? Reply
    @Pavel: This tool shouldn’t be so slow. Is the network condition good? How about the leveldb machine(the one you run leveldb-import on), the CPU, hard-disk? An how about the target machine(the one ssdb running on)? Reply

Leave a Comment