Collectors
The Moogsoft Collector is a distributable agent that collects metrics on Linux, Windows, and MacOS servers; detects metric anomalies directly at the source; and sends the anomalies and metrics to Moogsoft.
To install a collector, go to Data Config > Integrations > Moogsoft Collector and set up a service as described in the web UI.
For information about anomaly detection, see Customizing Anomaly Detection for Individual Metrics (Advanced).
You can use the Collectors API to do the following:
Create, retrieve, update and delete collectors.
Retrieve metric data from a collector.
Post metric data from a collector.
Retrieve the set of available metrics from a collector.
Before you begin
The Moogsoft Collector requires the following:
OS: Linux, Windows, or macOS
Internet access. See Outbound URLs accessed by the collector install script below.
Installed software: cURL (Required to download the installer)
Memory: 64Mb
CPU: 1
Disk space: 500 Mb
Network: 144Kbps
Windows collector -- notes
You must log in to the Windows server as Administrator before 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.
Log in to the Moogsoft web UI.
Go to Data Config > 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
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 on Linux or OS X, open a CLI and enter:
<collector_home>/collector/bin/collector start
To start all processes on Windows, open a command prompt and enter:
c:\Program Files\Moogsoft\collector\bin\collector.exe start
Hide the collector in the UI
This operation hides a collector in the UI.
Stop all collector processes as described in Stop the Collector.
In the web UI, go to Collectors, navigate to the collector of interest, and click Delete in the top-right corner.
This operation does not delete any collector files on the monitored host or associated collector data in the database. You can 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, complete the steps in Hide the collector in the UI above and then delete the <collector_home> directory.
Troubleshooting
The collector generates status and log messages in the following folders:
Linux/OS X —
moogsoft-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://base-url/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 only —
https://nodejs.org/dist/v10.16.3/node-v10.16.3-linux-armv7l.tar.gz
Windows —
https://nodejs.org/dist/v12.17.0/node-v12.17.0-win-x64.zip
OS X —
https://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
Watch how to Install a Data Collector in Moogsoft.