Administering the host agent on UNIX

After you install the host agent, configure and manage the agent as you require. See the following list for all the available agent configuration options on UNIX.

For more information about the host agent configuration, see Host agent configuration.

Checking the status of the host agent

After installing the host agent, you can check the status on the Agents dashboard in the Instana UI. To display the Agents dashboard, click More > Agents from the navigation menu on the Instana UI.

To find a host agent in a list of host agents, you can use the search bar with a simple string like Windows, or the fully qualified domain name (FQDN) of the host, or more complex strings that use a query syntax. For more information, click (?) in the search bar, or see the topic Filter with Dynamic Focus.

To check the status of the host agent on UNIX, run the following command:

<instana-agent-dir>/bin/status

Customizing the agent configuration

After you install the host agent, the following configuration files are created:

/opt/instana/agent/etc/mvn-settings.xml
/opt/instana/agent/etc/org.ops4j.pax.url.mvn.cfg
/opt/instana/agent/etc/instana/com.instana.agent.bootstrap.AgentBootstrap.cfg
/opt/instana/agent/etc/instana/com.instana.agent.main.config.Agent.cfg
/opt/instana/agent/etc/instana/com.instana.agent.main.config.UpdateManager.cfg
/opt/instana/agent/etc/instana/com.instana.agent.main.sender.Backend.cfg
/opt/instana/agent/etc/instana/configuration.yaml

You can customize the configuration of the agent as you need. For example, you can change the TCP port and hostname of the Instana backend and services that your host agent connects to, configure the agent to report to multiple backends, or configure a proxy for indirect communication from the host agent to the Instana backend.

For more information about customizing the agent configuration, see the following topics:

Starting, stopping, and updating the agent

See the following sections to learn how to start, stop, and update the host agent on UNIX:

Starting the agent

When you install the host agent, it is enabled to start automatically at system boot. You can turn off this behavior by setting the environment variable INSTANA_AGENT_AUTOSTART=false when you install the agent.

  • To start the host agent, run the following command:
<instana-agent-dir>/bin/start

Stopping the agent

To stop the agent, run the following command:

<instana-agent-dir>/bin/stop

Updating the agent

Before you update the host agent, take copies of the following existing agent configuration files. You can add these files to the upgraded agent files to retain your existing configurations.

  • /instana/com.instana.agent.main.config.Agent.cfg
  • /instana/com.instana.agent.bootstrap.AgentBootstrap.cfg
  • /instana/com.instana.agent.main.config.UpdateManager.cfg
  • /instana/configuration.yaml
  • /instana/bin/setenv

To update the host agent on UNIX, complete the following steps:

  1. In the Instana UI, click Deploy Agent.

  2. Click the tile UNIX.

  3. Select the packaging option to install a dynamic or static agent.

  4. In the dropdown menu, select your platform architecture.

  5. Click the download link to download the latest version of the host agent.

  6. Stop the existing agent by running the following command:

    <instana-agent-dir>/bin/stop
    
  7. Delete the existing agent package directory.

  8. Extract the new package that you downloaded from the Instana UI.

  9. Copy your agent configuration files to the new package directory to retain your configurations.

  10. Start the agent by running the following command:

    <instana-agent-dir>/bin/start
    

The agent is updated to the latest version.

Managing agents by using the Agent Management dashboard

You can complete the following operations by using the Agent Management dashboard in the Instana UI:

To open the Agent Management dashboard, complete the following steps:

  1. In the sidebar of the Instana UI, select Infrastructure. Alternatively, in the host overview, under Instana Agent, click the agent.
  2. Click a specific monitored host.
  3. On the host dashboard, click Open Agent Management.

Setting and overriding environment variables

You can set or override environment variables for the Instana agent on UNIX by using the setenv file.

In the <instana-agent-dir>/bin/ folder, open the setenv file. Add the required environment variables to the end of the file in the following format and save the file:

EXPORT <variable_name>="<value>"

The contents of the setenv files are overwritten when you update the agent. To retain your environment variables, make sure to save a copy of the setenv file before you start the update process.

Deleting temporary files

The Instana host agent installs some files that it needs in the /tmp/.instana/ directory. If those files are deleted over the uptime of the host, it can cause issues during updates.