서버는 아파치웹서버 2.2.4와 mod_jk/1.2.20 커넥터로 JSP,서블릿을 처리하는 아파치톰캣에 연결되어 있군요. 현재 메시지는 톰캣 서버가 내려가 있는 상태.
댓글 영역 서버가 memo.news.naver.com 이군요.
제 사이트의 코멘트들도 memo라고 명명했었는데.
잘 되시길 바랍니다.
![사용자 삽입 이미지](https://t1.daumcdn.net/tistoryfile/fs2/6_9_17_13_blog12234_attach_0_0.png?original)
Ip Allow and Deny
인트로
Introduction
배치자는, 이름이 의미하듯이, 톰캣 서버에 웹 애플리케이션을, 정적으로(서버가 기동하기 전에 설치된 애플리케이션) 또는 동적으로 (톰캣 매니저 웹 애플리케이션이나 이미 배치된 애플리케이션들과 연계하여), 배치하거나 제거하는 역할을 합니다.
The deployer, which as its name imply, allows deploying and undeploying web applications to the Tomcat server, either statically (the application is setup before the server is started), or dynamically (in conjunction with the Tomcat Manager web application or manipulating already deployed applications).
컨텍스트 기술서
Context descriptors
컨텍스트 XML 기술서는 XML 데이터 조각입니다. 메인서버 설정 파일(conf/server.xml)에서 정상적으로 보여질 수 있는 유효한 컨텍스트 엘리먼트를 포함합니다. 그리고 이것은 톰캣에서 다양한 관리 도구를 통해서 쉽게 자동화된 조작이 가능합니다. 호스트에서 컨텍스트 기술서의 위치는 $CATALINA_HOME/conf/[enginename]/[hostname]/foo.xml 입니다. 주의할 것은 파일의 이름은 웹 애플리케이션 이름에 맞지 않아도 되지만, 톰캣이 컨텍스트 기술서를 생성하게 되면 컨텍스트 기술서의 이름은 웹 애플리케이션과 동일하게 맞춰집니다.
A Context XML descriptor is a fragment of XML data which contains a valid Context element which would normally be found in the main server configuration file (conf/server.xml), and allows easy and automated manipulation of web applications by the various management tools available in Tomcat. For a given host, the Context descriptors are located in $CATALINA_HOME/conf/[enginename]/[hostname]/foo.xml. Note that while the name of the file is not tied to the webapp name, Tomcat will create Context descriptors which match the webapp name whenever it will generate a Context descriptor.
컨텍스트 기술서는 컨텍스트의 모든 환경설정 파라미터의 정의가 가능합니다. 예를 들면 네이밍 자원과 세션 매니저 설정같은 것이죠. 또 한 가지 말하자면, 컨텍스트 엘리먼트에 있는 docBase 값은 .WAR 파일을 참조하거나 .WAR파일의 압축이 풀려진 디렉토리를 지정할 수 있습니다.
Context descriptors allow defining all aspects and configuration parameters of a Context, such as namign resources and session manager configuration. It should be noted that the docBase specified in the Context element can refer to either the .WAR or the directory which will be created when the .WAR is expanded or the .WAR itself.
from: http://tomcat.apache.org/tomcat-5.0-doc/deployer-howto.html
운영중인 톰캣에 배치
Deploying on a running Tomcat server
만약 host의 "autoDeploy" 프로퍼티가 true이면, 호스트는 필요할 때마다 동적으로 웹 애플리케이션을 배치 또는 업데이트하려고 시도합니다. host는 자동 리로딩 작업에 필요한 백그라운드 처리가 필요할 것인데, 기본적으로 설정되어 있습니다.
If the host "autoDeploy" property is true, the host will attempt to deploy and update web applications dynamically, as needed. The host will need to have background processing enabled for automatic reloading to work, which is the default.
다음을 포함합니다:
주의: 웹 애플리케이션 리로딩은 로더에서 설정될 수 있고, 그런 경우 로드된 클래스는 변경에 대해서 추적됩니다.
This includes:
Deployment of WARs which are copied to the host appBase.
Deployment of expanded web applications which are copied to the host appBase.
Redeployment of a web application which has been deployed from a WAR when the WAR is updated: the expanded web application is removed, and the WAR is expanded again. This will not happen if the host is configured so that WARs are not expanded, in which case the webapp will be simply redeployed.
Redeployment of the web application if the /WEB-INF/web.xml file is updated.
Redeployment of the web application if the context XML file from which the web application has been deployed is updated.
Redeployment of the web application if a context XML file (with a name corresponding to the context path of the previously deployed application) is added in the $CATALINA_HOME/conf/[enginename]/[hostname]/ folder.
Note: Web application reloading can also be configured in the loader, in which case loaded classes will be tracked for changes.
from: http://tomcat.apache.org/tomcat-5.0-doc/deployer-howto.html
클라이언트 디플로이어 패키지를 사용해서 디플로이하기
Deploying using the Client Deployer Package
번역 translated by kenu_AT_okjsp.pe.kr
클라이언트 디플로이어는 운영이나 개발 서버에 웹 애플리케이션을 검증, 컴파일, 배치시킬 수 있는 패키지입니다. 이 기능은 자동 배치를 위해서 톰캣 매니저를 사용한다는 것은 알아야 겠죠.
The client deployer is a package which can be used to validate, compile, and deploy a web application to a production or development server. It should be noted that this feature uses the Tomcat manager for automatic deployment.
이 디플로이어는 카탈리나 매니저 앤트 태스크, 배치 전에 JSP 컴파일을 하기 위한 재스퍼 페이지 컴파일러, 그리고 웹 애플리케이션 배치 기술서를 검증하는 태스크를 포함하고 있습니다. 검증 태스크(org.apache.catalina.ant.ValidatorTask 클래스)는 파라미터 하나만 받습니다: 웹 애플리케이션의 기본 경로
The deployer includes the Catalina manager Ant tasks, the Jasper page compiler for JSP compilation before deployment, as well as a task which validates the webapp's deployment descriptor. The validator task (class org.apache.catalina.ant.ValidatorTask) allows only one parameter: the base path of an expanded web application.
디플로이어는 입력으로 펼쳐진 웹 애플리케이션을 이용합니다(아래에 나와 있는 디플로이어의 프로퍼티 목록 참조). 디플로이어가 프로그램으로 배치하게 되는 웹 애플리케이션은 톰캣에 특화된 배치 설정을 포함할 수도 있습니다. /META-INF/context.xml 안에 있는 컨텍스트 설정 XML 파일이죠.
The deployer uses an unpacked web application as input (see the list of the properties used by the deployer below). A web application which is programatically deployed with the deployer may include Tomcat specific deployment configuration, by including a Context configuration XML file in /META-INF/context.xml.
디플로이어 패키지는 다음과 같은 앤트 스크립트 타겟을 사용할 수 있습니다:
The deployer package includes a ready to use Ant script, with the following targets:
compile (default): Compile and validate the web application. This can be used standalone, and does not need a running Tomcat server. The compiled application will only run on the associated Tomcat 5.0.x server release, and is not guaranteed to work on another Tomcat release, as the code generated by Jasper depends on its runtime component. It should also be noted that this target will also compile automatically any Java source file located in the /WEB-INF/classes folder of the web application.
deploy: Deploy a web application (compiled or not) to a Tomcat server
undeploy: Undeploy a web application
start: Start web application
reload: Reload web application
stop: Stop web application
다음 프로퍼티는 시스템 프로퍼티나 또는 디플로이어 패키지의 루트 폴더에 있는 deployer.properties 파일을 통해서 지정할 수 있습니다:
The following properties can be specified, either as system properties, or by using a deployer.properties file located in the root folder of the deployer package:
build: The build folder used will be, by default, ${build}/webapp${path}. After the end of the execution of the compile target, the web application WAR will be located at ${build}/webapp${path}.war.
webapp: Folder containing the expanded web application which will be compiled and validated. By default, the folder is myapp.
path: Deployed context path of the web application, by default /myapp.
url: Absolute URL to the manager web application of a running Tomcat server, which will be used to deploy and undeploy the web application. By default, the deployer will attempt to access a Tomcat instance running on localhost, at http://localhost:8080/manager.
username: Username to be used to connect to the Tomcat manager.
password: Password to be used to connect to the Tomcat manager.
from: http://tomcat.apache.org/tomcat-5.0-doc/deployer-howto.html
Apache Tomcat 트레이아이콘에서 Configure... 를 선택하면 서비스에 등록된 Apache Tomcat의 세부 설정을 조정할 수 있습니다. 2001년 Tomcat 3.x에 비하면 많이 좋아졌죠.
Configure 의 내용을 살짝 알아보겠습니다.
1. General
Apache Tomcat service General
Apache Tomcat service LogOn
Apache Tomcat service Logging
Apache Tomcat service Java
Apache Tomcat service Startup
Apache Tomcat service Shutdown