[Date Prev][Date Next] [Chronological] [Thread] [Top]

Antw: Re: LMDB database size



>>> Howard Chu <hyc@symas.com> schrieb am 25.01.2014 um 19:07 in Nachricht
<52E3FD6E.9070906@symas.com>:
> Markus Doppelbauer wrote:
>> Hello,
>> We are using BerkeleyDB since a decade - but we are searching for something
>> more lightweight. LMDB is what we are looking for ...  ^^
>> The small code  and the benchmark-results are very impressive!
>> A question: We have a server with 4 GB RAM. One of the BerkeleyDB-files has
>> about 20 GB.This particular database is a kind of archive - hardly read and 
> hardly
>> written (maybe once per minute).
>> Is it possible to "mmap()" a 20 GB database into the RAM?
> 
> Yes.
> 
>> If yes, will the server
>> start "swapping"?
> 
> No.

This is only true (AFAIK) if the applications uses huge pages or memory locking. In other cases it depends on the OS and the other applications.
In general mmap files "swap" onto themselves, and you would not call it "swapping" in the usual sense...

Ulrich

> 
>> Thanks a lot
>> Markus
> 
> 
> -- 
>    -- Howard Chu
>    CTO, Symas Corp.           http://www.symas.com 
>    Director, Highland Sun     http://highlandsun.com/hyc/ 
>    Chief Architect, OpenLDAP  http://www.openldap.org/project/