B
B
Baldaris2015-12-22 18:20:10
NoSQL
Baldaris, 2015-12-22 18:20:10

Choice of key-value storage?

Currently mongodb is being used, but it's more of a database than a key-value store.
Help me choose key-value storage according to the following requirements:
- storage on disk (the last added values ​​can be stored in RAM with subsequent periodic flush to disk; SSD disk)
- driver for php (also desirable for java)
- fast writing to storage
- key increment
- ability to make non-blocking backup / restore storage
- no additional server needed
What will be stored:
- logs like "incremental record id" => "serialized value"
The selection is needed only for some elements by "record id", respectively, aggregation, sorting, indexes and other database functionality are not needed.
What mongodb doesn't like:
- too large amount of data occupied (output is 2 times more than MySQL). When in a couple of months, the amount of data exceeds 5-10 GB, it already becomes stressful to make backups.
- when backing up, it occupies the entire RAM, the size of a database and does not release it after backup (only restarting the service helps)

Answer the question

In order to leave comments, you need to log in

2 answer(s)
P
Philipp, 2015-12-22
@Baldaris

Redis, with Persistence enabled redis.io/topics/persistence
In MongoDB, you can use https://docs.mongodb.org/manual/reference/configur... for the old repository.
WiredTiger has a snappy compressor by default. But you can use zlib or bzip
source.wiredtiger.com/2.4.1/compression.html True, the CPU load will increase. Be careful.
Other than that, I can say that you have the wrong approach to backups for MongoDB. Using the full backup mode is not very convenient. Correct use of delayed replication .
I can say that my current database contains about 100 GB of data (on a 253G disk, Mongo 2.6). Everything is perfectly replicated (I have a replica set of 2 machines) and backed up (delayed). This requires a separate server, but it may not be as powerful as the main one, or it may have a different drive, such as a regular HDD.
10 GB is a very small amount of data. Rethink your architecture.

L
lega, 2015-12-22
@lega

What mongodb doesn't like:
1) Install mongo 3.2, it will weigh less than 5 times than in mysql
2) Apparently this is a bug, it should be treated by updating mongi

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question