Instant crash with Our of Memory on startup (Windows)

266 views
Skip to first unread message

Michael Hallock

unread,
Dec 1, 2015, 4:03:01 PM12/1/15
to Redis DB
Greetings all,

I have a weird issue that suddenly popped up. I have a server with 8 Gbs of RAM, and a Redis instance that has 

maxmemory 2147483648

However, when trying to start redis-server, I get an out of memory error. I have PLENTY of memory available, and there's no reason it shouldn't be able to allocate 2 gbs of ram here, (I even tried setting heap size to 2x this, which should still be fine).

I get the following:

C:\ProgramData\chocolatey\lib\redis-64>redis-server.exe redis.windows.conf
                _._
           _.-``__ ''-._
      _.-``    `.  `_.  ''-._           Redis 2.8.19 (00000000/0) 64 bit
  .-`` .-```.  ```\/    _.,_ ''-._
 (    '      ,       .-`  | `,    )     Running in stand alone mode
 |`-._`-...-` __...-.``-._|'` _.-'|     Port: 6379
 |    `-._   `._    /     _.-'    |     PID: 1008
  `-._    `-._  `-./  _.-'    _.-'
 |`-._`-._    `-.__.-'    _.-'_.-'|
 |    `-._`-._        _.-'_.-'    |           http://redis.io
  `-._    `-._`-.__.-'_.-'    _.-'
 |`-._`-._    `-.__.-'    _.-'_.-'|
 |    `-._`-._        _.-'_.-'    |
  `-._    `-._`-.__.-'_.-'    _.-'
      `-._    `-.__.-'    _.-'
          `-._        _.-'
              `-.__.-'

[1008] 01 Dec 15:00:55.272 # Server started, Redis version 2.8.19
VirtualAlloc/COWAlloc fail!
VirtualAlloc/COWAlloc fail!
[1008] 01 Dec 15:00:55.833 # Out Of Memory allocating 1918986348 bytes!
[1008] 01 Dec 15:00:55.833 #

=== REDIS BUG REPORT START: Cut & paste starting from here ===
[1008] 01 Dec 15:00:55.833 # ------------------------------------------------
[1008] 01 Dec 15:00:55.849 # !!! Software Failure. Press left mouse button to co
ntinue
[1008] 01 Dec 15:00:55.849 # Guru Meditation: "Redis aborting for OUT OF MEMORY"
 #..\src\redis.c:3467
[1008] 01 Dec 15:00:55.849 # ------------------------------------------------


Michael Hallock

unread,
Dec 1, 2015, 4:13:04 PM12/1/15
to Redis DB
I tried upgrading to the latest version too (2.8.2104 for me)

 

Your memory passed this test.
Please if you are still in doubt use the following two tools:

C:\ProgramData\chocolatey\lib\redis-64>
C:\ProgramData\chocolatey\lib\redis-64>redis-server "redis.windows - Copy.conf"
                _._
           _.-``__ ''-._
      _.-``    `.  `_.  ''-._           Redis 2.8.2104 (00000000/0) 64 bit
  .-`` .-```.  ```\/    _.,_ ''-._
 (    '      ,       .-`  | `,    )     Running in stand alone mode
 |`-._`-...-` __...-.``-._|'` _.-'|     Port: 6379
 |    `-._   `._    /     _.-'    |     PID: 2600
  `-._    `-._  `-./  _.-'    _.-'
 |`-._`-._    `-.__.-'    _.-'_.-'|
 |    `-._`-._        _.-'_.-'    |           http://redis.io
  `-._    `-._`-.__.-'_.-'    _.-'
 |`-._`-._    `-.__.-'    _.-'_.-'|
 |    `-._`-._        _.-'_.-'    |
  `-._    `-._`-.__.-'_.-'    _.-'
      `-._    `-.__.-'    _.-'
          `-._        _.-'
              `-.__.-'

[2600] 01 Dec 16:11:58.161 # Server started, Redis version 2.8.2104
[2600] 01 Dec 16:11:58.754 #

=== REDIS BUG REPORT START: Cut & paste starting from here ===
[2600] 01 Dec 16:11:58.754 # Out Of Memory allocating 1918986348 bytes.
[2600] 01 Dec 16:11:58.754 # --- ABORT
[2600] 01 Dec 16:11:58.754 # --- STACK TRACE
redis-server.exe!LogStackTrace(c:\release\redis\src\win32_interop\win32_stacktra
ce.cpp:95)(0x00000016, 0x0013F780, 0x00000000, 0x00000001)
redis-server.exe!AbortHandler(c:\release\redis\src\win32_interop\win32_stacktrac
e.cpp:206)(0x00000001, 0x86CBA396, 0x40150880, 0xD067C6FB)
redis-server.exe!raise(f:\dd\vctools\crt\crtw32\misc\winsig.c:587)(0x00000001, 0
x00000000, 0x7261686C, 0x4AC2FF40)
redis-server.exe!abort(f:\dd\vctools\crt\crtw32\misc\abort.c:82)(0x7261686C, 0x4
013F888, 0x7261686C, 0x40000000)
redis-server.exe!redisOutOfMemoryHandler(c:\release\redis\src\redis.c:3397)(0x72
61686C, 0x400319B4, 0x0013F780, 0xFFFFFFFF)
redis-server.exe!zcalloc(c:\release\redis\src\zmalloc.c:161)(0x00000000, 0x00000
080, 0x63686172, 0x0013F780)
redis-server.exe!rdbLoadLzfStringObject(c:\release\redis\src\rdb.c:265)(0x4AC2FF
40, 0xFFFFFFFF, 0x5F633DE0, 0x3FF1AC10)
redis-server.exe!rdbLoadObject(c:\release\redis\src\rdb.c:860)(0x00000000, 0x001
3F850, 0x5F633DE0, 0x3FF1AC10)
redis-server.exe!rdbLoad(c:\release\redis\src\rdb.c:1235)(0x9E6B8845, 0x00000002
, 0x3FEB6968, 0x00000000)
redis-server.exe!loadDataFromDisk(c:\release\redis\src\redis.c:3381)(0x565E0D1E,
 0x4013FA38, 0x00004010, 0x0000A541)
redis-server.exe!redis_main(c:\release\redis\src\redis.c:3509)(0x001A6E00, 0x000
00000, 0x565E0D1E, 0x00000000)
redis-server.exe!main(c:\release\redis\src\win32_interop\win32_qfork.cpp:1363)(0
x00000000, 0x00000000, 0x00000000, 0x00000000)
redis-server.exe!__tmainCRTStartup(f:\dd\vctools\crt\crtw32\startup\crt0.c:255)(
0x00000000, 0x00000000, 0x00000000, 0x00000000)
KERNEL32.DLL!BaseThreadInitThunk(f:\dd\vctools\crt\crtw32\startup\crt0.c:255)(0x
00000000, 0x00000000, 0x00000000, 0x00000000)
ntdll.dll!RtlUserThreadStart(f:\dd\vctools\crt\crtw32\startup\crt0.c:255)(0x0000
0000, 0x00000000, 0x00000000, 0x00000000)
ntdll.dll!RtlUserThreadStart(f:\dd\vctools\crt\crtw32\startup\crt0.c:255)(0x0000
0000, 0x00000000, 0x00000000, 0x00000000)
[2600] 01 Dec 16:11:58.770 #
=== REDIS BUG REPORT END. Make sure to include from START to END. ===

       Please report this bug by following the instructions at:


    Suspect RAM error? Use redis-server --test-memory to verify it.

Michael Hallock

unread,
Dec 2, 2015, 1:54:30 PM12/2/15
to Redis DB
So I FOUND the issue, but I have a new issue I need quick help with.

A key was loaded into the DB that was over 2 GB (!) in size. I deleted the key, deleted the slave DBs and let them resync, and it starts fine now.

So the obvious question is why the hell is one of the keys over 2 GB in size (completely abnormal). 

Anyone have an idea how I can take the dump file I saved and get the key value out of it and actually see whats in it?
Reply all
Reply to author
Forward
0 new messages