FS#44067 - [redis] Failed at step RUNTIME_DIRECTORY...
Attached to Project:
Community Packages
Opened by Oleg Nagornij (corner) - Friday, 06 March 2015, 10:22 GMT
Last edited by Sergej Pupykin (sergej) - Thursday, 30 April 2015, 13:51 GMT
Opened by Oleg Nagornij (corner) - Friday, 06 March 2015, 10:22 GMT
Last edited by Sergej Pupykin (sergej) - Thursday, 30 April 2015, 13:51 GMT
|
Details
Description:
redis.service failed Additional info: * package version(s) * config and/or log files etc. community/redis 2.8.19-2 UNIT LOAD ACTIVE SUB DESCRIPTION ● redis.service loaded failed failed Advanced key-value store Steps to reproduce: Mar 06 12:01:58 lenovobook systemd[1]: redis.service: main process exited, code=exited, status=233/RUNTIME_DIRECTORY Mar 06 12:01:58 lenovobook systemd[487]: Failed at step RUNTIME_DIRECTORY spawning /usr/bin/redis-cli: File exists Mar 06 12:01:58 lenovobook systemd[1]: redis.service: control process exited, code=exited status=233 Mar 06 12:01:58 lenovobook systemd[1]: Unit redis.service entered failed state. Mar 06 12:01:58 lenovobook systemd[1]: redis.service failed. Manually started well Mar 06 12:06:10 lenovobook redis-server[1194]: [1194] 06 Mar 12:06:10.074 # You requested maxclients of 10000 requiring at least 10032 max file descriptors. Mar 06 12:06:10 lenovobook redis-server[1194]: [1194] 06 Mar 12:06:10.074 # Redis can't set maximum open files to 10032 because of OS error: Operation not perm Mar 06 12:06:10 lenovobook redis-server[1194]: [1194] 06 Mar 12:06:10.074 # Current maximum open files is 1024. maxclients has been reduced to 4064 to compensa Mar 06 12:06:10 lenovobook redis-server[1194]: _._ Mar 06 12:06:10 lenovobook redis-server[1194]: _.-``__ ''-._ Mar 06 12:06:10 lenovobook redis-server[1194]: _.-`` `. `_. ''-._ Redis 2.8.19 (00000000/0) 64 bit Mar 06 12:06:10 lenovobook redis-server[1194]: .-`` .-```. ```\/ _.,_ ''-._ Mar 06 12:06:10 lenovobook redis-server[1194]: ( ' , .-` | `, ) Running in stand alone mode Mar 06 12:06:10 lenovobook redis-server[1194]: |`-._`-...-` __...-.``-._|'` _.-'| Port: 6379 Mar 06 12:06:10 lenovobook redis-server[1194]: | `-._ `._ / _.-' | PID: 1194 Mar 06 12:06:10 lenovobook redis-server[1194]: `-._ `-._ `-./ _.-' _.-' Mar 06 12:06:10 lenovobook redis-server[1194]: |`-._`-._ `-.__.-' _.-'_.-'| Mar 06 12:06:10 lenovobook redis-server[1194]: | `-._`-._ _.-'_.-' | http://redis.io Mar 06 12:06:10 lenovobook redis-server[1194]: `-._ `-._`-.__.-'_.-' _.-' Mar 06 12:06:10 lenovobook redis-server[1194]: |`-._`-._ `-.__.-' _.-'_.-'| Mar 06 12:06:10 lenovobook redis-server[1194]: | `-._`-._ _.-'_.-' | Mar 06 12:06:10 lenovobook redis-server[1194]: `-._ `-._`-.__.-'_.-' _.-' Mar 06 12:06:10 lenovobook redis-server[1194]: `-._ `-.__.-' _.-' Mar 06 12:06:10 lenovobook redis-server[1194]: `-._ _.-' Mar 06 12:06:10 lenovobook redis-server[1194]: `-.__.-' Mar 06 12:06:10 lenovobook redis-server[1194]: [1194] 06 Mar 12:06:10.075 # Server started, Redis version 2.8.19 Mar 06 12:06:10 lenovobook redis-server[1194]: [1194] 06 Mar 12:06:10.075 # WARNING overcommit_memory is set to 0! Background save may fail under low memory co Mar 06 12:06:10 lenovobook redis-server[1194]: [1194] 06 Mar 12:06:10.075 # WARNING you have Transparent Huge Pages (THP) support enabled in your kernel. This Mar 06 12:06:10 lenovobook redis-server[1194]: [1194] 06 Mar 12:06:10.075 # WARNING: The TCP backlog setting of 511 cannot be enforced because /proc/sys/net/co Mar 06 12:06:10 lenovobook redis-server[1194]: [1194] 06 Mar 12:06:10.135 * DB loaded from disk: 0.060 seconds Mar 06 12:06:10 lenovobook redis-server[1194]: [1194] 06 Mar 12:06:10.135 * The server is now ready to accept connections on port 6379 |
This task depends upon
systemd-tmpfiles --create redis.conf
I think.
I've added it into post_install hook.
With redis 2.8.19-3 same trouble.
I believe it started after https://projects.archlinux.org/svntogit/community.git/commit/trunk?h=packages/redis&id=f611b11f6e297474ba56b5dbed62ad4239265676 this change
Didn't help.
Service started manually only.
Witout auto start redis.service started after second service call.
Downgrading to 2.18.19-1 fixes the problem.
install -Dm644 ../redis.tmpfiles.d "$pkgdir"/usr/lib/tmpfiles.d/redis.conf
and redis.tmpfiles.d contains
d /run/redis 0755 redis redis -
Seems to be a systemd thing for creating temporary resources. Except when the service starts it tries to create the resource /run/redis that already exists.
EDIT: second one.
redis-runtime-dir.patch (1.5 KiB)
Many thanks for all
Unfortunately it isn't fixed 100%.
When using PHPredis to connect as socket, it crashes with a 'Connection Closed' error.
When downgrading to redis 2.8.19-1 all the problems are gone.
Hope you can take another look. :)
Thanks!
Will take a look. :)
---
Edit: in case anyone else still has issues with phpredis and listen on socket;
$ cat /etc/redis.conf
..
port 0
..
unixsocket /var/run/redis/redis.sock
unixsocketperm 770
# chown redis:redis /var/run/redis
This should solved the issues. For some reason it doesn't load correctly when using the /tmp directory, using /var/run/redis as directory fixes this issue.
Tested with the latest redis + phpredis-git.