This article describes how to bind multiple SSL certificates to various virtual servers (SSL) on NetScaler using CLI.
Background
In some cases, e.g. a hard drive failure, a crash or a failover may cause the virtual servers (SSL) have no certificates bound. In this situation they will not process any traffic until proper and corresponding certificates binding is in place.
The certificates may or may not exist in the /nsconfig/ssl directory of the Citrix NetScaler appliance, which is the recommended location for the certificate-key pairs.
Certificates can be bound using NetScaler GUI, however it may be easier to bind a larger amount of certificates to various virtual servers from the CLI.
To add, link and bind the SSL certificates to virtual servers, complete the following steps:
Step 1: SSH to the NetScaler, e.g. using PuTTY.
Step 2: Check if the certificate and key pairs are located in /nsconfig/ssl/ (recommended folder):
shell
ls -l /nsconfig/ssl/
If the certificates and keys are not located in /nsconfig/ssl/, copy them to this folder, e.g. using WinSCP
If the certificates and keys are located in /nsconfig/ssl/
a) From the running configuration list the commands that add, link and bind the certificates to virtual servers:
show run | grep -i certKey
b) Select all the commands in PuTTY to copy them to clipboard
c) Right-click in the prompt to paste and run them
Step 3: Verify if the certificates have been bound to the virtual servers.