OOM despite free memory

35 views
Skip to first unread message

Shishir Joshi

unread,
Jan 23, 2018, 9:06:46 AM1/23/18
to Redis DB
Hi folks,

I'm running a redis 3.2.0 in production that seems to be returning OOM errors despite there being a lot of free memory. I'm not sure why this seems to be happening and would really appreciate any help in debugging this. More context, I'm using the redis server as a queue for sidekiq(https://github.com/mperham/sidekiq) which is a background processing library in Ruby. I'm using sidekiq enterprise version 5.0.0. While trying to enqueue new jobs in redis, sidekiq returns the error "OOM command not allowed when used memory > 'maxmemory".

Pasting the memory stats from the redis server returned by running "info all"

# Memory
used_memory
:761522232
used_memory_human
:726.24M
used_memory_rss
:943042560
used_memory_rss_human
:899.36M
used_memory_peak
:824748272
used_memory_peak_human
:786.54M
total_system_memory
:13656690688
total_system_memory_human
:12.72G
used_memory_lua
:70656
used_memory_lua_human
:69.00K
maxmemory
:11607736320
maxmemory_human
:10.81G
maxmemory_policy
:noeviction
mem_fragmentation_ratio
:1.24
mem_allocator
:jemalloc-4.0.3



I ran free -m on the server at around the same time and there's plenty of free memory on that server.
             total       used       free     shared    buffers     cached

Mem:         13024       1129      11894          0         12         71
-/+ buffers/cache:       1045      11978
Swap:            0          0          0


I've checked the redis client and sidekiq libary code and it seems to be bug free. Not sure what more I should be doing to debug this problem. Has anyone faced this issue before?

hva...@gmail.com

unread,
Jan 26, 2018, 2:07:44 AM1/26/18
to Redis DB
Posting the whole output of INFO ALL would be more helpful than just the memory stats.  For one thing, does this Redis process spawn child processes to save snapshots to disk?  The other sections will confirm/deny that possible source of memory consumption.
Reply all
Reply to author
Forward
0 new messages