sudo yum install tomcat6-webapps tomcat6-admin-webapps
sudo service tomcat6 start
sudo service tomcat6 restart
sudo service tomcat6 stop
/etc/tomcat6 configuration files $CATALINA_HOME/conf
/usr/share/java/tomcat6 libraries $CATALINA_HOME/lib
/usr/share/tomcat6/bin executables $CATALINA_HOME/bin
/var/log/tomcat6 logs $CATALINA_HOME/logs
/var/cache/tomcat6/temp temporary files $CATALINA_HOME/temp
/var/lib/tomcat6 tomcat home directory $CATALINA_HOME
/var/lib/tomcat6/webapps web applications $CATALINA_HOME/webapps
/var/cache/tomcat6/work compiled servlets $CATALINA_HOME/work
설치후 테스트
웹브라우저 주소창에 다음과 같이 입력하고 엔터를 치면 Tomcat 초기화면을 확인할 수 있다.
http://IP-Address:8080<enter>
JSP 작성 및 테스트
/var/lib/tomcat6/webapps/ROOT/ 안에 간단한 JSP 파일을 작성하고 웹브라우저로 요청한다.
<%@page contentType="text/html;charset=euc-kr"%>
<html>
<head>
<title>hello world</title>
</head>
<body style="text-align:center; color:red;">
<% String msg = "Hello World"; %>
<%=msg%>
</body>
</html>