Redis server can't run more than 1024M maxheap - Printable Version +- 0Day Forums (https://zeroday.vip) +-- Forum: Coding (https://zeroday.vip/Forum-Coding) +--- Forum: PowerShell & .ps1 (https://zeroday.vip/Forum-PowerShell-ps1) +--- Thread: Redis server can't run more than 1024M maxheap (/Thread-Redis-server-can-39-t-run-more-than-1024M-maxheap) |
Redis server can't run more than 1024M maxheap - ascites119 - 07-21-2023 I am running Redis 2.8.19 on Windows Server 2008. I get an error saying that I have insufficient disc space for my Redis heap. (The memory mapping file instead of fork()). I can only get Redis running, if I have 'maxheap 1024M' in the cfg, even though I have ~50GB of free space on the directory I have set 'heapdir' to. If I try to run it with higher maxheap, or with no maxheap, I get this error (PowerShell): >PS C:\Users\admasgve> cd D:\redis-2.8.19 >PS D:\redis-2.8.19> .\redis-server.exe >[7476] 25 Feb 09:32:38.419 # The Windows version of Redis allocates a large memory mapped file for sharing the heap with the forked process used in persistence operations. This file will be created in the current working directory or the directory specified by the 'heapdir' directive in the .conf file. Windows is reporting that there is insufficient disk space available for this file (Windows error 0x70). >You may fix this problem by either reducing the size of the Redis heap with the --maxheap flag, or by moving the heap file to a local drive with sufficient space. Please see the documentation included with the binary distributions for more details on the --maxheap and --heapdir flags. >Redis can not continue. Exiting. Screenshot: - Free space on D: 49,4 GB - Free space on C: 2,71 GB - Total RAM: 16 GB - Free RAM: ~9 GB redis.windows.conf: # Generated by CONFIG REWRITE loglevel verbose logfile "stdout" save 900 1 save 300 10 save 60 10000 dir "D:\\redis-2.8.19" maxmemory 1024M # maxheap 2048M heapdir "D:\\redis-2.8.19" Everything beside the last 3 lines are generated by redis with the 'CONFIG REWRITE' cmd. I have tried various things, with maxmemory, maxheap and heapdir. From Redis documentation: > maxmemory / maxheap - the maxheap flag controls the maximum size of this memory mapped file, as well as the total usable space for the Redis heap. Running Redis without either maxheap or maxmemory will result in a memory mapped file being created that is equal to the size of physical memory; The Redis heap must be larger than the value specified by the maxmemory Have anybody encountered this problem before? What do I do wrong? RE: Redis server can't run more than 1024M maxheap - wicket100726 - 07-21-2023 To back up Michael's response, I've had the same problem. I had ~40GB of free space, and paging file set to 4G-8G. Redis did not want to start until I set paging file to the amount recommended by Windows themselves, which was 12GB. Really odd beahaviour. RE: Redis server can't run more than 1024M maxheap - reciprocity640 - 07-21-2023 Redis doesn't use the conf file in its home directory by default. You have to pass the file in on the command line: .\redis-server.exe redis.windows.conf This is what is in my conf file: maxheap 2048M heapdir D:\\redisheap These settings resolved my issue. RE: Redis server can't run more than 1024M maxheap - hornwort803362 - 07-21-2023 This is how to use the maxheap flag, which is more convenient then using a config file: redis-server --maxheap 2gb RE: Redis server can't run more than 1024M maxheap - avron724 - 07-21-2023 .\redis-server.exe redis.windows.conf This is what is in my conf file: maxheap 2048M heapdir D:\\redisheap after passing the above parameters in redis-server.exe redis.windows.conf the service has started for me thanks for the solution. RE: Redis server can't run more than 1024M maxheap - gretefqravth - 07-21-2023 maxheap 2048M heapdir D:\\"location where your server is This Should Solve problem Please Ping me if you have Same Question |