> For the complete documentation index, see [llms.txt](https://docs.sysout.co.kr/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.sysout.co.kr/web/back-end/apache-tomcat/tomcat-user.md).

# Tomcat User 생성

## Tomcat User 생성

이 문서에서는 톰캣 관리자를 설정하는 방법을 다룬다.

### 설정 작성&#x20;

오류 메세지에서도 알 수 있지만 특정 권한을 가진 사용자를 만들어야 한다. 톰캣 설치 폴더 내의 `conf/tomcat-users.xml`을 열고 다음과 같이 생성한다.

```xml
<?xml version='1.0' encoding='UTF-8'?>
<tomcat-users ...>

    <!-- 중간 생략 -->
    <role rolename="manager-gui"/>
    <role rolename="manager-script"/>
    <user username="허용할ID" password="비밀번호" roles="manager-gui,manager-script,manager-status"/>
    
</tomcat-users>
```

### 권한

부여 가능한 권한에 대한  공식 설명은 다음과 같다.&#x20;

* `manager-gui` - allow access to the HTML GUI and the status pages
* `manager-script` - allow access to the text interface and the status pages
* `manager-jmx` - allow access to JMS proxy and status pages
* `manager-status` - allow access to the status pages only

위 권한 중에서 `manager-jmx`는 JMX(Java Management eXtensions)를 이용한 접근 허용 권한을 말한다. 설명이 잘 된 사이트의 링크를 첨부한다.

{% embed url="<https://www.lesstif.com/java/apache-tomcat-jmx-monitoring-20776824.html>" %}
