How to set up Windows GDMA drive letter detection

REDIRECT: This URL has changed to https://support8.gwos.com/gw/gw8/latest/how-to-s/how-to-set-up-windows-gdma-drive-letter-detection
Click the link above if you are not automatically redirected in 10 seconds.

Auto-Setup detects the configuration of systems and automates service creation through a variety of means, and sets up the GDMA client to monitor that configuration. It's done at the host level, so while your auto-setup "instructions" can be the same for all hosts, every host can be configured and monitored differently. You can "trigger" auto-setup to update the configuration whenever you like, so you can get very close to fully automated monitoring.

This How To reviews how to set up Windows hosts to use auto-setup to detect the drive letters on your systems to monitor. Some prerequisites and notes before you get started:

  • GroundWork Monitor 8.0.0 or greater, see Installation
  • GDMA 2.7.1 or greater, see Downloads
  • All command line actions need to be performed as the user in which GroundWork was installed, this is any user in the docker group that can execute the docker command, for example the installation procedure uses gwos. It is important to keep in mind any interaction with the Docker containers should not be performed as root.
  • For this How To we use the GroundWork server phobos.gwostechlab.com, Perl, and will monitor the system demo-winapps1.gwosdemo.local (a Windows system with multiple disks).
  • Please adjust your configuration according to your setup, and keep in mind GDMA requires DNS resolution and time synchronization in order to properly function. 

Steps

  1. Download the package and run the file:

    • This includes everything you need: Profiles (base host profile, base service profile, base disk profile), the Instructions and Trigger files for GDMA Auto-Setup, and a wrapper script to help you automate the setup process.

      NameSizeCreatorCreation DateComment
      gdma-auto-windows-disk.tgz6.6kBJ. Byers09/19/2020MD5: e18f770bd6cf2b1d1c82432fd104e81b
    • Then, enter the following command which will create the autosetup directory with the files needed to implement this tip:

      tar zxvf gdma-auto-windows-disk.tgz
  2. Change to the autosetup directory and import the files:

    • You do not have to use -validate, but it does give you detail and tells you whether or not the instructions passed validation.

      cd autosetup/
      
      chmod +x auto_wrapper.pl
      
      ./auto_wrapper.pl -import -directory ./ -validate
  3. Import the profiles:
    • In GroundWork Monitor, import the profiles in the Uploaded folder by selecting Configuration > Nagios Monitoring > Profiles > Profile Importer > Import > Uploaded. Click Check all, and select the Import button.
  4. Edit the hosts.txt file:
    • This file should contain a list of hosts, one host per line. This file can have a single host or as many hosts as you like. Make sure that the hostname you use is in DNS, using the fully qualified domain name is best practice. For this tip, we are only including Windows hosts with more than 1 disk.
  5. Install the automation instructions for your hosts:

    • Enter the following:

      ./auto_wrapper.pl -install winpattern -hosts ./hosts.txt
      
    • Optionally, you can check to make sure the installation succeeded with the following command, where each host will be listed with a timestamp of when the install and trigger files were last installed:

       ./auto_wrapper.pl -status
  6. Install GDMA on a Windows system:
    This example works best on a system with at least two drive letters. Let's say you have drives C: and Q: on your Windows system. When you install GDMA, several options need to be established for Auto-Setup to run and for Auto-Registration not to run. You will need to indicate the following responses to the installer (the rest are up to your system preferences):
    • Autoregistration user name: gdma
    • Autoregistration password: gdma
    • Auto Configuration: Auto Setup
    • GDMA service start: Yes
    • Unattended Mode:
      • Since you're at this point, you're probably trying to automate everything possible. GDMA has capability to use unattended mode and an options file during installation, and this is great to use for this scenario. The configuration (options.txt) we use for auto-configuration is attached: options.txt

      • Then we run this using the following:

        groundworkagent-2.7.1-116-windows-installer.exe --optionfile options.txt
      • This way it silently installs, starts the agent, and pulls configuration from GDMA Auto-Setup without much work, but this is a matter of preference.

  7. Commit:
    • In GroundWork Monitor, run a Configuration > Nagios Monitoring > Control > Commit operation to instantiate the services. 
  8. Viewing hosts an services:
    • Then, in Dashboards > Status you should see your new hosts and services along with performance graph data populated for the new disk checks. Some services may remain in a pending state for up to 10 minutes.
      • gdma_wmi_cpu
      • gdma_wmi_disk_  (this will expand on a Commit operation to have service instances for C: and Q: in our case, your system may be different)
      • gdma_wmi_disktransfers
      • gdma_wmi_mem
      • gdma_wmi_memory_pages
      • gdma_wmi_uptime

Evaluating detection results

You can review and manage detection results centrally with a few commands. The autosetup status will tell you when instructions and triggers were added for a host, and if that host has checked in (GDMA agent started), you can see results and analysis of what was detected and added.

To get general status use:

./auto_wrapper.pl -status

This will output the timestamps of instructions and triggers, but more importantly for this purpose, when the last analysis and results were posted. It looks something like this:

ubuntu@phobos:~/demo_auto/autosetup$ ./auto_wrapper.pl -status
instructions     trigger          results          analysis         hostname
===============  ===============  ===============  ===============  ========================================
Sep 21 08:58:54  Sep 21 08:58:55  Sep 21 09:02:20  Sep 21 09:02:20  ad-demo.gwosdemo.local
Sep 21 08:58:54  Sep 21 08:58:55  Sep 21 09:07:46  Sep 21 09:07:47  demo-winapps1.gwosdemo.local

A "- - -" status indicates that we haven't completed a task, in this example, all tasks have been completed.

If you want to see the results of a task, you can print a result or an analysis. Results give us what was found, and is useful should an unexpected result be received that led to an error. Analysis gives us what was found and what was done with it, including any errors in discovery. For example, on demo-winapps01, we can see the following discovery results using:

Print detection results:

./auto_wrapper.pl -results -hosts hosts.txt

Print analysis results, this shows what was added to monitoring:

./auto_wrapper.pl -analysis -hosts hosts.txt