Configure Firewall
If you have a firewall or a router between your cache clients (web/app servers) and the cache servers, then you must open up specific ports in your firewall. This will ensure that cache clients are able to talk to the cache servers.
NCache server uses the following TCP ports for communication.
Client/Server Port: Default is 9800.
Management Port: Default is 8250.
You should also open port 8300-8400 for the management of Cache Host Process management and Cluster port. This is applied on Linux only.
But, if there is a port conflict and the above default ports are being used by other applications then you must configure all the cache servers to use different ports.
Step 1: Modify Alachisoft.NCache.Service.exe.config file
This file is located in %NCHOME%\bin\service folder on all cache servers. %NCHOME%
is NCache install directory.
Please note that for .NET Core installation, the file name is Alachisoft.NCache.Service.dll.config.
Change the “Port” for Client/Server communication and “ManagementPort” for NCache management in the file below.
<appSettings>
...
<add key="NCacheServer.Port" value="9800"/>
...
<add key="NCacheServer.ManagementPort" value="8250"/>
...
</appSettings>
Step 2: Restart NCache Service
Anytime you modify Alachisoft.NCache.Service.exe.config, you must restart NCache Service on all cache servers. Do the following in Windows PowerShell:
Restart-Service -Name ncachesvc
See Also
Configure IP Binding in Multiple NICs
Create a Cache
Simulate Cache Usage
Monitor Caches in PerfMon
Use NCache from .NET Application
Use NCache for ASP.NET Sessions