This document is a WORK IN PROGRESS.
This is just a quick personal cheat sheet: treat its contents with caution!
Redis¶
Redis is a software project that implements data structure servers. It is open-source, networked, in memory, and stores keys with optional durability.
Reference(s)
Table of contents¶
Install¶
Install Redis:
Config¶
Configure Redis:
# vi /etc/redis.conf
> ...
>
> bind 127.0.0.1 # make sure this line is not commented, unless you want
> # your Redis instance to listen to all interfaces
> ...
>
> # Accept connections on the specified port, default is 6379 (IANA #815344).
> # If port 0 is specified Redis will not listen on a TCP socket.
> port 0
>
> ...
>
> # Unix socket.
> #
> # Specify the path for the Unix socket that will be used to listen for
> # incoming connections. There is no default, so Redis will not listen
> # on a unix socket when not specified.
> #
> # unixsocket /tmp/redis.sock
> # unixsocketperm 700
>
> # Enable and update the Redis socket path:
> unixsocket /run/redis/redis.sock
> # Set permission to all members of the redis user group:
> unixsocketperm 770
> ...
Add Redis to the init system:
Give Redis the good group membership:
Special config with dhcpcd
¶
If, you are using dhcpcd
instead of netifrc
, then you need to config Redis accordingly:
And restart the Redis service:
Use¶
Update procedure¶
TODO
Troubleshooting¶
If this cheat sheet has been useful to you, then please consider leaving a star here.