A small howto to get the latest
redis-server and a webinterface on Ubuntu.
$ wget http://ftp.de.debian.org/debian/pool/main/r/redis/redis-server_1.2.5-1_amd64.deb ... $ sudo dpkg -i redis-server_1.2.5-1_amd64.deb ... $ /etc/init.d/redis-server start
... redis should listen on
You may need to get
i386 instead of
amd64 if you run 32bit.
You may need to add the following to
vm.overcommit_memory = 1
... that is, especially if you run in a VE (e.g. inside xen).
All other configs are in
Because web interfaces are so simple, I decided to get redweb.
wget http://ftp.us.debian.org/debian/pool/main/p/python-support/python-support_1.0.7_all.deb dpkg -i python-support_1.0.7_all.deb wget http://ftp.us.debian.org/debian/pool/main/p/python-redis/python-redis_1.34.1-1_all.deb dpkg -i python-redis_1.34.1-1_all.deb
So, on Ubuntu,
python-support is at
0.8.4 currently, but we'll need something equal or greater than
0.9.0. This is why I update
python-support from Debian.
git clone http://github.com/tnm/redweb ./redweb-git
index e79a062..e278fca 100644 --- a/redweb/redweb.py +++ b/redweb/redweb.py @@ -15,6 +15,8 @@ __author__ = 'Ted Nyman' __version__ = '0.2.2' __license__ = 'MIT' +import sys +sys.path.append('/path/to/redweb-git/') from bottle import route, request, response, view, send_file, run import redis
cd redweb-git/redweb/ python redweb.py
... this is a bit annoying. If you do
python redweb/redweb.py, it'll complain about missing files.
Then browse to
So this is my
redis-server howto — nice and simple.
And once you have Redis up and running, feel free to browse over to Rediska and use their session handling for Zend Framework. Setup is pretty simple and it works like a charm. :-) I'd suggest you use their
trunk code, which is hosted on Github as it will contain a few improvements and a small bugfix which I did.
For more on Rediska, watch this space. ;-)