Getting Started with NCache Professional Edition
NCache Professional edition provides a Windows Installer Package (.msi) to let you easily install NCache. However, before you install NCache, you need to keep the following in mind.
Installation Options
NCache Professional edition provides the following installation options:
Cache Server (.NET Framework only)
This installs both server and client portion of NCache software. You must install this on 2 or more servers for reliability. These can be dedicated servers or your web/app servers. For 3 or more web/app server environments, we recommend a dedicated caching tier. In this case, we recommend a 4:1 or 5:1 ratio between web/app servers and cache servers.
If you’re installing NCache server on your web/app servers, then make sure you have sufficient memory and CPU power available for both your application and NCache.
Remote Client
This installs the remote client libraries. Install this on all your web/app servers from where you want to remotely access the cache servers. Do not install it on cache servers.
Developer (.NET Framework only)
This installs the NCache API, online help/documentation, and a local stand-alone cache without any clustering capability.
Note the following limitations for Developer Installation Type while connecting to remote caches:
Throttling of 100 requests/sec for each client: All such clients that are licensed under DEV license will not be able to make more than 100 requests/sec to the remote cache.
Limited number of requests (200,000) a client can send to remote cache: In a lifetime of client application in case it is licensed under DEV license, the client will stop making requests to remote cache after it has sent 200,000 requests to remote cache. The only work around is to restart application for another 200,000 requests. Once the client has made 200,000 requests, a licensing exception will be thrown saying “Clients running under DEV license cannot send more than 200,000 requests to remote cache.”
Note
Developer licensed clients can make requests to local caches without any limitation.
Where to Install NCache?
You need to install NCache in the following environments:
- Production
- Staging
- QA
- DEV
Production environment is where your LIVE application runs. Staging is usually identical or very similar to production and contains the "next" version of your application and is used for final stress testing and client/manager approvals before going LIVE.
QA environment is often separate from DEV and is used by QA team to test your application. DEV environment is where your application is initially developed, unit tested, and integration tested. Many times, DEV environment is also used as QA environment and there is no separate QA environment.
System Requirements
8 or More Cores
NCache is a highly multi-threaded software and takes full advantage of extra cores. The most common configuration for NCache is 8 cores or higher. You may need stronger processing power if you have higher transaction loads and/or larger amount of data being stored in NCache.1G-bit or Faster Network Card (NICs)
This improves your throughput greatly.Disk
NCache does not make heavy use of disk space for data so you don’t need a lot of it.8GB or Higher RAM (16+ GB Recommended)
NCache puts a minimum of 15% overhead on top of your data which can be even as high as 100% if you have extensively used indexing. Please keep this in mind while deciding how much memory to have in your cache servers. The total memory you need depends on how much data you plan to store in cache and how much of it is indexed.Windows Server 64-bit (2008 R2, 2012 R2, 2016, 2019)
Please try to use the latest version of Windows Server if possible..NET Framework 4.7.2 or Higher (Cache Server)
.NET Framework 4.0 or Higher (Remote Client)
- .NET Core 3.0
Configure PowerShell
NCache provides integration with PowerShell to easily automate its administrative processes. Moreover, NCache remote tasks can also be managed over the network through a single machine using PowerShell cmdlets.
Compatible Version
NCache PowerShell Provider is only compatible with PowerShell version 4.0 and above.
Enable Script Execution
If you wish to create and execute PowerShell scripts using NCache cmdlets:
Search for PowerShell on Windows Start menu. Right click on the search result “PowerShell”, and select Run as Administrator.
Set script execution policy to
RemoteSigned
to allow remote execution:
Set-ExecutionPolicy RemoteSigned
Configure WinRM Listener
To execute remote PowerShell commands, Windows Remote Management (WinRM) needs to be configured. This is because PowerShell remoting requires Windows Services Management (WS-Management) protocol which is implemented by WinRM. To learn how to install and configure WinRM, head over to this Microsoft documentation.
Visual C++ 2010 x64 Redistributable
NCache installation requires Microsoft Visual C++ 2010 x64 Redistributable as a pre-requisite. This may or may not be installed on your system. But, just to be sure, please go through these steps to ensure that it is installed on all “cache server” and “remote client” machines/VMs/Containers.
Search for PowerShell on Windows Start menu. Right click on the search result “PowerShell”, and select Run as Administrator.
And, then copy/paste the following PowerShell script to this PowerShell window to run.
# PowerShell Script: to install Microsoft Visual C++ 2010 x64 Redistributable
if ([Environment]::Is64BitOperatingSystem)
{
Write-Host "64-Bit OS Detected"
$regEntry = Test-Path Registry::HKLM\SOFTWARE\\Classes\\Installer\\Products\\1926E8D15D0BCE53481466615F760A7F
$url = "https://download.microsoft.com/download/3/2/2/3224B87F-CFA0-4E70-BDA3-3DE650EFEBA5/vcredist_x64.exe"
$vcRed = "vcredist_x64.exe"
# Checking if vcredist_x64 is installed on this machine
if ($regEntry -eq 0)
{
# If no installation found download visual c++ redistributable
write-host "Microsoft Visual C++ 2010 x64 Redistributable NOT Found"
write-host "Downloading from $url"
$vcredistPath = "$ENV:temp\$vcRed"
(New-Object System.Net.WebClient).DownloadFile($url, $vcredistPath)
write-host "Download Complete"
# Installing vcredist_x64
write-host "Installing Microsoft Visual C++ 2010 x64 Redistributable"
start-process -Wait $vcredistPath -ArgumentList "/norestart /q"
write-host "Installation Complete"
}
else
{
write-host "Microsoft Visual C++ 2010 x64 Redistributable is already installed."
}
}
$regEntry = Test-Path Registry::HKLM\\SOFTWARE\\Classes\\Installer\\Products\\1D5E3C0FEDA1E123187686FED06E995A
$url = "https://download.microsoft.com/download/5/B/C/5BC5DBB3-652D-4DCE-B14A-475AB85EEF6E/vcredist_x86.exe"
$vcRed = "vcredist_x32.exe"
# Checking if vcredist_x32 is installed on this machine
if ($regEntry -eq 0)
{
# If no installation found download visual c++ redistributable
write-host "Microsoft Visual C++ 2010 x32 Redistributable NOT Found"
write-host "Downloading from $url"
$vcredistPath = "$ENV:temp\$vcRed"
(New-Object System.Net.WebClient).DownloadFile($url, $vcredistPath)
write-host "Download Complete"
# Installing vcredist_x32
write-host "Installing Microsoft Visual C++ 2010 x32 Redistributable"
start-process -Wait $vcredistPath -ArgumentList "/norestart /q"
write-host "Installation Complete"
}
else
{
write-host "Microsoft Visual C++ 2010 x32 Redistributable is already installed."
}
See Also
Windows Installation
Command Line Installation
Network Installation with PowerShell
License Management