perforce / p4prometheus

[Community Supported] Perforce (Helix Core) interface for writing Prometheus metrics from real-time analysis of p4d log files.
MIT License
48 stars 24 forks source link

p4log_lc_last=0 problem #14

Closed Hokwang closed 1 year ago

Hokwang commented 4 years ago

Hello.

when I run $ ./monitor_metrics.sh -p ip:port -u perforce -nosdp command first time.

there's [p4log][curr timestamp: 1594364793][curr linecount: 78346601] sed: -e expression #1, char 11: invalid usage of line address 0

there's sed warning message.

I found https://unix.stackexchange.com/questions/107301/how-to-use-variables-in-sed link.

p4log_lc_last=1 is may be right.

One more thing, last line of monitor_metrics.sh can change 755 to 644 chmod 644 $metrics_root/*.prom

rcowham commented 4 years ago

Thanks - you're right!

rcowham commented 1 year ago

This logic was removed due to various problems.