4

Whenever I update my Ubuntu software or run the command sudo dpkg --configure -a, it gets stuck at the line Setting up redis-server (5:4.0.9-1ubuntu0.1) .... I don't know why this is happening.

Update Manager screenshot

wjandrea
  • 14,504
Ham Ar
  • 41

4 Answers4

3

I uninstalled redis-server:

sudo apt-get purge redis-server

and installed it again from this repository.

sudo add-apt-repository ppa:chris-lea/redis-server
sudo apt-get update
sudo apt -y install redis-server

Now it works fine.

1

I did ps auxand found that redis server was working...

redis      535  0.0  0.1  51444  4772 ?        Ssl  01:41   0:00 /usr/bin/redis-server *:6379

Killed this process and it doesn't stuck again. However, still cannot install redis

Job for redis-server.service failed because a timeout was exceeded.################################################################################################################..................................................................................] 
See "systemctl status redis-server.service" and "journalctl -xe" for details.
Jeff
  • 1,724
1

Systemd and redis-sentinal disagreed on where the pid file was. My /etc/redis/sentinel.conf was listing the pid as /var/run/redis/redis-sentinel.pid, whereas systemd was looking for /var/run/sentinel/redis-sentinel.pid.

As a result, systemd was killing redis-sentinel and restarting it over and over.

I updated the sentinel.conf to point to the location configured in systemd.

Kieveli
  • 91
0

I faced the same problem so I remove

rm -rf /run/systemd/generator.late/redis-server.service

Now it's working fine. Maybe this will help you

cmthakur
  • 191