Ich habe Probleme mit sensu-plugins-Java. Ich habe Plugin in unserem Server installiert und ich muss check-java-heap-pcnt.rb verwenden, um die Heap-Größe in unserem Server zu überwachen, aber es zeigt keine korrekte Ausgabe, wenn ich versuche, die Prüfung lokal auszuführen. Hier ist, wie ich versucht, die Kontrolle lokal auszuführen:Sensu check für jvm Heap funktioniert nicht
# ./check-java-heap-pcnt.rb -n java -w 70 -c 85 -j /usr/java/defaults/bin/ -p
Hier ist die Ausgabe, die es erzeugt:
invalid argument count
Usage: jstat -help|-options
jstat -<option> [-t] [-h<lines>] <vmid> [<interval> [<count>]]
Definitions:
<option> An option reported by the -options option
<vmid> Virtual Machine Identifier. A vmid takes the following form:
<lvmid>[@<hostname>[:<port>]]
Where <lvmid> is the local vm identifier for the target
Java virtual machine, typically a process id; <hostname>is
the name of the host running the target Java virtual machine;
and <port> is the port number for the rmiregistry on the
target host. See the jvmstat documentation for a more complete
description of the Virtual Machine Identifier.
<lines> Number of samples between header lines.
<interval> Sampling interval. The following forms are allowed:
<n>["ms"|"s"]
Where <n> is an integer and the suffix specifies the units as
milliseconds("ms") or seconds("s"). The default units are "ms".
<count> Number of samples to take before terminating.
-J<flag> Pass <flag> directly to the runtime system.
(standard_in) 1: syntax error
MEM UNKNOWN -
Welche Version von Jstat haben Sie installiert? – jaxxstorm
@Frap Danke für die Antwort. Mit Jstat-Version meinst du die Java-Version? Wenn das der Fall ist, variiert meine aktuelle Java-Version von 1.8.0_25 bis 1.8.0_111. –