Redis cannot start You may fix this problem by either when cing the size of the Redis heap with the, redislocking cing

Source: Internet
Author: User

Redis cannot start You may fix this problem by either when cing the size of the Redis heap with the, redislocking cing

Redis cannot be started
The following error is prompted when starting Redis today:
C: \ Java \ redis2817> redis-server.exe for redis. windows. conf
[5268] 23 Apr 11:45:22. 696 #
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
The 'heapdir' ctictive 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 when cing the size of the Redis heap
The-maxheap flag, or by moving the heap file to a local drive with sufficient
Space.
Please see the documentation encoded with the binary distributions for more
Details on the-maxheap and-heapdir flags.

Redis can not continue. Exiting.
Cause analysis:
After analysis, it turns out that the "maxheap" configuration of the maximum heap size is incorrect because the available memory is insufficient and cannot meet the maxheap configuration conditions, so it cannot be started.

Solution:
Open the Redis configuration file "redis. windows. conf" and find the following code:

# The Redis heap must be larger than the value specified by the maxmemory # flag, as the heap allocator has its own memory requirements and # fragmentation of the heap is inevitable. If only the maxmemory flag is # specified, maxheap will be set at 1.5*maxmemory. If the maxheap flag is # specified along with maxmemory, the maxheap flag will be automatically # increased if it is smaller than 1.5*maxmemory. #  # maxheap <bytes>maxheap 51200000

The default value is maxheap 1024000000,
Because the available memory is too small,
So change it to: maxheap 51200000, and you can finally start it.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.