-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Windows service integration draft #16601
Changes from 1 commit
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
agentName: windows-service | ||
agentType: integration | ||
title: 'Windows service monitoring integration' | ||
metaDescription: 'Install the Windows service integration' | ||
introFilePath: 'src/install/windows-service/intro.mdx' | ||
appInfo: | ||
- optionType: dropdown1 | ||
label: '' | ||
placeholder: 'Select your environment' | ||
options: | ||
- value: 'windows' | ||
displayName: 'Windows' | ||
logo: 'windows' | ||
|
||
steps: | ||
- filePath: 'src/install/windows-service/install-infra.mdx' | ||
- filePath: 'src/install/windows-service/install-integration.mdx' | ||
- filePath: 'src/install/windows-service/configure-integration.mdx' | ||
whatsNextFilePath: 'src/install/windows-service/whatsNext.mdx' |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
--- | ||
componentType: appInfoConfig | ||
headingText: Choose your framework | ||
--- | ||
|
||
|
||
|
||
|
||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
--- | ||
componentType: default | ||
headingText: Configure the integration | ||
--- | ||
|
||
|
||
|
||
To enable the integration, edit and save the `winservices-config.yml`: | ||
|
||
* Uncomment `exporter_bind_address:` and `exporter_bind_port:` | ||
* Add the name of the services you want to monitor to `include_matching_entities:` | ||
|
||
By default, no service is included. To include and filter services, you must edit `include_matching_entities:`. | ||
|
||
Also, the configuration option [`inventory_source`](/docs/infrastructure/host-integrations/infrastructure-integrations-sdk/specifications/host-integrations-standard-configuration-format) is not compatible with the integration. | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. There is an anchor link for |
||
|
||
Here's an example of the Windows services integration configuration with both a regex pattern matching all services named `win32.*` and a direct match for the `newrelic-infra` service: | ||
|
||
<CollapserGroup> | ||
<Collapser | ||
id="example" | ||
title="winservices-config.yml" | ||
> | ||
```yml | ||
integrations: | ||
- name: nri-winservices | ||
config: | ||
exporter_bind_address: 127.0.0.1 | ||
exporter_bind_port: 9182 | ||
include_matching_entities: | ||
windowsService.name: | ||
- regex "win32.*" | ||
- "newrelic-infra" | ||
scrape_interval: 30s | ||
timeout: 60s | ||
``` | ||
|
||
For more information, see our documentation about the [general structure of on-host integration configurations](/docs/integrations/integrations-sdk/file-specifications/host-integration-configuration-overview). | ||
bradleycamacho marked this conversation as resolved.
Show resolved
Hide resolved
|
||
</Collapser> | ||
</CollapserGroup> |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
--- | ||
componentType: default | ||
headingText: Install the infrastructure agent | ||
--- | ||
|
||
To use the Apache Flink integration, you need to also [install the infrastructure agent](/docs/infrastructure/install-infrastructure-agent/get-started/install-infrastructure-agent-new-relic/) on the same host. The infrastructure agent monitors the host itself, while the integration you'll install in the next step extends your monitoring with specific data such as database and instance metrics. | ||
bradleycamacho marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
You must have <DoNotTranslate>**version 1.12.1 or higher**</DoNotTranslate> for our [infrastructure monitoring agent](/docs/infrastructure/install-infrastructure-agent/windows-installation/install-infrastructure-monitoring-agent-windows) installed on a supported host. The x86 Windows versions are not yet supported. | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The last sentence is passive. |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
--- | ||
componentType: default | ||
headingText: Install the Windows services integration | ||
--- | ||
|
||
To install the Windows services integration: | ||
|
||
1. Change the directory to the integrations folder: | ||
|
||
```shell | ||
cd C:\Program Files\New Relic\newrelic-infra\integrations.d\ | ||
``` | ||
|
||
2. Copy the sample configuration file: | ||
|
||
```shell | ||
copy winservices-config.yml.sample winservices-config.yml | ||
``` | ||
3. Edit the `winservices-config.yml` file as described in the [configuration settings](#config) and save it. | ||
bradleycamacho marked this conversation as resolved.
Show resolved
Hide resolved
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
--- | ||
headingText: Before we start | ||
componentType: default | ||
--- | ||
|
||
import infrastructureWindowsServicesMetric from 'images/infrastructure_screenshot-crop_windows-services-metric.webp' | ||
bradleycamacho marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
New Relic's Windows services integration collects data about the services running on your Microsoft Windows hosts and sends it to our platform. You can check the state and start mode of each service, find out which hosts are running a service, set up <InlinePopover type="alerts" /> for services, and more. | ||
|
||
<img | ||
title="New Relic - Windows services integration - Metric data" | ||
alt="New Relic - Windows services integration - Metric data" | ||
src={infrastructureWindowsServicesMetric} | ||
/> | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,108 @@ | ||
--- | ||
componentType: default | ||
headingText: Metrics collected by the integration | ||
--- | ||
|
||
|
||
## How it works [#process] | ||
|
||
To get data from Windows hosts, our Windows services integration uses a reduced version of the [Prometheus exporter for Windows](https://github.com/prometheus-community/windows_exporter), which exposes Prometheus metrics on the port specified in the agent configuration. The integration collects these metrics, transforms them into entities, filters them, and then sends them to New Relic. | ||
|
||
<img | ||
title="Windows services integration architecture" | ||
alt="Windows services integration architecture" | ||
src={infrastructureWindowsServices} | ||
/> | ||
|
||
<figcaption> | ||
The Windows services integration collects [Service Functions](https://docs.microsoft.com/en-us/windows/win32/services/service-functions) data using the Windows Prometheus exporter. It then transforms and filters the data before sending it to New Relic. | ||
</figcaption> | ||
|
||
## Metric data [#metrics] | ||
|
||
The Windows services integration provides the following data: | ||
|
||
<Callout variant="tip"> | ||
This integration creates dimensional metrics, which return the numeric status supplied by the [Win32_Service class](https://learn.microsoft.com/en-us/windows/win32/cimwin32prov/win32-service). Enumeration of these metrics into readable string values is provided under the `start_mode` and `state` attributes. | ||
</Callout> | ||
|
||
<table> | ||
<thead> | ||
<tr> | ||
<th> | ||
Metric Name | ||
</th> | ||
|
||
<th> | ||
Enumerated Attribute | ||
</th> | ||
|
||
<th> | ||
Description | ||
</th> | ||
</tr> | ||
</thead> | ||
|
||
<tbody> | ||
<tr> | ||
<td> | ||
`windows_service_start_mode` | ||
</td> | ||
|
||
<td> | ||
`start_mode` | ||
</td> | ||
|
||
<td> | ||
Start mode of the service. Possible values are: | ||
|
||
* `boot` | ||
* `system` | ||
* `auto` | ||
* `manual` | ||
* `disabled` | ||
</td> | ||
</tr> | ||
|
||
<tr> | ||
<td> | ||
`windows_service_state` | ||
</td> | ||
|
||
<td> | ||
`state` | ||
</td> | ||
|
||
<td> | ||
State of the service. Possible values are: | ||
|
||
* `stopped` | ||
* `start pending` | ||
* `stop pending` | ||
* `running` | ||
* `continue pending` | ||
* `pause pending` | ||
* `paused` | ||
* `unknown` | ||
</td> | ||
</tr> | ||
</tbody> | ||
</table> | ||
|
||
## Metadata [#metadata] | ||
|
||
The Windows services integration sends the following metadata to New Relic: | ||
|
||
* `display_name`: Name of the service as viewed in the services snap-in. | ||
* `process_id`: Process identifier of the service. | ||
* `run_as`: Account name under which a service runs. Depending on the service type, the format of the account name may be `DomainName\Username` or `Username@DomainName` (UPN). The value is taken from the `StartName` attribute of the `Win32_Service` class, which can be `NULL` (in that case, the label is reported as an empty string). | ||
* `service_name`: Unique identifier of the service. | ||
|
||
<Callout variant="important"> | ||
If the `StartName` attribute is `NULL`, the service is logged on under the `LocalSystem` account. For kernel or system-level drive, it runs with a default object name created by the I/O system based on the service name, for example, `DWDOM\Admin`. | ||
</Callout> | ||
|
||
## Source code [#open-source] | ||
|
||
The Windows services integration is open source software. That means you can [browse its source code](https://github.com/newrelic/nri-winservices/) and [send improvements](https://github.com/newrelic/nri-winservices/blob/master/CONTRIBUTING.md), or create your own fork and build it. For more information, see the [README](https://github.com/newrelic/nri-winservices/blob/master/README.md). | ||
|
||
bradleycamacho marked this conversation as resolved.
Show resolved
Hide resolved
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
no service is included
is passive.