OneAgent configuration via command-line interface
OneAgent v1.179
Use the oneagentctl
command-line interface to perform some post-installation OneAgent configuration at the individual host level.
The oneagentctl
tool is currently not available for OneAgent deployed as a container using volume-based storage.
The interface is available on Windows, Linux, and AIX. You need privileged access to use it (Windows administrator or Linux/AIX root). If you try to run oneagentctl
in a non-admin Windows console, Windows will display a User Account Control pop-up and fail.
The binary is located in:
Linux and AIX
/opt/desk/oneagent/agent/tools/oneagentctl
Windows
C:\Program Files (x86)\desk\oneagent\agent\tools\oneagentctl.exe
Host groups
You can use the oneagentctl
command-line interface to perform the following configuration actions for host groups.
Change host group assignment
Use --set-host-group
parameter to change the host group assignment.
Perform the following steps to assign the host to MyHostGroup
:
- Stop OneAgent. See specific instructions for Linux, Windows, and AIX.
- Go to
oneagentctl
directory. - Run the following command:
Linux and AIX
./oneagentctl --set-host-group MyHostGroup
Windows
.\oneagentctl.exe --set-host-group MyHostGroup
- Start OneAgent. See specific instructions for Linux, Windows, and AIX.
- Restart all the services monitored on the host.
Note: The host group string can only contain alphanumeric characters, hyphens, underscores, and periods. It must not start with dt.
and the maximum length is 100 characters.
Clear host group assignment
Use --set-host-group
parameter without a value to clear the host group assignment. For example:
Linux and AIX
./oneagentctl --set-host-group ""
Windows
.\oneagentctl.exe --set-host-group ""
Display host group assignment
Use --get-host-group
parameter to display the current host group assignment. For example:
Linux and AIX
./oneagentctl --get-host-group
Windows
.\oneagentctl.exe --get-host-group
For more information on host groups, see Organize your environment using host groups.
Display help
Use --help
to display all supported parameters.
Display OneAgent version
Use --version
to display OneAgent version.
Passing configuration parameters during installation
Since OneAgent version 1.177, you can pass the --set-*
parameters at the installation time. The configuration parameters are applied right before OneAgent service starts and there's no need to restart it to apply your configuration.
To pass through the configuration parameters, simply add the parameter and precede the value with the equals sign (=
). For example:
/bin/sh DESK-OneAgent-Linux.sh –-set-host-group=test_group
EXE installer
To pass the configuration parameters through using the EXE installer, simply add the parameter and precede the value with the equals sign (=
). For example:
DESK-OneAgent-Windows.exe –-set-host-group=test_group
MSI package
You can also pass the configuration parameters through using the MSI package. This time however, you must use an extra ADDITIONAL_CONFIGURATION
parameter. For example:
DESK-OneAgent-Windows.msi ADDITIONAL_CONFIGURATION="--set-host-group=test_group"