---
title: Setting up Redis
slug: neurons-for-itsm/on-premises-help/enu/2025/setting-up-redis
docTags: 
createdAt: 2026-07-29T16:36:06.810Z
---

You will have to setup Redis if you want to use the Chat service in Neurons for ITSM. All the different setup scenarios are explained below.

## Different install and uninstall options and scenarios

**Upgrading/Installing Redis for existing/New customer:**

- [Installing Redis in Linux Container on Windows](docId\:xAtf25vcZrUloCt1Hvt6A)
  - [Installing Linux container on Windows Server with Docker](docId\:xAtf25vcZrUloCt1Hvt6A)
  - [Installing Redis 6.2.5 in Docker](docId\:xAtf25vcZrUloCt1Hvt6A)
- [Installing Redis on Linux Machine](docId\:xAtf25vcZrUloCt1Hvt6A)
  - [Installing Redis on Linux Machine (Ubuntu)](docId\:xAtf25vcZrUloCt1Hvt6A)
  - [Establish the remote Redis Connection](docId\:xAtf25vcZrUloCt1Hvt6A)
  - [Install Redis on Windows Using WSL2](docId\:xAtf25vcZrUloCt1Hvt6A)
- [Uninstalling Redis from Windows Server (existing customer)](docId\:xAtf25vcZrUloCt1Hvt6A)
  - [Remote Redis Connection - using redis.bat script](docId\:xAtf25vcZrUloCt1Hvt6A)
  - [Remote Redis Connection from Windows UI](docId\:xAtf25vcZrUloCt1Hvt6A)
  - [Remote Redis Connection using redis-server.exe](docId\:xAtf25vcZrUloCt1Hvt6A)
- [Uninstalling from Linux Container](docId\:xAtf25vcZrUloCt1Hvt6A)
- [Uninstall from Linux Machine](docId\:xAtf25vcZrUloCt1Hvt6A)

## Option 1 – Install Redis in Linux Container on Windows Server

Prerequisite:

- Windows server - version 2019 or above with HyperV enabled.
- For more information on Linux container requirements check out - [Windows container requirements](https://learn.microsoft.com/en-us/virtualization/windowscontainers/deploy-containers/system-requirements).
- For upgrading your Windows Servers, check out this [Windows Server Upgrade guide](https://learn.microsoft.com/en-us/windows-server/get-started/upgrade-overview#which-version-of-windows-server-should-i-upgrade-to) and look for target version you need to upgrade.

Installation steps:

### Installing Linux container with docker on Windows Server

1. Open PowerShell as Administrator and run the following command:

Install-Module -Name DockerMsftProvider -Repository PSGallery -Force

:::Paragraph{indent="1"}
This installs the Docker-Microsoft PackageManagement provider.
:::

:::Paragraph{indent="1"}
Sample Output
:::

::Image[]{src="https://api.archbee.com/api/optimize/parib0MC3hVoUNdfQdnac/fzeE6os-P4Rhunat-d1yH_sample-output.jpg" position="flex-start" size="44" indent="1" width="436" height="130" initialPath="Redis-Installation/Sample-Output.jpg" githubPath="ITSM-On-Prem-Help/Content/Install_Deploy_guide/Redis-Installation/Sample-Output.jpg" darkWidth="436" darkHeight="130" showCaption="false"}

2. Install the preview build of Docker EE and run the following commands:

Install-Module DockerProvider

Install-Package Docker -ProviderName DockerProvider -RequiredVersion preview

3. Use “Yes” or “Y” to agree to install or use “A” to agree to all.
4. When the installation is complete, reboot the system.
5. To run Linux containers, enable LinuxKit system and use the following command:

\[Environment]\::SetEnvironmentVariable("LCOW\_SUPPORTED", "1", "Machine")

6. Use the following command to restart the system/Docker service after the change:

Restart-Service docker

:::Paragraph{indent="1"}
The Linux container should now successfully run on your Windows Server.
:::

For more information, refer - [How to run Docker Containers on Windows Server 2019](https://computingforgeeks.com/how-to-run-docker-containers-on-windows-server-2019)

### Installing Redis 6.2.5 in Docker

1. Open PowerShell as Administrator and run the following command:

docker run -d -p 6379:6379 --name redis-con redis:6.2.5

2. Check if it has successfully installed by executing the command - `docker ps`

Best Practices

- Run the command - `docker update --restart always redis-con` to always restart Redis Container whenever the docker/machine is restarted. If this is not enabled you have to enable Redis container manually everytime the docker/machine is restarted.
- Enable Authentication for Redis. Refer, Add Authentication to Redis.

### Setting up Redis Authentication

Add Auth to Redis server

1. Open Powershell and run the command - `docker exec -it redis-con sh`.

:::Paragraph{indent="1"}
This will give you Redis console.
:::

2. Run **Redis-cli** to set password to Redis server.
3. Run this command to set Redis password - `redis-cli Config Set requirepass <your-password>`.

:::Paragraph{indent="1"}
Your password is successfully set now.
:::

4. To test run the command - `redis-cli Auth <your-password>” it should return “Ok`.

Set the password through SCW for the application to authenticate through Redis password.

In step 2 of SCW configuration (Service and Asset Manager settings) in the field **Redis Auth Password**, enter the same password that is set in the **redis-cli**, and save it.

:::hint{type="info"}
Once docker/Redis server/machine is restarted , the auth will be set back to noAuth, sensure to remember and update the password to redis server every time restarted.
:::

::Image[]{src="https://api.archbee.com/api/optimize/parib0MC3hVoUNdfQdnac/4eZtHH297KoWz8WJ8PPZW_scw.jpg" position="flex-start" size="56" width="565" height="385" initialPath="Redis-Installation/SCW.jpg" githubPath="ITSM-On-Prem-Help/Content/Install_Deploy_guide/Redis-Installation/SCW.jpg" showCaption="false"}

## Option 2 – Install Redis on Linux Machine

Prerequisite:

- Ubuntu 16.04 or above

Steps to install:

1. Execute the following commands:

Sudo apt update

Sudo apt install redis-server

2. Check if Redis is set up using the following command:

sudo systemctl status redis

If the result displays as `Active: active (running)` then Redis is successfully setup.

::Image[]{src="https://api.archbee.com/api/optimize/parib0MC3hVoUNdfQdnac/6dKe0yaPzqEImuzviHiOQ_runningstatus.jpg" position="flex-start" size="46" width="460" height="231" initialPath="Redis-Installation/RunningStatus.jpg" githubPath="ITSM-On-Prem-Help/Content/Install_Deploy_guide/Redis-Installation/RunningStatus.jpg" showCaption="false"}

3. Edit the **redis.conf** file to make Redis port available to other servers (by default, the Redis port is on :6379) “*sudo gedit /etc/redis/redis.conf*” or “*sudo nano /etc/redis/redis.conf*”
4. Check for the line “**bind 127.0.0.1**” comment this line by prepending ‘**#**’

:::Paragraph{indent="1"}
Since you have removed binding, it is highly recommended to add authentication to Redis Server.
:::

5. Edit **redi.conf “sudo gedit /etc/redis/redis.conf”**
6. Search for requirepass foobared, replace foobared with your\_passowrd.
7. Restart the Redis Server to apply changes.

:::Paragraph{indent="1"}
“sudo systemctl restart redis.service”
:::

8. Then follow “Remote Redis Connection” and “Set password through SCW for the application to authenticate through Redis password.”

## Option 3 – Install Redis on Windows Using WSL2

This procedure describes how to install Redis on Windows by using Windows Subsystem for Linux (WSL). Redis is installed inside a Linux environment, which runs on Windows through WSL. This method is supported on Windows 10, Windows 11, and Windows Server 2019 or later.

To install Redis on Windows, enable WSL2 (Windows Subsystem for Linux). WSL2 lets you run Linux binaries natively on Windows.

**Prerequisites:**

- Windows 10, Windows 11, or Windows Server 2019/2022.

**Steps to enable WSL:**

**For Windows 10, Windows 11, or Windows Server 2022.**

1. Open **PowerShell** or **Command Prompt** as an administrator.
2. Run the following command:
   wsl --install
3. Restart the system when prompted.

:::hint{type="info"}
The **wsl --install** command installs the WSL feature and sets Ubuntu as the default Linux distribution.
:::

**For Windows Server 2019 (version 1709 and later)**

1. Open **PowerShell** as an administrator.
2. Run the following command:
   Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Windows-Subsystem-Linux
3. Restart your computer when prompted.
4. Download a Linux distribution from the Microsoft WSL Store: *"https\://aka.ms/wslstore"*
5. Download the latest **ubuntu** from the following link: *"Manual installation steps for older versions of WSL | Microsoft Learn"*
6. Open PowerShell, Install the downloaded distribution using the following command\::
   curl.exe -L -o ubuntu-2004.appx https\://aka.ms/wslubuntu2004
7. Replace **app\_name.appx** with the actual file name of the downloaded package.
   1. Add-AppxPackage .\ ubuntu-2004.appx
8. This installs Linux on your computer.

**Steps to Install Redis:**

1. Open the installed Linux distribution (for example, Ubuntu) from the Start menu.
2. Update the package list and install Redis:
   curl -fsSL https\://packages.redis.io/gpg | sudo gpg --dearmor -o /usr/share/keyrings/redis-archive-keyring.gpg
   echo "deb \[signed-by=/usr/share/keyrings/redis-archive-keyring.gpg] https\://packages.redis.io/deb $(lsb\_release -cs) main" | sudo tee /etc/apt/sources.list.d/redis.list
   sudo apt-get update
   sudo apt-get install redis
3. Start the Redis server:
   sudo service redis-server start
4. Verify that Redis is running:
   redis-cli
   ping
5. If Redis is running correctly, the response will be:
   PONG

### Establish the remote Redis Connection

1. Edit the **.env** file in the path “*\<install-Path>\Heat\Appserver\chat\\.env*”
2. Edit the attribut&#x65;**&#x20;REDIS\_HOST=localhost to REDIS\_HOST=\<remote-server-ip>**
3. Save the file.
4. This will install redis successfully.
5. Check if Redis is up by using the command `sudo systemctl status redis” – you should see the active (running status).`

## Uninstall Redis for Windows Server (Existing Customer)

This is a mandatory step for existing customers who have already installed Redis and are upgrading to the new version. Uninstall the obsolete Redis version from your machine by following the below server details and uninstall steps.

Redis server details:

| Version | 3.0.503                                                                                                                          |
| ------- | -------------------------------------------------------------------------------------------------------------------------------- |
| Path    | \<install\_path>\HEAT\Appserver\AppServer.Main\redis                                                                             |
| Project | [https://github.com/microsoftarchive/redis](https://github.com/microsoftarchive/redis)                                           |
| License | [https://github.com/microsoftarchive/redis/blob/3.0/license.txt](https://github.com/microsoftarchive/redis/blob/3.0/license.txt) |

### Option 1 – Uninstall using redis.bat script

1. Run the following in Powershell with administrator privileges.

cd \<install\_path>\HEAT\Appserver\AppServer.Main\redis; .\redis.bat -p $(pwd) -c stop

::Image[]{src="https://api.archbee.com/api/optimize/parib0MC3hVoUNdfQdnac/FTeeBRyD-eueQy_dCNTSq_windowspowershell.jpg" position="flex-start" size="57" indent="1" width="570" height="184" initialPath="Redis-Installation/WindowsPowershell.jpg" githubPath="ITSM-On-Prem-Help/Content/Install_Deploy_guide/Redis-Installation/WindowsPowershell.jpg" showCaption="false"}

2. Optional Step: Cleanup Redis installation files by using the below command:

.\redis.bat -p $(pwd) -c cleanup

::Image[]{src="https://api.archbee.com/api/optimize/parib0MC3hVoUNdfQdnac/oSaEvCZgtI7kLKQtrwgZ4_rediscleanup.jpg" position="flex-start" size="57" indent="1" width="566" height="131" initialPath="Redis-Installation/RedisCleanup.jpg" githubPath="ITSM-On-Prem-Help/Content/Install_Deploy_guide/Redis-Installation/RedisCleanup.jpg" showCaption="false"}

### Option 2 – Uninstall from Windows UI

1. Run the following in Powershell with administrator privileges:

Run services.msc

::Image[]{src="https://api.archbee.com/api/optimize/parib0MC3hVoUNdfQdnac/RKHi_6NjJ_pxfCUMnfWfT_runservices.jpg" position="flex-start" size="43" indent="1" width="428" height="265" initialPath="Redis-Installation/RunServices.jpg" githubPath="ITSM-On-Prem-Help/Content/Install_Deploy_guide/Redis-Installation/RunServices.jpg" showCaption="false"}

2. Locate Redis in the list and stop the service.

::Image[]{src="https://api.archbee.com/api/optimize/parib0MC3hVoUNdfQdnac/IFY1lK9JZpU9CS-o8L28S_stopservices.jpg" position="flex-start" size="56" indent="1" width="561" height="169" initialPath="Redis-Installation/StopServices.jpg" githubPath="ITSM-On-Prem-Help/Content/Install_Deploy_guide/Redis-Installation/StopServices.jpg" showCaption="false"}

3. Right click > **Properties**, Change **Startup type** to **Disabled**.

::Image[]{src="https://api.archbee.com/api/optimize/parib0MC3hVoUNdfQdnac/vPEvsIKiBj1F_wCiwSpti_redisproperties.jpg" position="flex-start" size="33" indent="1" width="331" height="355" initialPath="Redis-Installation/RedisProperties.jpg" githubPath="ITSM-On-Prem-Help/Content/Install_Deploy_guide/Redis-Installation/RedisProperties.jpg" showCaption="false"}

### Option 3 – Uninstall using redis-server.exe

Stop the service

Run the following in Powershell with administrator privileges.

.\redis-server.exe --service-stop

::Image[]{src="https://api.archbee.com/api/optimize/parib0MC3hVoUNdfQdnac/rXdrnzkHG_zEDfKDA8pLo_method3-stopservice.jpg" position="flex-start" size="57" width="566" height="47" initialPath="Redis-Installation/Method3-StopService.jpg" githubPath="ITSM-On-Prem-Help/Content/Install_Deploy_guide/Redis-Installation/Method3-StopService.jpg" showCaption="false"}

Uninstall service

Run the following in Powershell with administrator privileges.

.\redis-server.exe --service-uninstall redis.windows.conf

## Uninstall Redis

If you do not want to use the Chat service, you may uninstall Redis by the following the below steps:

### Option 1 – Uninstall Redis in container

Execute the following command:

Docker rm /redis-con

### Option 2 – Uninstall Redis in Linux Machine

For ubuntu distributions

\# if you use apt-get to install redis then use

sudo apt-get purge --auto-remove redis-server

\# if you compiled redis manually then follow the

\# steps below to remove it completely from linux/ubuntu

sudo service redis\_version stop

\# Now delete everything related to Redis server from /usr/local/bin/

sudo rm /usr/local/bin/redis-\*

\# Now delete Redis Configuration files directory and it’s content.

sudo rm -r /etc/redis/

\# Delete existing Redis log files.

sudo rm /var/log/redis\_\*

\# Delete existing Redis data directory and it’s content.

sudo rm -r /var/lib/redis/

\# Delete existing Redis server init scripts

sudo rm /etc/init.d/redis\_\*

\# Remove existing Redis PID files (Only if exists)

sudo rm /var/run/redis\_\*
