How to Include NCache IP Binding

NCache typically runs in a clustered environment which makes it a network intensive resource. Within a typical NCache environment, information is exchanged in the following ways:

  1. Cache servers talking to other Cache Servers in a NCache Cluster (Cluster Communication)
  2. NCache Cluster Cache Servers talking to Remote Clients (Client-Server communication)

During the NCache installation process, NCache automatically binds to the first available IP Address which can be used for both types of communication i.e. within the Cluster between Cache Server to Cache Server or between the Remote Clients (Web Servers) and the NCache servers. At times, IP Binding properties might not be properly configured during the installation process and the user might see the following errors related to the NCache service not starting:

"The NCache Service has started and then stopped. Some Services start and stop automatically, if they have no work to do"

Related errors can occur because of incorrect IP Binding when adding another Cache Server or remote client to an NCache Cluster in NCache Manager. The error would look like this:

"NCache Service could not be contacted on ‘IP Address of the machine'"

To solve this problem IP Binding can be configured manually. To specify the IP Addresses for NCache Cluster Server to Server communications or Remote Client to NCache Cluster communications, you will have to modify the following two lines in Alachisoft.NCache.Service.exe.config file located at (C:\Program Files\NCache\bin\service) and then restart NCache service:

<add key = "NCacheServer.BindToClientServerIP" value = "" />
<add key = "NCacheServer.BindToClusterIP" value = "" />

BindToClusterIP: Used to bind NCache to the Network Interface Card to use for Cluster-wide communication and provide the appropriate IP Address. NCache will use this IP for cache server to server communication.

BindToClientServerIP: Used to bind NCache to the Network interface to use for Remote Client to Cache Server communication and provide the appropriate IP address. NCache will listen on this IP for all remote client requests.

NCache can also be configured to use separate NIC’s for each type of communication (using Dual NIC’s).

Once an NCache Service IP Binding has been changed, you should also make sure that all Remote Clients configured against this Cache Cluster should have their Client.ncconf (C:\Program Files\NCache\Config) file updated with the Cache Server IP address as follows.

For example, for a cache named DemoCache you need to specify the IP address of NIC dedicated for client-server communication in the Client.ncconf file on the Remote Client nodes (which is the same server IP address that you specified for the BindToClientServerIP tag above).

<cache id="DemoCache" client-cache-id="" client-cache-syncmode="optimistic" 
	default-readthru-provider="" default-writethru-provider="" 
<server name=""/>

What to Do Next?

Signup for monthly email newsletter to get latest updates.

© Copyright Alachisoft 2002 - . All rights reserved.