Poking redis with netcat

January 26, 2011

Categories: bash, redis

netcat makes for a fine redis client.

like this I guess...

$ (echo -en "info\r\n"; sleep 0.1) | nc localhost 6379 | grep "used_memory:"
used_memory:7911904

$ while true; do echo -en "lpush foo asdf\r\nltrim foo 0 499\r\n"; done | nc localhost 6379
+OK
:501
+OK
:501
...
blog comments powered by Disqus