Download PDF
Download page Smart Agent Command Line Utility.
Smart Agent Command Line Utility
The AppDynamics Smart Agent command line utility (CLI) is a standalone service that is capable of managing nodes on remote or local hosts. You can install the Smart Agent CLI independently to manage any supported agents. This utility is helpful during the buildtime workflow.
Supported platforms
You can use the Smart Agent command line utility on any of the following platforms:
- RedHat-based Linux
- Debian-based Linux
Use Command Line Utility
This is syntax of the command that you can use to perform agent operations by using the Smart Agent CLI:
appd { operation } { agent } --{ options }
You can use this syntax for APM agents and Smart Agents.
APM Agents
To manage the app server agents and Machine Agents, the following are the supported values that you can use in the CLI command from the Smart Agent CLI utility:
Parameters | Values | Details |
---|---|---|
operation |
| You can perform install, upgrade, rollback, and uninstall operations using the CLI command. |
agent |
| These are the supported agents on which you can perform the operations using the CLI command. |
options | Agent options
| These are the available flag options for the operation on APM agents. The flag options are categorized into the following:
|
Connection options
| ||
Install options
| ||
Config options
|
For example: To install Java Agent 23.9.0, run the following command on the Smart Agent CLI:
appd install java --version 23.9.0
Smart Agent CLI Option-Operation Grid
Operation | Install | Upgrade | Uninstall | Rollback |
---|---|---|---|---|
Flags options | version string (latest) ( -v ) profile string (default) ( -p ) config string ( -c ) install-dir string ( -d ) app-name string ( -a ) node-name string ( -n ) tier-name string ( -t ) inventory string ( -i ) connection string ( -q ) hosts string ( -m ) instal-agent-from string ( -l ) | version string (latest) ( -v ) profile string (default) ( -p ) config string ( -c ) install-dir string ( -d ) app-name string ( -a ) node-name string ( -n ) tier-name string ( -t ) inventory string ( -i ) connection string ( -q ) hosts string ( -m ) instal-agent-from string ( -l ) | backup bool ( -b ) inventory string ( -i ) connection string ( -q ) hosts string ( -m ) | inventory string ( -i ) connection string ( -q ) hosts string ( -m ) |
Smart Agents
To manage the Smart Agents, the following are the supported values that you can use in the CLI command from the Smart Agent CLI utility:
Arguments | Values | Details |
---|---|---|
operation |
| You can perform install, upgrade, rollback, and uninstall operations using the CLI command. |
agent |
| The Smart Agent on which you can perform the operations using the CLI command. |
options | Agent options
| These are the available flag options for the operation on APM agents. The flag options are categorized into the following:
|
Download options
| ||
Connection options
| ||
Install options
| ||
Config options
| ||
Smartagent options
|
For example:
appd install smartagent --install-agent-from {path_to_local_artifact} --auto-start
Smart Agent CLI Option-Operation Grid
Operation | Install | Upgrade | Uninstall | Configure |
---|---|---|---|---|
Flags options | version string (latest) ( -v ) profile string (default) ( -p ) config string ( -c ) inventory string ( -i ) connection string ( -q ) hosts string ( -m ) instal-agent-from string ( -l ) | version string (latest) ( -v ) profile string (default) ( -p ) config string ( -c ) inventory string ( -i ) connection string ( -q ) hosts string ( -m ) instal-agent-from string ( -l ) | inventory string ( -i ) connection string ( -q ) hosts string ( -m ) | inventory string ( -i ) connection string ( -q ) hosts string ( -m ) attach-configure-file string ( -f ) |
Default Values for Smart Agent CLI Utility Flag Options
Option | Default Value |
---|---|
version string (latest) ( -v ) profile string (default) ( -p ) config string ( -c ) install-dir string ( -d ) app-name string ( -a ) node-name string ( -n ) tier-name string ( -t ) inventory string ( -i ) connection string ( -q ) hosts string ( -m ) install-agent-from string ( -l ) backup string ( -l ) attach-configure-file string ( -f ) | latest default /opt/appdynamics/appdcli/config.ini "" "" "" "" "" local all "" false "" |
Examples Scenarios
Install Java on Local Machine with Default Values
appd install java
Install Java, Node and Machine Agents into the Local Machine or Container with Custom Configuration
You can add these commands in your Dockerfile, Terraform scripts or any CI/CD scripts (local artifact for machine):
appd install java --config /tmp/config.ini --app-name demo-java-app --tier-name demo-java-tier
appd install node -c /tmp/config.ini --app-name demo-node-app --node-name demo-node-name
appd install machine -c /tmp/config.ini --app-name demo-machine-app --install-agent-from /vagrant/appdynamics-machine-agent-23.9.10.zip
Install Machine Agent to Multiple Hosts in the hosts File
You can run the following command for the mass install of agents on any number of hosts with a single command:
appd install machine -c /tmp/config.ini --inventory ./hosts --connection ssh --app-name demo-machine-app
Install Smart Agent on Host Machines
When Smart Agent is installed on the host machine, the smartagent
service autostarts and is controlled by a flag. You can onboard smart agent to multiple hosts:
appd install smartagent --install-agent-from /vagrant/appdsmartagent_23.10.0-964_amd64.deb -c ./config.ini -i ./hosts -q ssh --auto-start