美文网首页
Tomcat进入Manager的问题

Tomcat进入Manager的问题

作者: onweer | 来源:发表于2016-02-20 22:27 被阅读253次

  1. 解除注释Tomcat/conf目录下的 tomcat-users.xml 文件下的 <tomcat-users> </tomcat-users> 字段
  2. 进入manager界面之后,显示的是403 Access Denied
    解决办法:
    <pre>
    在conf/tomcat-users.xml文件中看到这么一段话:
      NOTE: By default, no user is included in the "manager-gui" role required to operate the "/manager/html" web application. If you wish to use this app,you must define such a user - the username and password are arbitrary.
     也就是说,为了考虑安全,tomcat默认还是没有manager-gui的管理权限的,如果想要使用manager的话,需要自行加入管理权限(角色)。
    </pre>

综上:
需要加一个这样的权限(角色) :
<role rolename="manager-gui"/>
然后再加到需要的用户名中去:
<user username="tomcat" password="tomcat" roles="tomcat,manager-gui"/>


给个github follow me的链接,上面有很多初学者可供学习的资料,项目.

<a>https://github.com/SuperZee</a>

相关文章

网友评论

      本文标题:Tomcat进入Manager的问题

      本文链接:https://www.haomeiwen.com/subject/qubvkttx.html