You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -546,20 +543,14 @@ Check that metrics are being written:
546
543
547
544
grep lines /hxlogs/metrics/p4_cmds.prom
548
545
546
+
## Install p4metrics and monitor_locks systemd timer service
549
547
550
-
## Install monitor metrics cron jobs
551
-
552
-
Download the following files (or use [Automated Script Installation](#automated-script-installation)):
553
-
554
-
*[monitor_metrics.sh](scripts/monitor_metrics.sh) or for use with wget, download raw file: [*right click this link > copy link address*](https://raw.githubusercontent.com/perforce/p4prometheus/master/scripts/monitor_metrics.sh)
555
-
*[monitor_wrapper.sh](scripts/monitor_wrapper.sh) or for use with wget, download raw file: [*right click this link > copy link address*](https://raw.githubusercontent.com/perforce/p4prometheus/master/scripts/monitor_wrapper.sh)
556
-
*[monitor_metrics.py](scripts/monitor_metrics.py) or for use with wget, download raw file: [*right click this link > copy link address*](https://raw.githubusercontent.com/perforce/p4prometheus/master/scripts/monitor_metrics.py)
548
+
Use [Automated Script Installation](#automated-script-installation)!!
557
549
558
-
There is a convenience script to keep things up-to-date in future:
550
+
Check out: [install_p4metrics function in installer script for details](https://github.com/perforce/p4prometheus/blob/master/scripts/install_p4prom.sh#L361)
559
551
560
-
*[check_for_updates.sh](scripts/check_for_updates.sh) or for use with wget, download raw file: [*right click this link > copy link address*](https://raw.githubusercontent.com/perforce/p4prometheus/master/scripts/check_for_updates.sh). It relies on the `jq` utility to parse GitHub and update the above scripts if new releases have been made.
561
-
562
-
Configure them for your metrics directory (e.g. `/hxlogs/metrics`)
552
+
Note that `p4metrics` has now replaced `monitor_metrics.sh` - the latter is retained as an example, but should
553
+
not be installed!
563
554
564
555
Please note that `monitor_metrics.py` (which is called by `monitor_wrapper.sh`) runs `lslocks` and
565
556
cross references locks found with `p4 monitor show` output. This is incredibly useful for
@@ -568,16 +559,8 @@ if you are not collecting the data at the time!
568
559
569
560
Warning: make sure that `lslocks` is installed on your Linux distribution!
570
561
571
-
Install in crontab (for user `perforce` or `$OSUSER`) to run every minute:
Or if not using SDP, copy the [monitor_metrics.sh script](scripts/monitor_metrics.sh) to an appropriate place such as `/usr/local/bin` and install it in your crontab.
Check that appropriate files are listed in your metrics dir (and are being updated every minute), e.g.
805
792
806
-
ls -l /hxlogs/metrics
793
+
ls -ltr /hxlogs/metrics/
807
794
808
795
## node exporter
809
796
@@ -875,21 +862,13 @@ and see what the output is.
875
862
876
863
The executable takes the `--config` parameter and the yaml file is same format as for Linux version. You can specify paths with forward slashes if desired, e.g. `c:/p4/metrics`
877
864
878
-
## Running monitor_metrics.sh
879
-
880
-
Download [Git Bash](https://gitforwindows.org/) and install.
881
-
882
-
Edit `monitor_metrics.sh` and adjust path settings, e.g. `/p4/metrics` -> `/c/p4/metrics`
883
-
884
-
Test the script with your installation (analyse it's settings). First make sure your admin user is logged in.
When it is working and writing metric files to your defined metrics directory, then create a .BAT wrapper, e.g. `run_monitor_metrics.bat` with something like the following contents (adjusted for your local settings):
867
+
Edit `p4metrics.yaml`and adjust path settings, e.g. `/p4/metrics` -> `/c/p4/metrics`
0 commit comments