Answer the question
In order to leave comments, you need to log in
How to allow Redis to open a specified number of files in Debian 8?
Debian 8
# cat /etc/redis/redis.conf | grep maxclients
maxclients 10000
# cat /etc/default/redis-server
ULIMIT=65536
# cat /etc/sysctl.conf
...
fs.file-max=100000
vm.overcommit_memory = 1
Redis-server.log contains lines like this
[3830] Apr 04 13:49:24.713 # You requested maxclients of 10000 requiring at least 10032 max file descriptors.
[3830] Apr 04 13:49:24.713 # Redis can't set maximum open files to 10032 because of OS error: Operation not permitted.
[3830] Apr 04 13:49:24.713 # Current maximum open files is 1024. maxclients has been reduced to 4064 to compensate for low ulimit. If you need higher maxclients increase 'ulimit -n'.
How to solve this problem?
Answer the question
In order to leave comments, you need to log in
/etc/security/limits.conf
Well, or in /etc/default/redis-server itself, call ulimit -n 10000
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question