Sitecore recommends Redis to be installed on a Linux box for production environments so following the guidance we installed and configured Redis for one of our clients onto a Linux box.
Most of team members from our team are well versed with Windows as compared to Linux so we were having a learning curve in order to connect to Redis and troubleshoot few things with it. Sharing our experience and commands that we documented and used to get acquainted with Redis on Linux.
To check Redis logs
======================
sudo tail /etc/redis/redis_log -n 10000
Redis config file
====================
sudo tail /etc/redis/redis.conf -n 10000
Linux system config
======================
sudo tail /etc/sysctl.conf -n 10000
Searching for redis in whole operating system
================================================
find / -path /sys -prune -o -path /proc -prune -o -name *redis*
Monitoring Redis Server
=========================
redis-cli monitor
Editing any file
==================
sudo vim /etc/redis/redis.conf
:q! — Quit without saving
i — open edit mode
:wq — Save and quit
View file content
====================
sudo echo /path/filename
System Logs are saved in different location
=============================================
Path : /var/log/messages
open log file command : sudo tail /var/log/messages -n 10000
Checking Memory consumption
=============================
Simple view : free -m
detailed view : cat /proc/meminfo
Task Manager
==============
top
Check date
============
date
Check uptime
===============
uptime
Flush Redis Cache
====================
redis-cli flushall
Clean Reboot System
=====================
sudo reboot
Hope this helps to someone looking for quick command line guide for Redis on Linux.