sudo vi /etc/tomcat6/tomcat-users.xml
输入密码后进入tomcat-users.xml文件
在<tomcat-users>与</tomcat-users>之间作出修改
修改后代码如下:
<tomcat-users>
<role rolename="manager"/>
<role rolename="admin"/>
<user username="manager" password="tomcat" role="manager"/>
<user username="admin" password="tomcat" role="admin"/>
</tomcat-users>
切记 要把注释符号给删除:
<!--
-->