Redis's huge files won't delete?

Royi Namir picture Royi Namir · May 14, 2014 · Viewed 12.9k times · Source

I'm using Redis-server for windows ( 2.8.4 - MSOpenTech) / windows 8 64bit.

It is working great , but even after I run :

enter image description here

I see this : (and here are my questions)

enter image description here

Question :

— Didn't I just tell it to erase all DB ? so why are those 2/3 huge files are still there ? How can I completely erase those files? ( without re-generating)

NB It seems that it is doing deletion of keys without freeing occupied space. if so , How can I free this unused space?

Answer

Deepak picture Deepak · May 14, 2014

From https://github.com/MSOpenTech/redis/issues/83 "Redis uses the fork() UNIX system API to create a point-in-time snapshot of the data store for storage to disk. This impacts several features on Redis: AOF/RDB backup, master-slave synchronization, and clustering. Windows does not have a fork-like API available, so we have had to simulate this behavior by placing the Redis heap in a memory mapped file that can be shared with a child(quasi-forked) process. By default we set the size of this file to be equal to the size of physical memory. In order to control the size of this file we have added a maxheap flag. See the Redis.Windows.conf file in msvs\setups\documentation (also included with the NuGet and Chocolatey distributions) for details on the usage of this flag. "