我已經下載的Tomcat 7,解壓縮,並在Eclipse中添加它。但後來我打localhost:9999(我的端口是9999),我啓動了服務器,但沒有出現tomcat的主頁。以下是圖像:的Tomcat 7:無法看到主頁tomcat的
我試圖更改:d:\ java中安裝\ Apache的Tomcat的7.0 \的conf \ tomcat的-users.xml中。添加用戶如下:
<tomcat-users>
<!--
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.
-->
<!--
NOTE: The sample user and role entries below are wrapped in a comment
and thus are ignored when reading this file. Do not forget to remove
<!.. ..> that surrounds them.
-->
<!--
<role rolename="tomcat"/>
<role rolename="role1"/>
<user username="tomcat" password="tomcat" roles="tomcat"/>
<user username="both" password="tomcat" roles="tomcat,role1"/>
<user username="role1" password="tomcat" roles="role1"/>
-->
<role rolename="manager-gui"/>
<user username="manager" password="xxxx" roles="manager-gui"/>
</tomcat-users>
請幫忙。
你爲什麼下載從2012年(7.0.34)釋放時,有一個目前一個可用(7.0.75,8.0.41,8.5.11)?另外:tomcat-users.xml與部署的webapps無關。你目前的webapps文件夾中有什麼,以及除了端口更改之外還有什麼其他配置? –
@OlafKock我先用8.0.41試過,但當我試圖打localhost:8081時,我得到了404。 webapps文件夾是在默認情況下和配置更改,我不知道。善意幫助 –