변군이글루

[scouter] Scouter 설치 - 2 본문

프___기타

[scouter] Scouter 설치 - 2

변군 변군이글루 2017.03.17 17:27

2. Scouter Host Agent
uter 다운로드(https://github.com/scouter-project/scouter/releases)

[root@web01 app]# tar xvfz scouter.agent.tar.gz

[root@web01 app]# chown -R tomcat.tomcat /app/scouter

[root@web01 ~]# su - tomcat

[tomcat@web01 ~]$ vi .bashrc
---
## JAVA_HOME
export JAVA_HOME="/app/java"
export PATH="$PATH:$JAVA_HOME/bin"
---

[tomcat@web01 ~]$ cd /app/scouter/agent.host/conf

[tomcat@web01 conf]$ vi scouter.conf
---
# Scouter Server IP Address (Default : 127.0.0.1)
net_collector_ip=10.1.5.215
---

[tomcat@web01 conf]$ cd ..

[tomcat@web01 agent.host]$ ./host.sh
nohup: redirecting stderr to stdout
  ____                  _           
 / ___|  ___ ___  _   _| |_ ___ _ __
 \___ \ / __/   \| | | | __/ _ \ '__|
  ___) | (_| (+) | |_| | ||  __/ |  
 |____/ \___\___/ \__,_|\__\___|_|                                     
 Open Source S/W Performance Monitoring 
 Scouter version 0.4.22 20170114
 
Configure -Dscouter.config=./conf/scouter.conf
Scouter Host Agent Version 0.4.22 20170114
System JRE version : 1.8.0_111

3. Scouter Tomcat Agent

[tomcat@web01 ~]$ vi .bashrc
---
## JAVA_HOME
export JAVA_HOME="/app/java"
export PATH="$PATH:$JAVA_HOME/bin"

## SCOUTER_AGENT
SCOUTER_AGENT_DIR=/app/scouter/agent.java
export SCOUTER_AGENT_DIR
---

[tomcat@web01 ~]$ cd /app/scouter/agent.java/

[tomcat@web01 agent.java]$ cat was11.conf
# Scouter Server IP Address (Default : 127.0.0.1)
net_collector_ip=10.1.5.215

# Scouter Server Port (Default : 6100)
net_collector_udp_port=6100
net_collector_tcp_port=6100

# Scouter Name(Default : tomcat1)
obj_name=was11

[tomcat@web01 ~]$ vi /app/was01/bin/catalina.sh
---
280 fi
281
282 # ----- Execute The Requested Command -----------------------------------------
283 JAVA_OPTS="$JAVA_OPTS -javaagent:${SCOUTER_AGENT_DIR}/scouter.agent.jar -Dscouter.config=${SCOUTER_AGENT_DIR}/was11.conf"
284 CATALINA_PID=$CATALINA_HOME/logs/.tomcat_pid
285
286 # Bugzilla 37848: only output this if we have a TTY
---

[tomcat@web01 ~]$ cd /app/was01/bin/

[tomcat@web01 bin]$ ./startup.sh
Using CATALINA_BASE:   /app/was01
Using CATALINA_HOME:   /app/was01
Using CATALINA_TMPDIR: /app/was01/temp
Using JRE_HOME:        /app/java
Using CLASSPATH:       /app/was01/bin/bootstrap.jar:/app/was01/bin/tomcat-juli.jar
Using CATALINA_PID:    /app/was01/logs/.tomcat_pid
Tomcat started.

[tomcat@web01 bin]$ ps -ef | grep was01 | grep scouter     
tomcat 12184     1 35 17:20 pts/0    00:00:11 /app/java/bin/java -Djava.util.logging.config.file=/app/was01/conf/logging.properties -Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager -server -Xms2g -Xmx2g -XX:MaxPermSize=512m -Dfile.encoding=UTF-8 -Djdk.tls.client.protocols=TLSv1,TLSv1.1,TLSv1.2 -Dhttps.protocols=TLSv1,TLSv1.1,TLSv1.2 -Ddeployment.security.TLSv1=true -Ddeployment.security.TLSv1.1=true -Ddeployment.security.TLSv1.2=true -Dsun.security.ssl.allowUnsafeRenegotiation=false -Djava.net.preferIPv4Stack=true -Djdk.tls.ephemeralDHKeySize=2048 -Djava.protocol.handler.pkgs=org.apache.catalina.webresources -javaagent:/app/scouter/agent.javascouter.agent.jar -Dscouter.config=/app/scouter/agent.java/was11.conf -Djava.endorsed.dirs=/app/was01/endorsed -classpath /app/was01/bin/bootstrap.jar:/app/was01/bin/tomcat-juli.jar -Dcatalina.base=/app/was01 -Dcatalina.home=/app/was01 -Djava.io.tmpdir=/app/was01/temp org.apache.catalina.startup.Bootstrap start

참고 ULI : https://github.com/scouter-project/scouter/blob/master/scouter.document/main/Setup_kr.md

 

0 Comments
댓글쓰기 폼