http://www.oracle.com/technetwork/java/javase/downloads/index.html
http://www.oracle.com/technetwork/java/javasebusiness/downloads/java-archive-downloads-javase6-419409.html
jdk-6u33-linux-i586.bin을 다운로드 했다
#>chmod 77 jdk-6u33-linux-i586.bin
#> ./jdk-6u33-linux-i586.bin
#>mv jdk1.6.0_33 /usr/local/jdk1.6.0_33
#> vi /etc/profile 을 열어서 아래 추가
export JAVA_HOME=/usr/local/jdk1.6.0_33
export PATH=$JAVA_HOME/bin:$PATH
톰캣 다운로드
http://tomcat.apache.org/
apache-tomcat-6.0.33.tar.gz 다운로드
압축풀고
tar -xvf apache-tomcat-6.0.33.tar.gz
톰캣 실행
/usr/local/apache-tomcat-6.0.33/bin/에가서./startup.sh 실행
방화벽설정 변경
#> vi /etc/sysconfig/iptables
-A INPUT -m state --state NEW -m tcp -p tcp --dport 8080 -j ACCEPT
동작 확인
http://서버IP:8080
톰캣 자동 실행 설정
#>vi /etc/rc.d/init.d/tomcat 파일 생성해서 아래대로 쓴다
#!/bin/sh
# Source function library.
. /etc/rc.d/init.d/functions
. /etc/rc.d/init.d/functions
source /etc/profile
export TOMCAT_HOME=/usr/local/apache-tomcat-6.0.33
# See how we were called.
case "$1" in
start)
echo -n "Starting tomcat EXPERIMENTAL: "
daemon $TOMCAT_HOME/bin/startup.sh
echo
;;
stop)
echo -n "Shutting down tomcat EXPERIMENTAL: "
daemon $TOMCAT_HOME/bin/shutdown.sh
echo
;;
restart)
$0 stop
$0 start
;;
*)
echo "Usage: $0 {start|stop|restart}"
exit 1
esac
exit 0
링크 걸기
# cd /etc/rc.d
# ln -s ../init.d/tomcat ./rc3.d/S90tomcat
# ln -s ../init.d/tomcat ./rc5.d/S90tomcat
# ln -s ../init.d/tomcat ./rc6.d/K90tomcat
# ln -s ../init.d/tomcat ./rc3.d/S90tomcat
# ln -s ../init.d/tomcat ./rc5.d/S90tomcat
# ln -s ../init.d/tomcat ./rc6.d/K90tomcat
Mysql설치 보기
톰캣 포트 변경 보기
댓글 없음:
댓글 쓰기