Error on package update
Opened this issue · 12 comments
Hello, I updated Redis to latest version today, and I had the following error:
Setting up redis-server (2:3.2.1-1~dotdeb+8.1) ...
Job for redis-server.service failed. See 'systemctl status redis-server.service' and 'journalctl -xn' for details.
invoke-rc.d: initscript redis-server, action "start" failed.
dpkg: error processing package redis-server (--configure):
subprocess installed post-installation script returned error exit status 1
Setting up logstash (1:2.3.3-1) ...
Installing new version of config file /etc/init.d/logstash ...
Processing triggers for systemd (215-17+deb8u4) ...
Errors were encountered while processing:
redis-server
E: Sub-process /usr/bin/dpkg returned an error code (1)
And if I run systemctl status redis-server.service I get
root@ns2:~# systemctl status redis-server.service
● redis-server.service - Advanced key-value store
Loaded: loaded (/lib/systemd/system/redis-server.service; enabled)
Active: failed (Result: start-limit) since Sat 2016-06-18 13:51:28 CEST; 4min 11s ago
Docs: http://redis.io/documentation,
man:redis-server(1)
Process: 10386 ExecStart=/usr/bin/redis-server /etc/redis/redis.conf (code=exited, status=1/FAILURE)
Process: 10381 ExecStartPre=/bin/run-parts --verbose /etc/redis/redis-server.pre-up.d (code=exited, status=0/SUCCESS)
Main PID: 9142 (code=exited, status=0/SUCCESS)
Jun 18 13:51:28 ns2.webdl.org systemd[1]: Failed to start Advanced key-value store.
Jun 18 13:51:28 ns2.webdl.org systemd[1]: Unit redis-server.service entered failed state.
Jun 18 13:51:28 ns2.webdl.org systemd[1]: redis-server.service holdoff time over, scheduling restart.
Jun 18 13:51:28 ns2.webdl.org systemd[1]: Stopping Advanced key-value store...
Jun 18 13:51:28 ns2.webdl.org systemd[1]: Starting Advanced key-value store...
Jun 18 13:51:28 ns2.webdl.org systemd[1]: redis-server.service start request repeated too quickly, refusing to start.
Jun 18 13:51:28 ns2.webdl.org systemd[1]: Failed to start Advanced key-value store.
Jun 18 13:51:28 ns2.webdl.org systemd[1]: Unit redis-server.service entered failed state.
And in the daemon.log I have the following messages:
> Jun 18 14:03:01 ns2 systemd[1]: Starting Advanced key-value store...
> Jun 18 14:03:01 ns2 run-parts[27079]: run-parts: executing /etc/redis/redis-server.pre-up.d/00_example
> Jun 18 14:03:01 ns2 redis-server[27087]: *** FATAL CONFIG FILE ERROR ***
> Jun 18 14:03:01 ns2 redis-server[27087]: Reading the configuration file, at line 143
> Jun 18 14:03:01 ns2 redis-server[27087]: >>> 'logfile /var/log/redis/redis-server.log'
> Jun 18 14:03:01 ns2 redis-server[27087]: Can't open the log file: Permission denied
> Jun 18 14:03:01 ns2 systemd[1]: redis-server.service: control process exited, code=exited status=1
> Jun 18 14:03:01 ns2 systemd[1]: Failed to start Advanced key-value store.
> Jun 18 14:03:01 ns2 systemd[1]: Unit redis-server.service entered failed state.
> Jun 18 14:03:02 ns2 systemd[1]: redis-server.service holdoff time over, scheduling restart.
> Jun 18 14:03:02 ns2 systemd[1]: Stopping Advanced key-value store...
> Jun 18 14:03:02 ns2 systemd[1]: Starting Advanced key-value store...
> Jun 18 14:03:02 ns2 systemd[1]: redis-server.service start request repeated too quickly, refusing to start.
> Jun 18 14:03:02 ns2 systemd[1]: Failed to start Advanced key-value store.
> Jun 18 14:03:02 ns2 systemd[1]: Unit redis-server.service entered failed state.
root@ns2:~# ls -la /var/log/redis
total 8.0K
drwxrwxrwx 2 redis redis 4.0K May 8 10:52 .
drwxr-xr-x 15 root root 4.0K Jun 18 06:27 ..
-rw-rw-r-- 1 redis redis 0 Jun 18 14:02 redis-server.log
Which version were you upgrading from?
It was 3.2.0
I can't reproduce the issue. Could you please check your /var/log/redis/redis-server.log to see what's exactly the problem?
Well I can't check it as nothing is written in it. It's quite weird, as if I run
/usr/bin/redis-server /etc/redis/redis.conf
as root, no problem, but if I use the "standard" service start command, failure.
Same problem happens after purging the redis-server and redis-tools packages, removing the /var/log/redis directories and reinstalling them.
Could you please run it as redis
user instead?
It works, and the log is populated:
[snip]
17216:M 19 Jun 20:07:49.320 # Server started, Redis version 3.2.1
17216:M 19 Jun 20:07:49.320 * The server is now ready to accept connections on port 6379
@kissifrot i had the same issue on my LXC containers
edit /etc/systemd/system/redis.service
and change
PrivateDevices=yes
to PrivateDevices=no
after this change it works.
Some logs from my box:
Jul 30 15:04:13 redis1 systemd[1]: Failed to start Advanced key-value store.
Jul 30 15:04:13 redis1 systemd[1]: Unit redis-server.service entered failed state.
Jul 30 15:04:14 redis1 systemd[1]: redis-server.service holdoff time over, scheduling restart.
Jul 30 15:04:14 redis1 systemd[1]: Stopping Advanced key-value store...
Jul 30 15:04:14 redis1 systemd[1]: Starting Advanced key-value store...
Jul 30 15:04:14 redis1 systemd[1]: redis-server.service start request repeated too quickly, refusing to start.
Jul 30 15:04:14 redis1 systemd[1]: Failed to start Advanced key-value store.
Jul 30 15:04:14 redis1 systemd[1]: Unit redis-server.service entered failed state.
Jul 30 15:05:00 redis1 systemd[1]: Reloading.
Jul 30 15:05:03 redis1 systemd[1]: Starting Advanced key-value store...
Jul 30 15:05:03 redis1 systemd[1]: Failed to reset devices.list on /machine.slice/machine-lxc\x2dredis1.scope: Invalid argument
Jul 30 15:05:03 redis1 systemd[1]: Failed to reset devices.list on /machine.slice/machine-lxc\x2dredis1.scope/system.slice: Invalid argument
Jul 30 15:05:03 redis1 systemd[1]: Failed to reset devices.list on /machine.slice/machine-lxc\x2dredis1.scope/user.slice: Operation not permitted
Jul 30 15:05:03 redis1 systemd[1]: Failed to reset devices.list on /machine.slice/machine-lxc\x2dredis1.scope/system.slice/proc-meminfo.mount: Operation not permitted
Jul 30 15:05:03 redis1 systemd[1]: Failed to reset devices.list on /machine.slice/machine-lxc\x2dredis1.scope/system.slice/dev-ptmx.mount: Operation not permitted
Jul 30 15:05:03 redis1 systemd[1]: Failed to reset devices.list on /machine.slice/machine-lxc\x2dredis1.scope/system.slice/dev-sdb5.swap: Operation not permitted
Jul 30 15:05:03 redis1 systemd[1]: Failed to reset devices.list on /machine.slice/machine-lxc\x2dredis1.scope/system.slice/-.mount: Operation not permitted
Jul 30 15:05:03 redis1 systemd[1]: Failed to reset devices.list on /machine.slice/machine-lxc\x2dredis1.scope/system.slice/cron.service: Operation not permitted
Jul 30 15:05:03 redis1 systemd[1]: Failed to reset devices.list on /machine.slice/machine-lxc\x2dredis1.scope/system.slice/ssh.service: Operation not permitted
Jul 30 15:05:03 redis1 systemd[1]: Failed to reset devices.list on /machine.slice/machine-lxc\x2dredis1.scope/system.slice/rc-local.service: Operation not permitted
Jul 30 15:05:03 redis1 systemd[1]: Failed to reset devices.list on /machine.slice/machine-lxc\x2dredis1.scope/system.slice/exim4.service: Operation not permitted
Jul 30 15:05:03 redis1 systemd[1]: Failed to reset devices.list on /machine.slice/machine-lxc\x2dredis1.scope/system.slice/system-getty.slice: Operation not permitted
Jul 30 15:05:03 redis1 systemd[1]: Failed to reset devices.list on /machine.slice/machine-lxc\x2dredis1.scope/system.slice/system-container\x2dgetty.slice: Operation not permitted
Jul 30 15:05:03 redis1 systemd[1]: Failed to reset devices.list on /machine.slice/machine-lxc\x2dredis1.scope/system.slice/console-getty.service: Operation not permitted
Jul 30 15:05:03 redis1 systemd[1]: Failed to reset devices.list on /machine.slice/machine-lxc\x2dredis1.scope/system.slice/getty-static.service: Operation not permitted
Jul 30 15:05:03 redis1 systemd[1]: Failed to reset devices.list on /machine.slice/machine-lxc\x2dredis1.scope/system.slice/rsyslog.service: Operation not permitted
Jul 30 15:05:03 redis1 systemd[1]: Failed to reset devices.list on /machine.slice/machine-lxc\x2dredis1.scope/system.slice/udev-finish.service: Operation not permitted
Jul 30 15:05:03 redis1 systemd[1]: Failed to reset devices.list on /machine.slice/machine-lxc\x2dredis1.scope/system.slice/systemd-user-sessions.service: Operation not permitted
Jul 30 15:05:03 redis1 systemd[1]: Failed to reset devices.list on /machine.slice/machine-lxc\x2dredis1.scope/system.slice/dev-hugepages.mount: Operation not permitted
Jul 30 15:05:03 redis1 systemd[1]: Failed to reset devices.list on /machine.slice/machine-lxc\x2dredis1.scope/system.slice/dev-mqueue.mount: Operation not permitted
Jul 30 15:05:03 redis1 systemd[1]: Failed to reset devices.list on /machine.slice/machine-lxc\x2dredis1.scope/system.slice/sys-kernel-debug.mount: Operation not permitted
Jul 30 15:05:03 redis1 systemd[1]: Failed to reset devices.list on /machine.slice/machine-lxc\x2dredis1.scope/system.slice/systemd-update-utmp.service: Operation not permitted
Jul 30 15:05:03 redis1 systemd[1]: Failed to reset devices.list on /machine.slice/machine-lxc\x2dredis1.scope/system.slice/sys-fs-fuse-connections.mount: Operation not permitted
Jul 30 15:05:03 redis1 systemd[1]: Failed to reset devices.list on /machine.slice/machine-lxc\x2dredis1.scope/system.slice/systemd-tmpfiles-setup.service: Operation not permitted
Jul 30 15:05:03 redis1 systemd[1]: Failed to reset devices.list on /machine.slice/machine-lxc\x2dredis1.scope/system.slice/systemd-random-seed.service: Operation not permitted
Jul 30 15:05:03 redis1 systemd[1]: Failed to reset devices.list on /machine.slice/machine-lxc\x2dredis1.scope/system.slice/networking.service: Operation not permitted
Jul 30 15:05:03 redis1 systemd[1]: Failed to reset devices.list on /machine.slice/machine-lxc\x2dredis1.scope/system.slice/systemd-journald.service: Operation not permitted
Jul 30 15:05:03 redis1 systemd[1]: Failed to reset devices.list on /machine.slice/machine-lxc\x2dredis1.scope/system.slice/systemd-remount-fs.service: Operation not permitted
Jul 30 15:05:03 redis1 systemd[1339]: Failed at step NAMESPACE spawning /bin/run-parts: Operation not permitted
Jul 30 15:05:03 redis1 systemd[1340]: Failed at step NAMESPACE spawning /usr/bin/redis-server: Operation not permitted
Jul 30 15:05:03 redis1 systemd[1]: redis-server.service: control process exited, code=exited status=226
Jul 30 15:05:03 redis1 systemd[1]: Failed to start Advanced key-value store.
Jul 30 15:05:03 redis1 systemd[1]: Unit redis-server.service entered failed state.
Jul 30 15:05:03 redis1 systemd[1]: redis-server.service holdoff time over, scheduling restart.
Jul 30 15:05:03 redis1 systemd[1]: Stopping Advanced key-value store...
Jul 30 15:05:03 redis1 systemd[1]: Starting Advanced key-value store...
Well that didn't change anything for me
Could you please retry with the latest 3.2.3 version?
Well I retried with this new version (tried upgrade, then purge and install), the problem persists.
Does having a symlink /var/log
->/home/log
change anything?
I guess the problem is elsewhere, but I dunno where.
Same issue here (jessie over lxc, proxmox), some forums suggest it may be related to PrivateTmp=true
on systemd service file.
redis-server 3.2.5-1~dotdeb+8.1 0
Same for me stopped working after update, bellow the logs
Nov 24 00:04:37 systemd[1]: Starting Advanced key-value store...
Nov 24 00:04:37 systemd[1]: Failed to reset devices.list on /system.slice/redis-server.service: No such file or directory
Nov 24 00:04:37 systemd[1]: Failed to set devices.allow on /system.slice/redis-server.service: No such file or directory
Nov 24 00:04:37 systemd[1]: Failed to set devices.allow on /system.slice/redis-server.service: No such file or directory
Nov 24 00:04:37 systemd[1]: Failed to set devices.allow on /system.slice/redis-server.service: No such file or directory
Nov 24 00:04:37 systemd[1]: Failed to set devices.allow on /system.slice/redis-server.service: No such file or directory
Nov 24 00:04:37 systemd[1]: Failed to set devices.allow on /system.slice/redis-server.service: No such file or directory
Nov 24 00:04:37 systemd[1]: Failed to set devices.allow on /system.slice/redis-server.service: No such file or directory
Nov 24 00:04:37 systemd[1]: Failed to set devices.allow on /system.slice/redis-server.service: No such file or directory