Installing Redis with Magento
It’s fairly straight forward on Debian and forks nowadays.
apt-get install redis-server apt-get install php5-redis
Make sure redis is running
/etc/init.d/redis-server restart
Next you need to update some Magento files.
Set “Active” to true.
edit /app/etc/modules/Cm_RedisSession.xml
<config> <modules> <Cm_RedisSession> <active>true</active> <codePool>community</codePool> </Cm_RedisSession> </modules> </config>
Now edit your /app/etc/local.xml
<session_save><![CDATA[files]]></session_save> <session_save_path> <![CDATA[/tmp/session]]> </session_save_path> <cache> <backend>Cm_Cache_Backend_Redis</backend> <backend_options> <server>127.0.0.1</server> <port>6379</port> <database>0</database> <password></password> <force_standalone>0</force_standalone> <connect_retries>1</connect_retries> <automatic_cleaning_factor>0</automatic_cleaning_factor> <compress_data>0</compress_data> <compress_tags>0</compress_tags> <compress_threshold>20480</compress_threshold> <compression_lib>gzip</compression_lib> <persistent>1</persistent> </backend_options> </cache> <full_page_cache> <backend>Cm_Cache_Backend_Redis</backend> <backend_options> <server>127.0.0.1</server> <port>6379</port> <database>1</database> <password></password> <force_standalone>0</force_standalone> <connect_retries>0</connect_retries> <automatic_cleaning_factor>0</automatic_cleaning_factor> <compress_data>0</compress_data> <compress_tags>1</compress_tags> <compress_threshold>20480</compress_threshold> <compression_lib>gzip</compression_lib> <lifetimelimit>43200</lifetimelimit> <persistent>1</persistent> </backend_options> </full_page_cache> <session_save>db</session_save> <redis_session> <host>127.0.0.1</host> <port>6379</port> <password></password> <timeout>2.5</timeout> <persistent>1</persistent> <db>3</db> <compression_threshold>2048</compression_threshold> <compression_lib>gzip</compression_lib> <log_level>1</log_level> <max_concurrency>6</max_concurrency> <break_after_frontend>5</break_after_frontend> <break_after_adminhtml>30</break_after_adminhtml> <bot_lifetime>7200</bot_lifetime> </redis_session>
To look at the redit database 0 and select all keys
redis-cli select 0 keys *
Gareth