[英]Can't access Tomcat in NetBeans
I've a really big problem. 我有一个很大的问题。 I installed the new NetBeans 8.0
and by the way doing this I also changed my Tomcat
to 7.0
. 我安装了新的NetBeans 8.0
然后将Tomcat
更改为7.0
。 Also I set Tomcats tomcat-users.xml (../Tomcat 7.0/conf/tomcat-users.xml)
manager role and set the name and password in Tomcat options in NetBeans. 另外,我将Tomcats设置为tomcat-users.xml (../Tomcat 7.0/conf/tomcat-users.xml)
Tomcat tomcat-users.xml (../Tomcat 7.0/conf/tomcat-users.xml)
管理器角色,并在NetBeans的Tomcat选项中设置名称和密码。
If I'm running my project now (which was running perfectly befor, but i unfortunately deleted my old environment befor the new setup) the server start but the project is not deployed on Tomcat. 如果我现在正在运行我的项目(之前运行得很好,但是不幸的是我在新设置之前删除了旧环境),服务器将启动,但是该项目未部署在Tomcat上。
If I go to localhost:8080
Tomcat server
is running. 如果我转到localhost:8080
Tomcat server
正在运行。 I can access Tomcat with my username and password I specified but if I try to see Tomcats Web Applications
folder in NetBeans I alway recieve the error message: 我可以使用我指定的用户名和密码访问Tomcat,但是如果尝试查看NetBeans中的Tomcats Web Applications
文件夹,我总是会收到错误消息:
"Access to Tomcat server has not been authorized. Set the correct username and password with the "manager-script" role in Tomcat customizer in the Server Manager." “未授权对Tomcat服务器的访问。在服务器管理器的Tomcat定制程序中,使用“ manager-script”角色设置正确的用户名和密码。
It is not the first time I set up Netbeans with Tomcat but I never had this problem, if somebody have any idea how to solve this problem I would be really thankful. 这不是我第一次使用Tomcat设置Netbeans,但我从未遇到过这个问题,如果有人对如何解决此问题有任何想法,我将非常感激。
Thanks in advance. 提前致谢。
You can try to create or update tomcat-users.xml
in tomcathome\\conf
folder by adding manager role 您可以通过添加管理员角色尝试在tomcathome\\conf
文件夹中创建或更新tomcat-users.xml
。
<tomcat-users>
<role rolename="admin"/>
<user username="admin" password="admin" roles="manager"/>
<role rolename="manager-gui"/>
<user username="admin" password="admin" roles="manager-gui"/>
</tomcat-users>
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.