The SilkEssential package required for SSH monitoring (SSH.sep) uses an executable called "Plink.exe".  This executable is used to create secure sessions with the SSH daemon running on the server being monitored.

It has been found that for every measure polled during the monitoring process the "plink" executable is executed.  This in turn causes a new login process to be initiated for each measure and can therefore result in high CPU utilization when adding multiple data sources.

To overcome this problem a modified SilkEssential package (SSH.sep) has been created.  To use this file you should copy the attached file to the "\Working\Monitors" folder. The Default location of the "monitors folder" is:

C:\Program Files\silk\SilkPerformer 2011\Monitors

The changes made to the modified SSH.sep file are as follows:

If the current command equals the last command then the last results are reused.
So the performance will only be improve if you group equal commands, e.g.:
Command1 vmstat 1 2 | tail -1
Command2 vmstat 1 2 | tail -1
Command3 vmstat 1 2 | tail -1

The performance will not change if you use the following:
Command1 vmstat 1 2 | tail -1
Command2 ps -ef | egrep -c \".*\"
Command3 vmstat 1 2 | tail -1

The original SSH.sep executed plink.exe for each command, the modified one only for each new command.

After opening the new .sep file, the following lines of code which should be added in the function SshExecute between
hProcess := ProcessInitialize("cmd.exe", PROCESS_ATTACHED, "/C "+ gsSnap, gsDir, gsOut, gsErr, 0);
and ProcessStart(hProcess);

FOpen(hFile, gsDir+"dummy_in.txt", OPT_FILE_ACCESS_READWRITE, OPT_FILE_CREATE);
FClose(hFile);
ProcessSetStdInFile(hProcess, gsDir + "dummy_in.txt");

The final result should be:
    hProcess := ProcessInitialize("cmd.exe", PROCESS_ATTACHED, "/C "+ gsSnap, gsDir, gsOut, gsErr, 0);
   
    FOpen(hFile, gsDir+"dummy_in.txt", OPT_FILE_ACCESS_READWRITE, OPT_FILE_CREATE);
    FClose(hFile);
    ProcessSetStdInFile(hProcess, gsDir + "dummy_in.txt");
   
    ProcessStart(hProcess);


Failure to include this modification results in the following error during TryScript:

Process Exit RepMessage RT: 14 - Custom Message, Return code: 0, Error: Unable to read from standard input: the handle is invalid.
Virtual user stopped *** Severe API error (SEVERITY_PROCESS_EXIT)