之前用的8.0版本的tomcat,最近需要将版本升级,当前8的最新的版本是8.5.42,升级之后发现manager页面打不开了,就是下面这个按钮的页面

tomcat8.5打开manager页面报错的问题

 

点击之后报403没权的错误

tomcat8.5打开manager页面报错的问题

 

还是按照8.0版本的配置方法,在conf/tomcat-users.xml中配置权限和用户名密码,类似页面提示的这样。

<role rolename="manager-gui"/>
<user username="tomcat" password="s3cret" roles="manager-gui"/>

但是重启服务后还是提示同样的错误,再次确认配置的没问题后,这次才好好的把页面的错误提示读了一遍,发现有这么个提示

By default the Manager is only accessible from a browser running on the same machine as Tomcat. If you wish to modify this restriction, you'll need to edit the Manager's context.xml file.

默认只允许本机访问了,如果要允许其他主机访问要去修改manaager的context.xml文件,看来这是8.5的新特性了,找到webapps\manager\META-INF\context.xml 文件,看到文件里果然有限制本机访问的配置,将这段注释掉

tomcat8.5打开manager页面报错的问题

重启服务之后,再次访问就可以登录了,用你配置的用户名密码就可以进入管理页面了

tomcat8.5打开manager页面报错的问题

 

相关文章:

  • 2022-12-23
  • 2021-11-17
  • 2022-12-23
  • 2022-12-23
  • 2021-10-05
  • 2021-04-20
  • 2022-12-23
  • 2022-01-02
猜你喜欢
  • 2021-06-24
  • 2021-10-07
  • 2022-01-22
  • 2021-09-01
  • 2021-05-01
  • 2021-07-30
  • 2022-02-04
相关资源
相似解决方案