How to monitor Fisheye Crucible using JMX in Linux

お困りですか?

アトラシアン コミュニティをご利用ください。

コミュニティに質問

目的

See real time operating data from your Fisheye/Crucible instance. For example, if you want to determine the number of repositories open in memory monitor the activeCount variable.

Other variables:

属性名

PassivationStats

名前 機能
activeCacheSize Current total size of the cache for all active repos
activeCount Total number of active (i.e. in-memory) runnable repositories
cacheUsage Fractional usage of the allocated cache
gcPassivations Total number of passivations due to GC load
maxActivePassivations Current count of passivations due to reaching the active limit
maxActiveRepos Maximum number of active repos allowed
maxCacheSize Max total heap size allocated to per-repo caches, in bytes
needingPassivationCacheSize Current total size of the cache for all close-wait repos
needingPassivationCount Total number of active (i.e. in-memory) repositories requiring passivation
perRepoCacheSize Current per-repo cache size setting in bytes
runnableCount Total number of repositories considered runnable

JMX とは何か

JMX (Java Management eXtensions) は、Java アプリケーションの監視と管理を行うためのテクノロジーです。JMX は MBean (Managed Bean) と呼ばれるオブジェクトを使用してアプリケーションのデータとリソースを公開します。


ソリューション

The JMX interface allows you to see live internal information from your Fisheye/Crucible instance, via the following MBean:

com.atlassian.fisheye.rep.PassivateMXBean

Enable JMX in Fisheye/Crucible

Add the following options to your FISHEYE_OPTS environment variable and restart Fisheye/Crucible:


-Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=8061 -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false -Djava.rmi.server.hostname=<FishEye server FQDN>

Using a JMX Client

You need to use a JMX client in order to view the JMX output from Confluence. JConsole is a readily available JMX client that is included with the supported Java Developer Kit (version 5 onwards).

  1. Open JConsole and select Remote Process
  2. Specify the hostname of server and the port that JMX is running on, ie. fisheyeserver.company.com:8061
  3. Click Connect
  4. When prompted, click the Insecure button


Adding live monitoring to a production instance may have an impact on performance.


Enable Jetty JMX MBeans

In case you want to extend the monitoring to Jetty and enable JMX for the Jetty MBeans it is possible to add one extra parameter to the FISHEYE_OPTS environment variable to enable that:

-Dfisheye.jetty.jmx.enable=true

The full content of the FISHEYE_OPTS in this case will be the following:

-Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=8061 -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false -Djava.rmi.server.hostname=<FishEye server FQDN> -Dfisheye.jetty.jmx.enable=true


If this option is enabled, at restart, Fisheye/Crucible will show the following extra log line:

2018-03-12 10:50:02,963 INFO  - System property fisheye.jetty.jmx.enable set to value: true



When enabled you will see extra MBean available in your JMX client. Below an example of the MBean available on VisualVM:




最終更新日 2018 年 11 月 2 日

この内容はお役に立ちましたか?

はい
いいえ
この記事についてのフィードバックを送信する
Powered by Confluence and Scroll Viewport.