Verify Redis on Windows memory consumption

587 views
Skip to first unread message

Shay Yannay

unread,
Jan 1, 2015, 10:44:58 AM1/1/15
to redi...@googlegroups.com
Hi ALL,
I'm a bit confuse about the way Redis stores the data in memory on Windows OS.
I've run a test that push lots of keys in to Redis over time and i still see that the private working set (memory in windows for the redis-server.exe is very slowly increasing where as the dump file on disk is very large with size of 2GB.
In addition when I type the INFO command in redis-cli I see that "used_memory_human" is 2,74GB in the memory section but how come that it's not reflected in Window OS memory.

I have series doubts if the memory is used at all or all my data is stored on disk and Redis saved small cache in memory.

You great assistance is more than welcome 

Thanks!!!

Shay Yannay

unread,
Jan 1, 2015, 11:13:52 AM1/1/15
to redi...@googlegroups.com
I noticed that when I turn off persistence the memory increase to the value reported by the INFO command.
So what exactly Redis storing in memory when persistence is enabled ?

Josiah Carlson

unread,
Jan 6, 2015, 4:37:11 PM1/6/15
to redi...@googlegroups.com
No one has yet replied to you likely because the number of people running the Windows fork of Redis is small compared to those who are using Redis on *nix platforms.

If the Windows fork hasn't varied too much from the standard version, there should be no substantial difference in memory consumption between persistence being enabled or disabled, aside from some caching that the OS may do during startup (the snapshot or AOF) or during snapshot and/or AOF writing.

Are you sure that you are observing an actual difference in memory use on the same data? Do you have any keys with expiration times? Does your machine have  enough free memory to ensure that Redis isn't being partly swapped out?

 - Josiah

--
You received this message because you are subscribed to the Google Groups "Redis DB" group.
To unsubscribe from this group and stop receiving emails from it, send an email to redis-db+u...@googlegroups.com.
To post to this group, send email to redi...@googlegroups.com.
Visit this group at http://groups.google.com/group/redis-db.
For more options, visit https://groups.google.com/d/optout.

Alexis Campailla

unread,
Jan 6, 2015, 5:21:41 PM1/6/15
to redi...@googlegroups.com
Hi Shay,

In order to implement persistence and simulate the fork() copy-on-write mechanism, the Windows port of Redis places the Redis heap in a memory mapped file that can be shared with child processes. Data is definitely stored in memory but because of the memory-mapped file working set will be accounted for under "shared working set" instead of "private working set". You can inspect the shared working set of redis-server.exe using task manager or Windows Performance Monitor. You should see values that much closer reflect "used_memory_human".

I hope this helps.

-Alexis (MSOPENTECH)






Josiah Carlson

unread,
Jan 6, 2015, 5:31:09 PM1/6/15
to redi...@googlegroups.com
And I just learned something about the MSOPENTECH Redis fork. Awesome :)

 - Josiah


Reply all
Reply to author
Forward
0 new messages