redis-server.service: Failed with result 'timeout'. - More errors listed inside
Update: This appears to be mostly fixed. I'm not 100% sure what I did, but it's running and also my sites are loading with it properly. However, I'm still having error #1 about the PID not being readable.
I'm hoping that I can get some help with figuring out why Redis-Server won't run for me. I had it completely running about 3 days ago, but when I attempted to start removing other caching programs from my WordPress install. I somehow broke Redis. Following, I've listed the errors, and then how I've attempted to correct them. Please let me know what your thoughts are and how I can try to fix it going forward.
I've installed Redis-Server originally from source from redis.io, but once that broke I ended up attempting to reinstall from source and also attempted to reinstall from apt
. I'm having the same errors on both types of installs.
uname -a: Linux serverName.tld 4.4.0-97-generic #120-Ubuntu SMP Tue Sep 19 17:28:18 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux
Ubuntu 16.04
Redis-Server 4.0.2
I've used the following tutorial to install Redis-Server: Install Redis Object Cache for WordPress PHP 7 on Ubuntu 16.04
Errors:
redis-server.service: PID file /var/run/redis/redis.pid not readable (yet?) after start: No such file or directory
- I've attempted to correct this by making sure that /var/run/redis/ is already created. I've also made sure that (at separate times) that /var/run/redis/ was owned by redis:redis and also redis:www-data (my apache2 group). I've also attempted many permissions schemes of 777, 755, 775, 007, 770.
Across all of this, I occasionally still get the error. - I've also manually created the /var/run/redis/redis.pid file with the same type of permissions that I mentioned above.
- Finally, per some recommendations on websites, I've also changed the PIDFile to redis-server.pid ...
- None of these changes really seem to persist and work consistently for this error message.
- I've attempted to correct this by making sure that /var/run/redis/ is already created. I've also made sure that (at separate times) that /var/run/redis/ was owned by redis:redis and also redis:www-data (my apache2 group). I've also attempted many permissions schemes of 777, 755, 775, 007, 770.
You requested maxclients of 20000 requiring at least 20032 max file descriptors.
Server can't set maximum open files to 20032 because of OS error: Operation not permitted.
Current maximum open files is 4096. maxclients has been reduced to 4064 to compensate for low ulimit. If you need higher maxclients increase 'ulimit -n'.
- This seems to be influenced by the "MaxClients" piece of the redis.conf file... I've attempted to change the MaxClients option by commenting out and it sets it to default 10000 ... I've also changed this to 20000 in redis.conf and the number goes up to 20032 ... so it always seems that it wants 32 more files than I'm permitted or something.
- I've changed the /etc/systemd/system/redis-server.service file to include "LimitNOFILE=64000" ... this hasn't made a difference.
I've restarted the server - no change. - I've changed /etc/default/redis-server and uncommented the "ULIMIT=65536" ... restarted, again no change.
WARNING you have Transparent Huge Pages (THP) support enabled in your kernel. This will create latency and memory usage issues with Redis. To fix this issue run the command 'echo never > /sys/kernel/mm/transparent_hugepage/enabled' as root, and add it to your /etc/rc.local in order to retain the setting after a reboot. Redis must be restarted after THP is disabled
- This was corrected once I had issued the following command:
echo never > /sys/kernel/mm/transparent_hugepage/enabled
- I also added the above command to /etc/rc.local to persist past reboot. Again, this seems to have been resolved.
- This was corrected once I had issued the following command:
WARNING overcommit_memory is set to 0! Background save may fail under low memory condition. To fix this issue add 'vm.overcommit_memory = 1' to /etc/sysctl.conf and then reboot or run the command 'sysctl vm.overcommit_memory=1' for this to take effect.
I issued the following command to attempt to combat this error ... it seems to only show up sometimes:
echo "vm.overcommit_memory=1" >> /etc/sysctl.conf; sysctl -p
This error happens every once in a while
WARNING: The TCP backlog setting of 511 cannot be enforced because /proc/sys/net/core/somaxconn is set to the lower value o
I've added the following by performing the commands:
echo "net.core.somaxconn=65536" >> /etc/sysctl.conf
echo "net.ipv4.tcp_max_syn_backlog=8192" >> /etc/sysctl.conf
To verify they were added ... sysctl -p
Below is my entire /etc/systemd/system/redis-server.service file.
[Unit]
Description=Redis Datastore Server
After=network.target
[Service]
Type=forking
PIDFile=/var/run/redis/redis.pid
User=redis
Group=www-data
LimitNOFILE=64000
PermissionsStartOnly=true
# Create and set perms for PIDFile directory
ExecStartPre=/bin/mkdir -p /var/run/redis
ExecStartPre=/bin/chown redis:www-data /var/run/redis
ExecStartPre=/bin/chmod 775 -R /var/run/redis
# Create and set perms for Log directory
# This is commented out because I receive errors that the operation is not permitted.
#ExecStartPre=/bin/mkdir -p /var/log/redis
#ExecStartPre=/bin/chown redis -R /var/log/redis
#ExecStartPre=/bin/chmod 775 -R /var/log/redis
# Create and set perms for log file
ExecStartPre=/bin/touch /var/log/redis/redis-server.log
ExecStartPre=/bin/chown redis /var/log/redis/redis-server.log
ExecStartPre=/bin/chmod 775 /var/log/redis/redis-server.log
ExecStart=/sbin/start-stop-daemon --start --pidfile /var/run/redis/redis.pid --umask 007 --exec /usr/bin/redis-server -- /etc/redis/redis.conf
ExecReload=/bin/kill -USR2 $MAINPID
ExecStop=/usr/bin/redis-cli shutdown
Restart=always
[Install]
WantedBy=multi-user.target
I'm at my wits end. I switched to Redis-Server after struggling with failing to get memcached working. The single time that memcached worked, I tried it out on my WordPress sites and it was SUPER fast. I was very impressed and very happy with the performance. However obviously, I can't get it to work, which is why I'm asking for assistance.
redis
add a comment |
Update: This appears to be mostly fixed. I'm not 100% sure what I did, but it's running and also my sites are loading with it properly. However, I'm still having error #1 about the PID not being readable.
I'm hoping that I can get some help with figuring out why Redis-Server won't run for me. I had it completely running about 3 days ago, but when I attempted to start removing other caching programs from my WordPress install. I somehow broke Redis. Following, I've listed the errors, and then how I've attempted to correct them. Please let me know what your thoughts are and how I can try to fix it going forward.
I've installed Redis-Server originally from source from redis.io, but once that broke I ended up attempting to reinstall from source and also attempted to reinstall from apt
. I'm having the same errors on both types of installs.
uname -a: Linux serverName.tld 4.4.0-97-generic #120-Ubuntu SMP Tue Sep 19 17:28:18 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux
Ubuntu 16.04
Redis-Server 4.0.2
I've used the following tutorial to install Redis-Server: Install Redis Object Cache for WordPress PHP 7 on Ubuntu 16.04
Errors:
redis-server.service: PID file /var/run/redis/redis.pid not readable (yet?) after start: No such file or directory
- I've attempted to correct this by making sure that /var/run/redis/ is already created. I've also made sure that (at separate times) that /var/run/redis/ was owned by redis:redis and also redis:www-data (my apache2 group). I've also attempted many permissions schemes of 777, 755, 775, 007, 770.
Across all of this, I occasionally still get the error. - I've also manually created the /var/run/redis/redis.pid file with the same type of permissions that I mentioned above.
- Finally, per some recommendations on websites, I've also changed the PIDFile to redis-server.pid ...
- None of these changes really seem to persist and work consistently for this error message.
- I've attempted to correct this by making sure that /var/run/redis/ is already created. I've also made sure that (at separate times) that /var/run/redis/ was owned by redis:redis and also redis:www-data (my apache2 group). I've also attempted many permissions schemes of 777, 755, 775, 007, 770.
You requested maxclients of 20000 requiring at least 20032 max file descriptors.
Server can't set maximum open files to 20032 because of OS error: Operation not permitted.
Current maximum open files is 4096. maxclients has been reduced to 4064 to compensate for low ulimit. If you need higher maxclients increase 'ulimit -n'.
- This seems to be influenced by the "MaxClients" piece of the redis.conf file... I've attempted to change the MaxClients option by commenting out and it sets it to default 10000 ... I've also changed this to 20000 in redis.conf and the number goes up to 20032 ... so it always seems that it wants 32 more files than I'm permitted or something.
- I've changed the /etc/systemd/system/redis-server.service file to include "LimitNOFILE=64000" ... this hasn't made a difference.
I've restarted the server - no change. - I've changed /etc/default/redis-server and uncommented the "ULIMIT=65536" ... restarted, again no change.
WARNING you have Transparent Huge Pages (THP) support enabled in your kernel. This will create latency and memory usage issues with Redis. To fix this issue run the command 'echo never > /sys/kernel/mm/transparent_hugepage/enabled' as root, and add it to your /etc/rc.local in order to retain the setting after a reboot. Redis must be restarted after THP is disabled
- This was corrected once I had issued the following command:
echo never > /sys/kernel/mm/transparent_hugepage/enabled
- I also added the above command to /etc/rc.local to persist past reboot. Again, this seems to have been resolved.
- This was corrected once I had issued the following command:
WARNING overcommit_memory is set to 0! Background save may fail under low memory condition. To fix this issue add 'vm.overcommit_memory = 1' to /etc/sysctl.conf and then reboot or run the command 'sysctl vm.overcommit_memory=1' for this to take effect.
I issued the following command to attempt to combat this error ... it seems to only show up sometimes:
echo "vm.overcommit_memory=1" >> /etc/sysctl.conf; sysctl -p
This error happens every once in a while
WARNING: The TCP backlog setting of 511 cannot be enforced because /proc/sys/net/core/somaxconn is set to the lower value o
I've added the following by performing the commands:
echo "net.core.somaxconn=65536" >> /etc/sysctl.conf
echo "net.ipv4.tcp_max_syn_backlog=8192" >> /etc/sysctl.conf
To verify they were added ... sysctl -p
Below is my entire /etc/systemd/system/redis-server.service file.
[Unit]
Description=Redis Datastore Server
After=network.target
[Service]
Type=forking
PIDFile=/var/run/redis/redis.pid
User=redis
Group=www-data
LimitNOFILE=64000
PermissionsStartOnly=true
# Create and set perms for PIDFile directory
ExecStartPre=/bin/mkdir -p /var/run/redis
ExecStartPre=/bin/chown redis:www-data /var/run/redis
ExecStartPre=/bin/chmod 775 -R /var/run/redis
# Create and set perms for Log directory
# This is commented out because I receive errors that the operation is not permitted.
#ExecStartPre=/bin/mkdir -p /var/log/redis
#ExecStartPre=/bin/chown redis -R /var/log/redis
#ExecStartPre=/bin/chmod 775 -R /var/log/redis
# Create and set perms for log file
ExecStartPre=/bin/touch /var/log/redis/redis-server.log
ExecStartPre=/bin/chown redis /var/log/redis/redis-server.log
ExecStartPre=/bin/chmod 775 /var/log/redis/redis-server.log
ExecStart=/sbin/start-stop-daemon --start --pidfile /var/run/redis/redis.pid --umask 007 --exec /usr/bin/redis-server -- /etc/redis/redis.conf
ExecReload=/bin/kill -USR2 $MAINPID
ExecStop=/usr/bin/redis-cli shutdown
Restart=always
[Install]
WantedBy=multi-user.target
I'm at my wits end. I switched to Redis-Server after struggling with failing to get memcached working. The single time that memcached worked, I tried it out on my WordPress sites and it was SUPER fast. I was very impressed and very happy with the performance. However obviously, I can't get it to work, which is why I'm asking for assistance.
redis
add a comment |
Update: This appears to be mostly fixed. I'm not 100% sure what I did, but it's running and also my sites are loading with it properly. However, I'm still having error #1 about the PID not being readable.
I'm hoping that I can get some help with figuring out why Redis-Server won't run for me. I had it completely running about 3 days ago, but when I attempted to start removing other caching programs from my WordPress install. I somehow broke Redis. Following, I've listed the errors, and then how I've attempted to correct them. Please let me know what your thoughts are and how I can try to fix it going forward.
I've installed Redis-Server originally from source from redis.io, but once that broke I ended up attempting to reinstall from source and also attempted to reinstall from apt
. I'm having the same errors on both types of installs.
uname -a: Linux serverName.tld 4.4.0-97-generic #120-Ubuntu SMP Tue Sep 19 17:28:18 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux
Ubuntu 16.04
Redis-Server 4.0.2
I've used the following tutorial to install Redis-Server: Install Redis Object Cache for WordPress PHP 7 on Ubuntu 16.04
Errors:
redis-server.service: PID file /var/run/redis/redis.pid not readable (yet?) after start: No such file or directory
- I've attempted to correct this by making sure that /var/run/redis/ is already created. I've also made sure that (at separate times) that /var/run/redis/ was owned by redis:redis and also redis:www-data (my apache2 group). I've also attempted many permissions schemes of 777, 755, 775, 007, 770.
Across all of this, I occasionally still get the error. - I've also manually created the /var/run/redis/redis.pid file with the same type of permissions that I mentioned above.
- Finally, per some recommendations on websites, I've also changed the PIDFile to redis-server.pid ...
- None of these changes really seem to persist and work consistently for this error message.
- I've attempted to correct this by making sure that /var/run/redis/ is already created. I've also made sure that (at separate times) that /var/run/redis/ was owned by redis:redis and also redis:www-data (my apache2 group). I've also attempted many permissions schemes of 777, 755, 775, 007, 770.
You requested maxclients of 20000 requiring at least 20032 max file descriptors.
Server can't set maximum open files to 20032 because of OS error: Operation not permitted.
Current maximum open files is 4096. maxclients has been reduced to 4064 to compensate for low ulimit. If you need higher maxclients increase 'ulimit -n'.
- This seems to be influenced by the "MaxClients" piece of the redis.conf file... I've attempted to change the MaxClients option by commenting out and it sets it to default 10000 ... I've also changed this to 20000 in redis.conf and the number goes up to 20032 ... so it always seems that it wants 32 more files than I'm permitted or something.
- I've changed the /etc/systemd/system/redis-server.service file to include "LimitNOFILE=64000" ... this hasn't made a difference.
I've restarted the server - no change. - I've changed /etc/default/redis-server and uncommented the "ULIMIT=65536" ... restarted, again no change.
WARNING you have Transparent Huge Pages (THP) support enabled in your kernel. This will create latency and memory usage issues with Redis. To fix this issue run the command 'echo never > /sys/kernel/mm/transparent_hugepage/enabled' as root, and add it to your /etc/rc.local in order to retain the setting after a reboot. Redis must be restarted after THP is disabled
- This was corrected once I had issued the following command:
echo never > /sys/kernel/mm/transparent_hugepage/enabled
- I also added the above command to /etc/rc.local to persist past reboot. Again, this seems to have been resolved.
- This was corrected once I had issued the following command:
WARNING overcommit_memory is set to 0! Background save may fail under low memory condition. To fix this issue add 'vm.overcommit_memory = 1' to /etc/sysctl.conf and then reboot or run the command 'sysctl vm.overcommit_memory=1' for this to take effect.
I issued the following command to attempt to combat this error ... it seems to only show up sometimes:
echo "vm.overcommit_memory=1" >> /etc/sysctl.conf; sysctl -p
This error happens every once in a while
WARNING: The TCP backlog setting of 511 cannot be enforced because /proc/sys/net/core/somaxconn is set to the lower value o
I've added the following by performing the commands:
echo "net.core.somaxconn=65536" >> /etc/sysctl.conf
echo "net.ipv4.tcp_max_syn_backlog=8192" >> /etc/sysctl.conf
To verify they were added ... sysctl -p
Below is my entire /etc/systemd/system/redis-server.service file.
[Unit]
Description=Redis Datastore Server
After=network.target
[Service]
Type=forking
PIDFile=/var/run/redis/redis.pid
User=redis
Group=www-data
LimitNOFILE=64000
PermissionsStartOnly=true
# Create and set perms for PIDFile directory
ExecStartPre=/bin/mkdir -p /var/run/redis
ExecStartPre=/bin/chown redis:www-data /var/run/redis
ExecStartPre=/bin/chmod 775 -R /var/run/redis
# Create and set perms for Log directory
# This is commented out because I receive errors that the operation is not permitted.
#ExecStartPre=/bin/mkdir -p /var/log/redis
#ExecStartPre=/bin/chown redis -R /var/log/redis
#ExecStartPre=/bin/chmod 775 -R /var/log/redis
# Create and set perms for log file
ExecStartPre=/bin/touch /var/log/redis/redis-server.log
ExecStartPre=/bin/chown redis /var/log/redis/redis-server.log
ExecStartPre=/bin/chmod 775 /var/log/redis/redis-server.log
ExecStart=/sbin/start-stop-daemon --start --pidfile /var/run/redis/redis.pid --umask 007 --exec /usr/bin/redis-server -- /etc/redis/redis.conf
ExecReload=/bin/kill -USR2 $MAINPID
ExecStop=/usr/bin/redis-cli shutdown
Restart=always
[Install]
WantedBy=multi-user.target
I'm at my wits end. I switched to Redis-Server after struggling with failing to get memcached working. The single time that memcached worked, I tried it out on my WordPress sites and it was SUPER fast. I was very impressed and very happy with the performance. However obviously, I can't get it to work, which is why I'm asking for assistance.
redis
Update: This appears to be mostly fixed. I'm not 100% sure what I did, but it's running and also my sites are loading with it properly. However, I'm still having error #1 about the PID not being readable.
I'm hoping that I can get some help with figuring out why Redis-Server won't run for me. I had it completely running about 3 days ago, but when I attempted to start removing other caching programs from my WordPress install. I somehow broke Redis. Following, I've listed the errors, and then how I've attempted to correct them. Please let me know what your thoughts are and how I can try to fix it going forward.
I've installed Redis-Server originally from source from redis.io, but once that broke I ended up attempting to reinstall from source and also attempted to reinstall from apt
. I'm having the same errors on both types of installs.
uname -a: Linux serverName.tld 4.4.0-97-generic #120-Ubuntu SMP Tue Sep 19 17:28:18 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux
Ubuntu 16.04
Redis-Server 4.0.2
I've used the following tutorial to install Redis-Server: Install Redis Object Cache for WordPress PHP 7 on Ubuntu 16.04
Errors:
redis-server.service: PID file /var/run/redis/redis.pid not readable (yet?) after start: No such file or directory
- I've attempted to correct this by making sure that /var/run/redis/ is already created. I've also made sure that (at separate times) that /var/run/redis/ was owned by redis:redis and also redis:www-data (my apache2 group). I've also attempted many permissions schemes of 777, 755, 775, 007, 770.
Across all of this, I occasionally still get the error. - I've also manually created the /var/run/redis/redis.pid file with the same type of permissions that I mentioned above.
- Finally, per some recommendations on websites, I've also changed the PIDFile to redis-server.pid ...
- None of these changes really seem to persist and work consistently for this error message.
- I've attempted to correct this by making sure that /var/run/redis/ is already created. I've also made sure that (at separate times) that /var/run/redis/ was owned by redis:redis and also redis:www-data (my apache2 group). I've also attempted many permissions schemes of 777, 755, 775, 007, 770.
You requested maxclients of 20000 requiring at least 20032 max file descriptors.
Server can't set maximum open files to 20032 because of OS error: Operation not permitted.
Current maximum open files is 4096. maxclients has been reduced to 4064 to compensate for low ulimit. If you need higher maxclients increase 'ulimit -n'.
- This seems to be influenced by the "MaxClients" piece of the redis.conf file... I've attempted to change the MaxClients option by commenting out and it sets it to default 10000 ... I've also changed this to 20000 in redis.conf and the number goes up to 20032 ... so it always seems that it wants 32 more files than I'm permitted or something.
- I've changed the /etc/systemd/system/redis-server.service file to include "LimitNOFILE=64000" ... this hasn't made a difference.
I've restarted the server - no change. - I've changed /etc/default/redis-server and uncommented the "ULIMIT=65536" ... restarted, again no change.
WARNING you have Transparent Huge Pages (THP) support enabled in your kernel. This will create latency and memory usage issues with Redis. To fix this issue run the command 'echo never > /sys/kernel/mm/transparent_hugepage/enabled' as root, and add it to your /etc/rc.local in order to retain the setting after a reboot. Redis must be restarted after THP is disabled
- This was corrected once I had issued the following command:
echo never > /sys/kernel/mm/transparent_hugepage/enabled
- I also added the above command to /etc/rc.local to persist past reboot. Again, this seems to have been resolved.
- This was corrected once I had issued the following command:
WARNING overcommit_memory is set to 0! Background save may fail under low memory condition. To fix this issue add 'vm.overcommit_memory = 1' to /etc/sysctl.conf and then reboot or run the command 'sysctl vm.overcommit_memory=1' for this to take effect.
I issued the following command to attempt to combat this error ... it seems to only show up sometimes:
echo "vm.overcommit_memory=1" >> /etc/sysctl.conf; sysctl -p
This error happens every once in a while
WARNING: The TCP backlog setting of 511 cannot be enforced because /proc/sys/net/core/somaxconn is set to the lower value o
I've added the following by performing the commands:
echo "net.core.somaxconn=65536" >> /etc/sysctl.conf
echo "net.ipv4.tcp_max_syn_backlog=8192" >> /etc/sysctl.conf
To verify they were added ... sysctl -p
Below is my entire /etc/systemd/system/redis-server.service file.
[Unit]
Description=Redis Datastore Server
After=network.target
[Service]
Type=forking
PIDFile=/var/run/redis/redis.pid
User=redis
Group=www-data
LimitNOFILE=64000
PermissionsStartOnly=true
# Create and set perms for PIDFile directory
ExecStartPre=/bin/mkdir -p /var/run/redis
ExecStartPre=/bin/chown redis:www-data /var/run/redis
ExecStartPre=/bin/chmod 775 -R /var/run/redis
# Create and set perms for Log directory
# This is commented out because I receive errors that the operation is not permitted.
#ExecStartPre=/bin/mkdir -p /var/log/redis
#ExecStartPre=/bin/chown redis -R /var/log/redis
#ExecStartPre=/bin/chmod 775 -R /var/log/redis
# Create and set perms for log file
ExecStartPre=/bin/touch /var/log/redis/redis-server.log
ExecStartPre=/bin/chown redis /var/log/redis/redis-server.log
ExecStartPre=/bin/chmod 775 /var/log/redis/redis-server.log
ExecStart=/sbin/start-stop-daemon --start --pidfile /var/run/redis/redis.pid --umask 007 --exec /usr/bin/redis-server -- /etc/redis/redis.conf
ExecReload=/bin/kill -USR2 $MAINPID
ExecStop=/usr/bin/redis-cli shutdown
Restart=always
[Install]
WantedBy=multi-user.target
I'm at my wits end. I switched to Redis-Server after struggling with failing to get memcached working. The single time that memcached worked, I tried it out on my WordPress sites and it was SUPER fast. I was very impressed and very happy with the performance. However obviously, I can't get it to work, which is why I'm asking for assistance.
redis
redis
edited Oct 23 '17 at 16:52
Todd-ProNoob
asked Oct 22 '17 at 20:43
Todd-ProNoobTodd-ProNoob
64
64
add a comment |
add a comment |
2 Answers
2
active
oldest
votes
Might be unlikely since you don't mention other changes, I'll post anyway.
Perhaps this is an IPv6 / IPv4 issue. If you disabled IPv6 at any point, you'll get the result you described.
Take a look at /var/log/redis/redis-server.log. This is what I found in mine:
17008:C 24 Aug 07:17:45.193 # oO0OoO0OoO0Oo Redis is starting oO0OoO0OoO0Oo
17008:C 24 Aug 07:17:45.193 # Redis version=4.0.9, bits=64, commit=00000000, modified=0, pid=17008, just started
17008:C 24 Aug 07:17:45.193 # Configuration loaded
17009:M 24 Aug 07:17:45.195 # Creating Server TCP listening socket ::1:6379:
bind: Cannot assign requested address
Redis was attempting to use IPv6 (::1:6379:). I had disabled IPv6 on this system (for reasons), however the default redis-cache configuration enables both IPv4 and v6. If you're seeing the "Cannot assign" error in that log, take a look at /etc/redis/redis.conf. The "out-of-box" configuration enables IPv6 (::1):
bind 127.0.0.1 ::1
So I removed that, changing it to:
bind 127.0.0.1
Redis started right up after that.
Hope that helps!
add a comment |
Try this (tested Ubuntu 18.04):
sudo sh -c 'echo "httpd soft nofile 4096" >> /etc/security/limits.conf'
sudo sh -c 'echo "httpd hard nofile 10240" >> /etc/security/limits.conf'
sudo sh -c 'echo "fs.file-max = 100000" >> /etc/sysctl.conf'
sudo sh -c 'echo "vm.overcommit_memory = 1" >> /etc/sysctl.conf'
sudo sh -c 'echo "net.core.somaxconn = 65535" >> /etc/sysctl.conf'
sudo apt -y install redis-server redis-tools
sudo service redis-server stop
sudo sed -i '/^bind/s/bind.*/bind 0.0.0.0/' /etc/redis/redis.conf
if [ ! -d /var/run/redis ]; then sudo mkdir -p /var/run/redis && sudo chown redis /var/run/redis; fi
sudo service redis-server start
source: Ntopng maravento.com
add a comment |
Your Answer
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "89"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f967763%2fredis-server-service-failed-with-result-timeout-more-errors-listed-inside%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
2 Answers
2
active
oldest
votes
2 Answers
2
active
oldest
votes
active
oldest
votes
active
oldest
votes
Might be unlikely since you don't mention other changes, I'll post anyway.
Perhaps this is an IPv6 / IPv4 issue. If you disabled IPv6 at any point, you'll get the result you described.
Take a look at /var/log/redis/redis-server.log. This is what I found in mine:
17008:C 24 Aug 07:17:45.193 # oO0OoO0OoO0Oo Redis is starting oO0OoO0OoO0Oo
17008:C 24 Aug 07:17:45.193 # Redis version=4.0.9, bits=64, commit=00000000, modified=0, pid=17008, just started
17008:C 24 Aug 07:17:45.193 # Configuration loaded
17009:M 24 Aug 07:17:45.195 # Creating Server TCP listening socket ::1:6379:
bind: Cannot assign requested address
Redis was attempting to use IPv6 (::1:6379:). I had disabled IPv6 on this system (for reasons), however the default redis-cache configuration enables both IPv4 and v6. If you're seeing the "Cannot assign" error in that log, take a look at /etc/redis/redis.conf. The "out-of-box" configuration enables IPv6 (::1):
bind 127.0.0.1 ::1
So I removed that, changing it to:
bind 127.0.0.1
Redis started right up after that.
Hope that helps!
add a comment |
Might be unlikely since you don't mention other changes, I'll post anyway.
Perhaps this is an IPv6 / IPv4 issue. If you disabled IPv6 at any point, you'll get the result you described.
Take a look at /var/log/redis/redis-server.log. This is what I found in mine:
17008:C 24 Aug 07:17:45.193 # oO0OoO0OoO0Oo Redis is starting oO0OoO0OoO0Oo
17008:C 24 Aug 07:17:45.193 # Redis version=4.0.9, bits=64, commit=00000000, modified=0, pid=17008, just started
17008:C 24 Aug 07:17:45.193 # Configuration loaded
17009:M 24 Aug 07:17:45.195 # Creating Server TCP listening socket ::1:6379:
bind: Cannot assign requested address
Redis was attempting to use IPv6 (::1:6379:). I had disabled IPv6 on this system (for reasons), however the default redis-cache configuration enables both IPv4 and v6. If you're seeing the "Cannot assign" error in that log, take a look at /etc/redis/redis.conf. The "out-of-box" configuration enables IPv6 (::1):
bind 127.0.0.1 ::1
So I removed that, changing it to:
bind 127.0.0.1
Redis started right up after that.
Hope that helps!
add a comment |
Might be unlikely since you don't mention other changes, I'll post anyway.
Perhaps this is an IPv6 / IPv4 issue. If you disabled IPv6 at any point, you'll get the result you described.
Take a look at /var/log/redis/redis-server.log. This is what I found in mine:
17008:C 24 Aug 07:17:45.193 # oO0OoO0OoO0Oo Redis is starting oO0OoO0OoO0Oo
17008:C 24 Aug 07:17:45.193 # Redis version=4.0.9, bits=64, commit=00000000, modified=0, pid=17008, just started
17008:C 24 Aug 07:17:45.193 # Configuration loaded
17009:M 24 Aug 07:17:45.195 # Creating Server TCP listening socket ::1:6379:
bind: Cannot assign requested address
Redis was attempting to use IPv6 (::1:6379:). I had disabled IPv6 on this system (for reasons), however the default redis-cache configuration enables both IPv4 and v6. If you're seeing the "Cannot assign" error in that log, take a look at /etc/redis/redis.conf. The "out-of-box" configuration enables IPv6 (::1):
bind 127.0.0.1 ::1
So I removed that, changing it to:
bind 127.0.0.1
Redis started right up after that.
Hope that helps!
Might be unlikely since you don't mention other changes, I'll post anyway.
Perhaps this is an IPv6 / IPv4 issue. If you disabled IPv6 at any point, you'll get the result you described.
Take a look at /var/log/redis/redis-server.log. This is what I found in mine:
17008:C 24 Aug 07:17:45.193 # oO0OoO0OoO0Oo Redis is starting oO0OoO0OoO0Oo
17008:C 24 Aug 07:17:45.193 # Redis version=4.0.9, bits=64, commit=00000000, modified=0, pid=17008, just started
17008:C 24 Aug 07:17:45.193 # Configuration loaded
17009:M 24 Aug 07:17:45.195 # Creating Server TCP listening socket ::1:6379:
bind: Cannot assign requested address
Redis was attempting to use IPv6 (::1:6379:). I had disabled IPv6 on this system (for reasons), however the default redis-cache configuration enables both IPv4 and v6. If you're seeing the "Cannot assign" error in that log, take a look at /etc/redis/redis.conf. The "out-of-box" configuration enables IPv6 (::1):
bind 127.0.0.1 ::1
So I removed that, changing it to:
bind 127.0.0.1
Redis started right up after that.
Hope that helps!
answered Aug 24 '18 at 13:38
ChrisChris
1
1
add a comment |
add a comment |
Try this (tested Ubuntu 18.04):
sudo sh -c 'echo "httpd soft nofile 4096" >> /etc/security/limits.conf'
sudo sh -c 'echo "httpd hard nofile 10240" >> /etc/security/limits.conf'
sudo sh -c 'echo "fs.file-max = 100000" >> /etc/sysctl.conf'
sudo sh -c 'echo "vm.overcommit_memory = 1" >> /etc/sysctl.conf'
sudo sh -c 'echo "net.core.somaxconn = 65535" >> /etc/sysctl.conf'
sudo apt -y install redis-server redis-tools
sudo service redis-server stop
sudo sed -i '/^bind/s/bind.*/bind 0.0.0.0/' /etc/redis/redis.conf
if [ ! -d /var/run/redis ]; then sudo mkdir -p /var/run/redis && sudo chown redis /var/run/redis; fi
sudo service redis-server start
source: Ntopng maravento.com
add a comment |
Try this (tested Ubuntu 18.04):
sudo sh -c 'echo "httpd soft nofile 4096" >> /etc/security/limits.conf'
sudo sh -c 'echo "httpd hard nofile 10240" >> /etc/security/limits.conf'
sudo sh -c 'echo "fs.file-max = 100000" >> /etc/sysctl.conf'
sudo sh -c 'echo "vm.overcommit_memory = 1" >> /etc/sysctl.conf'
sudo sh -c 'echo "net.core.somaxconn = 65535" >> /etc/sysctl.conf'
sudo apt -y install redis-server redis-tools
sudo service redis-server stop
sudo sed -i '/^bind/s/bind.*/bind 0.0.0.0/' /etc/redis/redis.conf
if [ ! -d /var/run/redis ]; then sudo mkdir -p /var/run/redis && sudo chown redis /var/run/redis; fi
sudo service redis-server start
source: Ntopng maravento.com
add a comment |
Try this (tested Ubuntu 18.04):
sudo sh -c 'echo "httpd soft nofile 4096" >> /etc/security/limits.conf'
sudo sh -c 'echo "httpd hard nofile 10240" >> /etc/security/limits.conf'
sudo sh -c 'echo "fs.file-max = 100000" >> /etc/sysctl.conf'
sudo sh -c 'echo "vm.overcommit_memory = 1" >> /etc/sysctl.conf'
sudo sh -c 'echo "net.core.somaxconn = 65535" >> /etc/sysctl.conf'
sudo apt -y install redis-server redis-tools
sudo service redis-server stop
sudo sed -i '/^bind/s/bind.*/bind 0.0.0.0/' /etc/redis/redis.conf
if [ ! -d /var/run/redis ]; then sudo mkdir -p /var/run/redis && sudo chown redis /var/run/redis; fi
sudo service redis-server start
source: Ntopng maravento.com
Try this (tested Ubuntu 18.04):
sudo sh -c 'echo "httpd soft nofile 4096" >> /etc/security/limits.conf'
sudo sh -c 'echo "httpd hard nofile 10240" >> /etc/security/limits.conf'
sudo sh -c 'echo "fs.file-max = 100000" >> /etc/sysctl.conf'
sudo sh -c 'echo "vm.overcommit_memory = 1" >> /etc/sysctl.conf'
sudo sh -c 'echo "net.core.somaxconn = 65535" >> /etc/sysctl.conf'
sudo apt -y install redis-server redis-tools
sudo service redis-server stop
sudo sed -i '/^bind/s/bind.*/bind 0.0.0.0/' /etc/redis/redis.conf
if [ ! -d /var/run/redis ]; then sudo mkdir -p /var/run/redis && sudo chown redis /var/run/redis; fi
sudo service redis-server start
source: Ntopng maravento.com
answered Mar 10 at 16:34
ajcgajcg
749411
749411
add a comment |
add a comment |
Thanks for contributing an answer to Ask Ubuntu!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f967763%2fredis-server-service-failed-with-result-timeout-more-errors-listed-inside%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown