简体   繁体   中英

how to access following admin and manager roles= manager-script, tomcat, admin-script on Apache Tomcat 9.0.43

I install appache and then Tomcat 9.0.43 on my Raspberry Pi3 both servers and their atributes are working fine but when it come to login I am having issues with following manager and admin roles:

(1)manager-script, when I lounch localhost:8080 I get three buttons on right handside 1.Server Status,2.Manager App and 3.Host manager this rolename does not let me login either of them

(2) rolename=admin-script like manager-script can't login in either of the button

(3) once you login to either other define roles in following code then described above, once you login you will staylogin no matter how many times you close your browser some time it works restarting the server or have to completly reboot the whole system

(4) rolename=tomcat, I can't work out what does it suppose to do I include this rolename in my code because every code I have seen on net everyone is keeping this role in their code so I have include in mine to but it doesn't let me login to either

Code

FAIL - Unknown command [/text]

Restart the server every time if I have to either login in a different role or even server stop it self then I have to issue following command again or re-start the Rspberry pi 3

terminal comand to restart the Tomcat Server

for example if I have tested Server Status now I wanted to get into Managers app I have to close the browser and restart the server again is it normal of there is something wrong with my machine? enter image description here

Tomcat itself does not define any roles, these are all defined by the web applications. In order to use the HTML versions of Tomcat Manager and Tomcat Host Manager application you need:

The roles you cite ( manager-script and admin-script ) are used by the text interface of those applications.

Due to the way HTTP Authentication is implemented in browsers, changing users is difficult: the easiest solution to your problem is not to change users at all. If you want to use the two aforementioned applications, define a user which has both roles:

<user username="user" password="secret" roles="admin-gui,manager-gui" />

and log in using that user.

Otherwise you'll bump into two problems:

  • user credentials are cached in the HTTP session (unless you set cache="false" on the Basic Authenticator Valve ). Sessions are stored to disk upon server restart, so the only way to logout from a user is to delete the JSESSIONID cookie in your browser,
  • browsers cache previously entered HTTP Authentication credentials, so that the next time they are needed you won't get a popup window to enter credentials. The only way to login as another user (assuming you already cleared the cookies) is to add the credentials into the URL, eg http://user:password@localhost:8080/manager/html .

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM