Collectors

Express includes a distributable agent that collects metrics on Linux, Windows, and MacOS servers; detects metric anomalies; and sends the anomalies and metrics to Express.

To install a collector, go to Integrations > Moogsoft Collector and set up a service as described in the web UI.

For information about anomaly detection, see

Before you begin

The Linux Server collector requires the following:

Windows collector -- notes

  • You should be logged in to the Windows server as Administrator when you install the collector.

  • The Windows collector installs as an application rather than as a service. This means that you must restart the collector manually if the server gets rebooted.

  • The Windows collector does not upgrade itself automatically. If an upgrade is available, the collector adds a log entry. To upgrade the collector, run the following command as Administrator:

    collector.exe upgrade

Install the collector

Note

Moogsoft recommends that you install the collector while logged in as root or sudo on Linux or OS X, or as Administrator on Windows.

  1. Log in to the Express web UI.

  2. Go to Integrations > Moogsoft Collector, follow the instructions, and run the specified script on the host of interest.

The collector, once installed, immediately starts collecting metrics, detecting anomalies, and sending data to the server.

Collector operations

The default home directory for the collector is /opt/moogsoft. All collector binaries, logs, and related files are installed under this directory. If the installer cannot install into /opt,  it installs the collector files in your user home directory. This generally happens only when you install as a non-root/non-sudo user (not recommended). To install in a different directory, specify the target in a $MOOGSOFT_HOME environment variable on the collector host.

Stop the collector

To stop the collector in the web UI, go to Collectors and navigate to the Collector of interest. Then click the Running status button in the top-right corner. This toggles the collector state to Stopped.

Stopping a collector in the UI stops data collection but does not stop all collector-related processes.

  • To stop all processes on Linux or OS X, open a CLI and enter:

    <collector_home>/collector/bin/collector stop
  • To stop all processes on Windows, open a command prompt and enter:

    c:\Program Files\Moogsoft\collector\bin\collector.exe stop

Restart the collector

To start the collector in the web UI, go to Collectors and navigate to the collector of interest. Then click the Stopped status button in the top-right corner. To restart the collector in a CLI window, enter the following:

  • To start the collector on Linux or OS X, open a CLI and enter:

    <collector_home>/collector/bin/collector start
  • To stop all processes on Windows, open a command prompt and enter:

    c:\Program Files\Moogsoft\collector\bin\collector.exe start

Remove the collector from the UI

This operation hides the collector in the UI. It does not delete any collector files on the monitored host or associated collector data in the database.

  1. Stop all collector processes as described in Stop the collector.

  2. In the web UI, go to Collectors, navigate to the collector of interest, and click Delete in the top-right corner.

Once the collector is removed, you can then restart the collector from the CLI and it will reappear in the UI.

Delete the collector on the monitored host

To delete all collector files on the host, do the steps in Remove the collector from the UI above and then delete the <collector_home> directory.

Note

The Delete Collector operation simply removes references to that collector in the UI. It does not delete any data from that collector in the Express database. It also does not delete any files on the collector host.

Troubleshooting

The collector generates status and log messages in the following folders:

  • Linux/OS Xmoogsoft-home/collector/bin/logs/

  • Windows%LOCALAPPDATA%\moogsoft\collector\logs

Outbound URLs accessed by the collector install script

The collector install script requires outbound access to the following URLs:

  • The script downloads and installs Moogsoft collector files from:

    https://instance-name.moogsoft.qa/express/v1/collectors

  • If the server does not have NodeJS installed, the script downloads and installs from the following URLs, depending on the platform:

    • Linux (all platforms)https://nodejs.org/dist/v10.16.3/node-v10.16.3-linux-x64.tar.gz

    • Linux ARM onlyhttps://nodejs.org/dist/v10.16.3/node-v10.16.3-linux-armv7l.tar.gz

    • Windowshttps://nodejs.org/dist/v12.17.0/node-v12.17.0-win-x64.zip

    • OS Xhttps://nodejs.org/dist/v10.16.3/node-v10.16.3-darwin-x64.tar.gz

  • The script might also access the following npm packages:

    • https://www.npmjs.com/package/systeminformation

    • https://www.npmjs.com/package/mongodb

    • https://www.npmjs.com/package/aws-sdk