mirror of
https://github.com/prometheus-community/windows_exporter
synced 2025-02-16 12:07:13 +00:00
readme & text changes
Signed-off-by: Dinifarb <andreas.vogt89@bluewin.ch>
This commit is contained in:
parent
0ec4e9d90f
commit
9473265ffa
@ -64,7 +64,7 @@ type textFileCollector struct {
|
||||
func newTextFileCollectorFlags(app *kingpin.Application) {
|
||||
textFileDirectory = app.Flag(
|
||||
FlagTextFileDirectory,
|
||||
"Directory or Directories to read text files with metrics from.",
|
||||
"DEPRECATED: Use --collector.textfile.directories",
|
||||
).Default("").String()
|
||||
textFileDirectories = app.Flag(
|
||||
FlagTextFileDirectories,
|
||||
|
@ -10,15 +10,25 @@ Enabled by default? | Yes
|
||||
|
||||
## Flags
|
||||
|
||||
### `--collector.textfile.directory`
|
||||
### `--collector.textfile.directory`
|
||||
:warning: DEPRECATED Use `--collector.textfile.directories`
|
||||
|
||||
The directory containing the files to be ingested. Only files with the extension `.prom` are read. The `.prom` file must end with an empty line feed to work properly.
|
||||
<br>
|
||||
|
||||
### `--collector.textfile.directories`
|
||||
One or multiple directories containing the files to be ingested.
|
||||
|
||||
E.G. `--collector.textfile.directories="C:\MyDir1,C:\MyDir2"`
|
||||
|
||||
Default value: `C:\Program Files\windows_exporter\textfile_inputs`
|
||||
|
||||
Required: No
|
||||
|
||||
## Metrics
|
||||
> **Note:**
|
||||
> - If there are duplicated filenames among the directories, only the first one found will be read. For any other files with the same name, the `windows_textfile_scrape_error` metric will be set to 1 and a error message will be logged.
|
||||
> - Only files with the extension `.prom` are read. The `.prom` file must end with an empty line feed to work properly.
|
||||
|
||||
|
||||
|
||||
Metrics will primarily come from the files on disk. The below listed metrics
|
||||
are collected to give information about the reading of the metrics themselves.
|
||||
@ -38,7 +48,7 @@ _This collector does not yet have any useful queries added, we would appreciate
|
||||
_This collector does not yet have alerting examples, we would appreciate your help adding them!_
|
||||
|
||||
# Example use
|
||||
This Powershell script, when run in the `collector.textfile.directory` (default `C:\Program Files\windows_exporter\textfile_inputs`), generates a valid `.prom` file that should successfully ingested by windows_exporter.
|
||||
This Powershell script, when run in the `--collector.textfile.directories` (default `C:\Program Files\windows_exporter\textfile_inputs`), generates a valid `.prom` file that should successfully ingested by windows_exporter.
|
||||
|
||||
```Powershell
|
||||
$alpha = 42
|
||||
|
Loading…
Reference in New Issue
Block a user