tomcat配置管理员帐号密码

时间:2022-05-01 08:37:47

进入tomcat目录下的conf中的tomcat-users.xml:

增加以下语句

<role rolename="admin-gui"/>
<role rolename="admin-script"/>
<role rolename="manager-gui"/>
<role rolename="manager-script"/>
<role rolename="manager-jmx"/>
<role rolename="manager-status"/>
<user password="tomcat" roles="manager-gui,manager-script,manager-jmx,manager-status,admin-script,admin-gui" username="tomcat"/>

保存后启动tomcat,输入用户名:tomcat,密码:tomcat