zoukankan      html  css  js  c++  java
  • 笔记:JMX Configuration

    1.Setup forTomcat


    (1). Add the necessary parameters to Tomcat startup script:

    In Windows, modifythe file "${CATALINA_BASE}incatalina.bat",add thesearguments for JVM before the comment “rem ----Execute The RequestedCommand ------”:

    setJAVA_OPTS=-Dcom.sun.management.jmxremote

    -Dcom.sun.management.jmxremote.port=${Your JMX Port} 

    -Dcom.sun.management.jmxremote.authenticate=true  

    -Dcom.sun.management.jmxremote.ssl=false   

    -Dcom.sun.management.jmxremote.access.file=mxremote.access  

    -Dcom.sun.management.jmxremote.password.file=jmxremote.password 

    In Linux, modify the file "${CATALINA_BASE}/bin/catalina.sh",add thesearguments for JVM before the comment “# ----Execute The RequestedCommand ------”:

    JAVA_OPTS=”$JAVA_OPTS -Dcom.sun.management.jmxremote  

    -Dcom.sun.management.jmxremote.port=${ Your JMX Port}  

    -Dcom.sun.management.jmxremote.authenticate=true     

    -Dcom.sun.management.jmxremote.ssl=false    

    -Dcom.sun.management.jmxremote.access.file=jmxremote.access   

    -Dcom.sun.management.jmxremote.password.file=jmxremote.password

    (2). Edit the access authorizationfile jmxremote.access:

    monitorRole readonly

    controlRole readwrite

    Edit the passwordfile jmxremote.password:

    monitorRole yourpassword

    controlRole yourpassword

    These two files should be read-only and only accessible by theoperating system user Tomcat is running as. In Linux, run the command:

    chmod 600jmxremote.access,

    chmod 600jmxremote.password


    2.Setup forGlassfish


    (1). The default port for JMX is 8686.If you want tochange it,modify the node  "jmx-connector " of file ${GlassFish_Home}/domains/${Domain_Name}/config/domain.xml.

    (2).The username and password for JMXare the same as the web console.


    3.Setup forWebLogic


    (1). Enable and configure the IIOPprotocol:

    In the Change Center of theAdministration Console, click Lock & Edit.

    In the left pane of the Console,expand Environment and select Servers.

    Select the Protocols tab, thenselect IIOP.

    Select the Enable IIOP check boxto enable the IIOP protocol.

    To modify the defaultconfiguration, click Advanced.

    In the Default IIOP User field,enter a user name.

    In Default IIOP Password, enter apassword.

    Modify default values for theother attributes.

    To activate these changes, in theChange Center of the Administration Console, click ActivateChanges.

    (2). The port for JMX is the sameas the web console, and the default value is7001.


    4. Setup forJBoss


     (1). The default port for JMX is1090. If you want to change it, modify the file "${JBoss_Home}/server/default/conf/bindingservice.beans/META-INF/bindings-jboss-beans.xml" .

    (2). Enable authorization.

    Modify the file " ${JBoss_Home}/server/default/deploy/jmx-jboss-beans.xml" , find the bean "JMXConnector", uncomment itsnode:

     jmx-console

    Modify the file"${JBoss_Home}/server/default/conf/props/jmx-console-roles.properties" to configure the role of JMX.

    admin=JBossAdmin,HttpInvoker

    Modify the file "${JBoss_Home}/server/default/conf/props/jmx-console-users.properties" to configure the username and password of JMX.

    admin=yourpassword

    (3). Configure the DNS:

    Modify file “/etc/hosts” of the host toadd the target IP and hostname.  Forexample, if the IP of JBoss is "10.1.2.16"and the target hostname is “SH-JMX-TEST”, add this line to“/etc/hosts”:

    10.1.2.16   SH-JMX-TEST

    (4)

    For JBoss 4,5,6, copy ${JBoss_Home}/lib/jboss-bootstrap-api.jarto classpath

    For JBoss 7.0, we do not need copyjars.

    For JBoss 7.1, copy ${JBoss_Home}/bin/client/jboss-client.jarto classpath

    (5)  StartJBoss:

    ${JBoss_Home}/bin/run.sh  -b 0.0.0.0 

    or

    ${JBoss_Home}/bin/run.sh  -b  ${Binding IP}


    5. Setup forWebSphere


    (1). Thedefault port forJMX is 8880.Ifyou want to change it, modify the node "Applicationservers>${ServerName}>Ports>SOAP_CONNECTOR_ADDRESS"of web console.

    The username and password of JMX is thesame as web console.

    (2). Copy necessary client jarstothe path classpath including:

     ${WebSphere_Home}/AppServer/runtimes/com.ibm.ws.admin.client.jar

    ${WebSphere_Home}/AppServer/plugins/com.ibm.ws.security.crypto.jar 

    (3). Copy necessary SSL filesto the file path  

    ${WebSphere_Home}/AppServer/profiles/${Profile_Name}/etc/DummyClientKeyFile.jks

    ${WebSphere_Home}/AppServer/profiles/${Profile_Name}/etc/DummyClientTrustFile.jks 

    (4). Install IBM JDK (1.6 or higher version

  • 相关阅读:
    Centos7.2 下搭建LNMP环境(终极版)Yum安装
    ThinkPHP3.2 插入数据库数据,缓存问题
    无限极分类的JS实现
    PHP 商城无限极分类
    高速下载Centos的地址
    高性能的城市定位API接口
    阿帕奇配置本地虚拟站点,XAMPP环境下
    Nginx 下配置Laravel 错误404
    laravel Redis缓存
    pytest.1.快速开始
  • 原文地址:https://www.cnblogs.com/leeeee/p/7276603.html
Copyright © 2011-2022 走看看