Redis on OpenBSD

Page content

let’s play a bit with Redis. A In-Memory Data Store for Caching, Streaming, Message Broker


doas rcctl add redis
doas rcctl enable redis
doas rcclt restart redis

Package Summary

what did we got installed ?

doas pkg_info -L redis
$ doas pkg_info -L redis
Information for inst:redis-6.2.7

A Server, a Client, a configuration File, …

Keep Alive

send a ping …

$ redis-cli ping

Redis Client

Let’s connect with the Client and find help …

$ redis-cli> help @generic

  COPY source destination [DB destination-db] [REPLACE]
  summary: Copy a key
  since: 6.2.0

  DEL key [key ...]
  summary: Delete a key
  since: 1.0.0

First Steps

Write and Read to Redis

$ redis-cli> set name hans
OK> get name
"hans">> HSET key vorname franz
(integer) 1> HSET key nachname meier
(integer) 1> HGET key vorname
"franz"> HGETALL key
1) "vorname"
2) "franz"
3) "nachname"
4) "meier"

to be continued ;)

sha256: db83111f8844fe0de9939ba92bb9b0dcc01a7ba8ae0ca22c4791bc79ca288907