Skip to content

Commit

Permalink
docs/Single-server-VictoriaMetrics.md: add a link to the original iss…
Browse files Browse the repository at this point in the history
…ue, which describes how to run VictoriaMetrics as Windows service

This is a follow-up for cc7d5b7

The original issue #3781 contains
up-to-date information on how to run VictoriaMetrics components as Windows service,
plus it may contain additional information about this case such as #3781 (comment) ,
so it is better to refer this issue from the docs.
  • Loading branch information
valyala committed Oct 15, 2023
1 parent 3594214 commit ddbe713
Show file tree
Hide file tree
Showing 3 changed files with 39 additions and 30 deletions.
23 changes: 13 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -214,8 +214,8 @@ After changes were made, trigger config re-read with the command `curl 127.0.0.1

### Running as Windows service

In order to run as a windows service it is required to create a service configuration for [WinSW](https://github.com/winsw/winsw)
and then install it as a service.
In order to run VictoriaMetrics as a Windows service it is required to create a service configuration for [WinSW](https://github.com/winsw/winsw)
and then install it as a service according to the following guide:

1. Create a service configuration:

Expand All @@ -225,23 +225,23 @@ and then install it as a service.
<name>VictoriaMetrics</name>
<description>VictoriaMetrics</description>
<executable>%BASE%\victoria-metrics-windows-amd64-prod.exe"</executable>

<onfailure action="restart" delay="10 sec"/>
<onfailure action="restart" delay="20 sec"/>

<resetfailure>1 hour</resetfailure>

<arguments>-envflag.enable</arguments>

<priority>Normal</priority>

<stoptimeout>15 sec</stoptimeout>

<stopparentprocessfirst>true</stopparentprocessfirst>
<startmode>Automatic</startmode>
<waithint>15 sec</waithint>
<sleeptime>1 sec</sleeptime>

<logpath>%BASE%\logs</logpath>
<log mode="roll">
<sizeThreshold>10240</sizeThreshold>
Expand All @@ -251,7 +251,7 @@ and then install it as a service.
<env name="loggerFormat" value="json" />
<env name="loggerOutput" value="stderr" />
<env name="promscrape_config" value="C:\Program Files\victoria-metrics\promscrape.yml" />

</service>
```

Expand All @@ -264,6 +264,9 @@ and then install it as a service.
Get-Service VictoriaMetrics | Start-Service
```

See [this issue](https://github.com/VictoriaMetrics/VictoriaMetrics/issues/3781) for more details.


## Prometheus setup

Add the following lines to Prometheus config file (it is usually located at `/etc/prometheus/prometheus.yml`) in order to send data to VictoriaMetrics:
Expand Down
23 changes: 13 additions & 10 deletions docs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -217,8 +217,8 @@ After changes were made, trigger config re-read with the command `curl 127.0.0.1

### Running as Windows service

In order to run as a windows service it is required to create a service configuration for [WinSW](https://github.com/winsw/winsw)
and then install it as a service.
In order to run VictoriaMetrics as a Windows service it is required to create a service configuration for [WinSW](https://github.com/winsw/winsw)
and then install it as a service according to the following guide:

1. Create a service configuration:

Expand All @@ -228,23 +228,23 @@ and then install it as a service.
<name>VictoriaMetrics</name>
<description>VictoriaMetrics</description>
<executable>%BASE%\victoria-metrics-windows-amd64-prod.exe"</executable>

<onfailure action="restart" delay="10 sec"/>
<onfailure action="restart" delay="20 sec"/>

<resetfailure>1 hour</resetfailure>

<arguments>-envflag.enable</arguments>

<priority>Normal</priority>

<stoptimeout>15 sec</stoptimeout>

<stopparentprocessfirst>true</stopparentprocessfirst>
<startmode>Automatic</startmode>
<waithint>15 sec</waithint>
<sleeptime>1 sec</sleeptime>

<logpath>%BASE%\logs</logpath>
<log mode="roll">
<sizeThreshold>10240</sizeThreshold>
Expand All @@ -254,7 +254,7 @@ and then install it as a service.
<env name="loggerFormat" value="json" />
<env name="loggerOutput" value="stderr" />
<env name="promscrape_config" value="C:\Program Files\victoria-metrics\promscrape.yml" />

</service>
```

Expand All @@ -267,6 +267,9 @@ and then install it as a service.
Get-Service VictoriaMetrics | Start-Service
```

See [this issue](https://github.com/VictoriaMetrics/VictoriaMetrics/issues/3781) for more details.


## Prometheus setup

Add the following lines to Prometheus config file (it is usually located at `/etc/prometheus/prometheus.yml`) in order to send data to VictoriaMetrics:
Expand Down
23 changes: 13 additions & 10 deletions docs/Single-server-VictoriaMetrics.md
Original file line number Diff line number Diff line change
Expand Up @@ -225,8 +225,8 @@ After changes were made, trigger config re-read with the command `curl 127.0.0.1

### Running as Windows service

In order to run as a windows service it is required to create a service configuration for [WinSW](https://github.com/winsw/winsw)
and then install it as a service.
In order to run VictoriaMetrics as a Windows service it is required to create a service configuration for [WinSW](https://github.com/winsw/winsw)
and then install it as a service according to the following guide:

1. Create a service configuration:

Expand All @@ -236,23 +236,23 @@ and then install it as a service.
<name>VictoriaMetrics</name>
<description>VictoriaMetrics</description>
<executable>%BASE%\victoria-metrics-windows-amd64-prod.exe"</executable>

<onfailure action="restart" delay="10 sec"/>
<onfailure action="restart" delay="20 sec"/>

<resetfailure>1 hour</resetfailure>

<arguments>-envflag.enable</arguments>

<priority>Normal</priority>

<stoptimeout>15 sec</stoptimeout>

<stopparentprocessfirst>true</stopparentprocessfirst>
<startmode>Automatic</startmode>
<waithint>15 sec</waithint>
<sleeptime>1 sec</sleeptime>

<logpath>%BASE%\logs</logpath>
<log mode="roll">
<sizeThreshold>10240</sizeThreshold>
Expand All @@ -262,7 +262,7 @@ and then install it as a service.
<env name="loggerFormat" value="json" />
<env name="loggerOutput" value="stderr" />
<env name="promscrape_config" value="C:\Program Files\victoria-metrics\promscrape.yml" />

</service>
```

Expand All @@ -275,6 +275,9 @@ and then install it as a service.
Get-Service VictoriaMetrics | Start-Service
```

See [this issue](https://github.com/VictoriaMetrics/VictoriaMetrics/issues/3781) for more details.


## Prometheus setup

Add the following lines to Prometheus config file (it is usually located at `/etc/prometheus/prometheus.yml`) in order to send data to VictoriaMetrics:
Expand Down

0 comments on commit ddbe713

Please sign in to comment.