Machine Agents Installer on Windows

Overview

This document provides steps for silent and automated installation of Cavisson agents on the Windows platform.

This includes the following agents:

  1. Machine agent
  2. Log agent
  3. App agent

It contains prerequisites and the steps that need to be performed before the installation.

Platform Support

#

OS Version

DotNet Version

Processor bit

1

Windows Server 2008

4

32 bit

2

Window Server 2008

4

64 bit

3

Window Server 2008

4.5

32 bit

4

Window Server 2008

4.5

64 bit

5

Window Server 2012

4/4.5

32/64 bit

6

Window Server 2016

4/4.5

32/64 bit

Note: Silent installer also supports all other versions later to 2012.

Prerequisites

For Silent Mode

  1. PowerShell runtime environment is required to execute the script. The PowerShell version should be later than or equal to 5.
  2. Administrator might have disabled the script execution. To allow the script to run, open PowerShell as administrator and run the command: Set-ExecutionPolicy UnRestricted.
  3. PowerShell may temporarily block execution of scripts downloaded from the internet. To unblock, the following has to be done on the machine from where the installer will run.
  4. Right-click on the install.ps1 script and click Properties. From there, click Unblock.
  5. Open PowerShell as administrator and navigate to the directory containing the script. Run the command unblock-file ./install.ps1 to unblock it.

For GUI Mode

  1. Admin permission is also required for the installation via GUI mode.

Additional Prerequisites for Remote Installation

  1. WinRM (Windows remote) services should be running on the server.
  2. Inbound Rule should enable the server for WinRM Service from where the installer is running.
  3. List of trusted remote servers should be added in configuration of WinRM Client on the machine from where the installer will run.

Installation in Silent Mode

Silent Mode installation can be done either from the targeted server or remotely. User needs to create a hostfile.txt containing Username, Password and Hostname of the servers if installing remotely.

  1. Create the CavissonAgentInstaller folder in <C:\Program Files (x86)\> . User can create somewhere else as per his choice.
  2. Download Cavisson-Agent-Installer.*.zip file using Cavisson repository in <C:\Program Files (x86)\
  3. Extract it into the folder <C:\Proer>gram Files (x86)\CavissonAgentInstaller>.
  4. Open PowerShell on your system with administrative privilege.
  5. Navigate to the extracted directory <C:\Program Files (x86)\CavissonAgentInstaller>.
  6. Create hostfile.txt under <C:\Program Files (x86)\CavissonAgentInstaller> with the following format if installing remotely.

Username1:Password1:Hostname1
Username2:Password2:Hostname2
Username3:Password3:Hostname3

  1. Run .\install.ps1 with required agent and its related args. Below parameters are supported in the script, you can pass with .\install.ps1.

Note: The folder needs to be copied at an appropriate place or select the folder during installation that does not have spaces in the file path.

Usage

Silent Mode Installation with All arguments

.\install.ps1 -installedPath “Provide installation dir Default <C:\Program Files (x86)\opt\cavisson\>” -appAgent “Provide Install Mode Install/Skip <1/0>” -machineAgent “Provide Install Mode Install/Skip <1/0>”> -logAgent “Provide Install Mode Install/Skip <1/0>” -tier “Provide Tier Name” -instance “Provide Instance Name” -poolName “Provide Pool Name <pool1,pool2>” -remoteinstall “Flag to enable remote install <0/1>” -dest “Provide Destination Folder <C:\Users\Administrator\Downloads>” -controller “Provide Cavisson server <hostname:443>” -protocol “Provide Protocol-Default: WSS” -msi “Provide msi name”-nfIndexPrefix “Provide Index Prefix” -nfServer “Provide Log Server <hostname:443>” -nfEnv “Provide Setup-name like Prod” -nfReloadPort “Provide ND Reload Port” -logFile “Log File Name” -server “Provide Server Name-Default: Hostname” -username “Provide Usernme to run Machine Agent with different user” -password “Provide password of above User” -installVCRuntime “Provide Flag to install bundled visual c++ runtime” -iisreset “Provide Flag to reset the IIS” -hostfile “Provide host file”

Note: All parameters are optional and if not provided on the command line are picked from the bundled configuration file in binary.

Case1: Silent mode installation from targeted server

.\install.ps1 -tier “Provide Tier Name” -controller “Provide Cavisson server <hostname:443>”

Case2: Silent mode installation on a targeted server remotely

.\install.ps1 -tier “Provide Tier Name” -controller “Provide Cavisson server <hostname:443>” -remoteinstall “Flag to enable remote install <1>” -hostfile “Provide host file”

Case 3: Install only Machine Agent and App Agent

.\install.ps1 -appAgent 1 -machineAgent 1 -tier “Provide Tier Name”  -controller “Provide Cavisson server <hostname:443>” -nfIndexPrefix “Provide Index Prefix” -nfServer “Provide Log Server <hostname:443>” -poolName “Provide Pool Name <pool1,pool2>”

Note: Create hostfile.txt and use -hostfile “Provide host file” and -remoteinstall “Flag to enable remote install <0/1>”  args if installing remotely.

Case 4: Install only Machine Agent, App Agent and Log Agent

.\install.ps1 -appAgent 1 -machineAgent 1 -logAgent 1 -tier “Provide Tier Name” -controller “Provide Cavisson server <hostname:443>” -nfIndexPrefix “Provide Index Prefix” -nfServer “Provide Log Server <hostname:443>” -poolName “Provide Pool Name <pool1,pool2>” -nfEnv “Provide Setup-name like Prod” -nfReloadPort “Provide ND Reload Port” -logFile “Log File Name”.

Note: Create hostfile.txt and use -hostfile “Provide host file” and -remoteinstall “Flag to enable remote install <1>” args if installing remotely.

Installation in GUI Mode

  1. Download the provided Agent MSI file.

Example: Cavisson-Agent-Installer.4.5.0.77.x64.4.5.zip

  1. Unzip the MSI by right-clicking on the MSI zip file and select Extract All.
2. Unzip the MSI by right-clicking on the MSI zip file and select Extract All.
  1. After extracting the MSI, open the folder and get the MSI file.
  2. Execute the MSI by double-clicking on the MSI file (Cavisson-Agent-Installer.4.5.0.77.msi). The Welcome page is displayed.
  1. Click Next, the License Agreement window is displayed. Select the terms and conditions and click Next.
  1. Click Next, the Installation Path is displayed.
  1. Click Next, the Common Properties window is displayed.

8. Click Next, the following window is displayed where you can enable SaaS features.

9. If you select the SaaS check box, the following window is displayed.

10. If you do not select the SaaS check box (in Step – 8), the Agent(s) Selector window is displayed.

11. Click Next, the following window is displayed where you can select the Machine Agent

12. Click Next, the User Authentication window is displayed.

13. Click Next, the ApplicationAgent Entries window is displayed.

14. Click Next, the AppPoolEntries window is displayed.

15. Click Next, the AppPoolEntries window is displayed.

16. Click Next, the Agents are ready to install.

17. Click Install, the agents get installed.

Directory Structure after Installation

Services

You can see the running services in the Services tab.

Appendix – 1: Steps to Add Trusted Hosts in WinRM Client Configuration

  1. Open the run prompt and type msc.
  2. Navigate to Local Computer Policy > Computer Configuration > Administrative Templates > Windows Components > Windows Remote Management (WinRM) > WinRM Client.
  3. Enable Trust the remote machine. On the settings window, add the remote server name in the trustedhostedlist
  4. Use * to trust all remote hosts.

Appendix – 2: Additional Details for Silent Mode Installation

List of Parameters Supported In Silent Installation

#

NAME

TYPE

DEFAULT

MANDATORY

DESCRIPTION

1

Tier

String

None

Yes

Name to be given to a cluster of application servers running same application services

2

Controller

String

Empty

No

Cavisson Server to which Application and Machine agents will be posting the captured data. Input format is <hostname:port>

3

Instance

String

Empty

No

Instance Name

4

Protocol

String

WSS

Yes

Communication Protocol to be used. Default is WSS.

Possible values

WSS,WS,TCP.

5

Msi

String

AUTO

No

MSI Name, It picks up automatically from

present working

directory.

6

appAgent

Int

0

No

Flag to install appagent

7

machineAgent

Int

1

No

Flag to install machine Agent

8

Logagent

Int

1

No

Flag to install NF Log agent

9

poolName

String

ALL Pools

No

List of comma separated pool names if want to restrict application instrumentation to specific IIS Pools. Default is ALL

10

nfIndexPrefix

String

Empty

No

NF Index Prefix – Use when nfAgent is enabled.

Prefix string that will be prefixed to all log indices managed by Log server
Syntax: <prefix>_<env>_<tier>-<currentDate>

Example: cav_stage_payment-2020-04-12

11

nfServer

String

Same as controller

No

NFServer host/IP. Default it is same as frontend controller

12

nfEnv

String

Empty

No

NF Environment name

Eg: Dev/LLE/Stress/Prod

13

logFile

String

agent-install.log

No

Log filename(installation logs would be appended to this file)

14

remoteinstall

int

Empty

No

Flag to enable remote installation

15

Dest

String

Empty

Yes

Only when upgrading remotely (-remoteinstall is enabled). Related files are copied to remote host at this path. Default is C:\Users\Administrator\DownloadsDOTNET_WIN-G45LG581T0C_StockTraderWebAppPool.txt

 

16

Copy

Int

1

No

Useful when files are present in the remote directory. This saves time copying the executables.

17

installVCRuntime

Int

1

No

Flag to install bundled visual c++ runtime.

When to update the vc version?

18

Username

String

None

No

For running Machine Agent under different user other than local system

19

Password

String

None

No

Password for specified username

20

Iisreset

Int

0

No

Flag to reset the IIS

21

hostfile

String

None

No

User:Password:Host entries with multiple lines in a file if

upgrading on multiple

remote servers.

22

Uninstall

Switch

False

No

Switch/Flag to uninstall agents. This switch can be used with other options such as –

logAgent, appAgent, –

machineAgent to

remove specific

products.

23

Upgrade

Switch

False

No

Switch/Flag to upgrade agents. This switch can be used with other options such as -logAgent, -appAgent, -machineAgent to upgrade specific products.

24

Partialuninstall

switch

False

No

Switch/Flag to uninstall specific agents. This switch can be used with other options such as -logAgent, -appAgent, -machineAgent to remove specific products.

25

Ndproxy

string

empty

No

“Provide Gateway Server(Required for App Agent) <Gateway Server:port>”

Adding Keywords for SaaS Feature in Silent Mode Installation

#

NAME

TYPE

DEFAULT

MANDATORY

DESCRIPTION

1

Saas

String

None

No

For installing SaaS feature along with agents: 0/1

2

projectkey

String

None

Yes/No

In case of sass feature it will be mandatory

otherwise not. Get it from Cavisson team.

3

url

String

None

No

Cavisson SaaS URL where all Monitored data is

present.

4

tierattributes

String

None

No

Keyword for tierattributes. Default is Default.

5

appname

String

None

No

Keyword for appname. Default is Default

Note: When the SaaS feature is enabled, the project key is a mandatory field and the controller is optional.