Discussion:
Unable to Run Programs From Apache Tomcat
arndtmatt
2012-06-11 18:38:10 UTC
Permalink
I have NetBeans installed using Apache Tomcat 7. I try to run a program and am prompted with the Tomcat Manager Application and asked for a username and password.

First off I am unable to change the password under the properties of the Apache Tomcat server. I can change the username but no matter what the password always stays the same. I edited the tomcat-user.xml file both in the Catalina home & base but it doesn't seem to make a difference. I still cannot run anything from with NetBeans. I get Deployment error: Access to Tomcat server has not been authorized. Set the correct username and password with the "manager-script" role in the Tomcat customizer in the Server Manager.
See the server log for details.

This is what I have setup in the tomcat-user.xml file


<?xml version='1.0' encoding='utf-8'?>
<!--
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<tomcat-users>
<role rolename="tomcat"/>
<role rolename="role1"/>
<role rolename="manager"/>
<role rolename="manager-script"/>
<role rolename="admin"/>
<user username="tomcat" password="tomcat" roles="tomcat"/>
<user username="both" password="tomcat" roles="tomcat,role1"/>
<user username="role1" password="tomcat" roles="role1"/>
<user username="Matthew" password="tomcat" roles="admin,manager,manager-script"/>
</tomcat-users>

Any help would be great. Also, I can get into apache through Localhost but unable to access any of the support documents, I get:

HTTP Status 404 - /docs/realm-howto.html

Any help would be great,


Matthew
Rick Fincher
2012-06-11 23:24:22 UTC
Permalink
In the Tomcat properties dialog in NetBeans click the "show" button
beside the password to see it in clear text. Then copy that password
into tomcat-user.xml as your password.

Rick
Post by arndtmatt
I have NetBeans installed using Apache Tomcat 7. I try to run a program and am prompted with the Tomcat Manager Application and asked for a username and password.
First off I am unable to change the password under the properties of the Apache Tomcat server. I can change the username but no matter what the password always stays the same. I edited the tomcat-user.xml file both in the Catalina home& base but it doesn't seem to make a difference. I still cannot run anything from with NetBeans. I get Deployment error: Access to Tomcat server has not been authorized. Set the correct username and password with the "manager-script" role in the Tomcat customizer in the Server Manager.
See the server log for details.
This is what I have setup in the tomcat-user.xml file
<?xml version='1.0' encoding='utf-8'?>
<!--
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<tomcat-users>
<role rolename="tomcat"/>
<role rolename="role1"/>
<role rolename="manager"/>
<role rolename="manager-script"/>
<role rolename="admin"/>
<user username="tomcat" password="tomcat" roles="tomcat"/>
<user username="both" password="tomcat" roles="tomcat,role1"/>
<user username="role1" password="tomcat" roles="role1"/>
<user username="Matthew" password="tomcat" roles="admin,manager,manager-script"/>
</tomcat-users>
HTTP Status 404 - /docs/realm-howto.html
Any help would be great,
Matthew
Loading...