cd /tmp
zcat /tmp/jakarta-tomcat-5.0.19.tar.gz | tar xf -
- Copy the tomcat file tree to its final destination (in this example case, /usr/local/). You may
have to do this as root if only root can write to the desired destination.
cp -r /tmp/jakarta-tomcat-5.0.19 /usr/local
- Set the ownership of the entire tomcat file tree to reflect the user account in which
tomcat will be run (we don't recommend running tomcat as root). In this example, we're using
user id "agrid" and group id "agrid" :
chown -R agrid:agrid /usr/local/jakarta-tomcat-5.0.19
- Use the instructions in the file RUNNING.txt, included in the toplevel directory of the tomcat distribution that you have just installed, to start and stop the server and check that it's running. (Do this while logged in as the tomcat user - "agrid" in this example - not as root!) This file also includes instructions for changing the port on which tomcat is run (by default, 8080) and for installing multiple copies of tomcat on the same server.
- Within tomcat, set up a user with privileges to allow administering and managing the tomcat server via its web interface. To do this,
edit the file jakarta-tomcat-5.0.19/conf/tomcat-users.xml and add a suitable user:
<?xml version='1.0' encoding='utf-8'?> <tomcat-users> <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"/> <user username="agriduser" password="agridpasswd" roles="admin,manager"/> </tomcat-users>Here, we've added a user with name "agriduser" and password "agridpasswd". (This password is stored in plain text, so don't use a security-critical system password!) When you go to the manager or admin interfaces from tomcat's home page, you'll be prompted for this username and password to gain access. You'll also need to use this username and password when installing Astrogrid software using the deployment kit.
To change [the default port], open the file:
$CATALINA_HOME/conf/server.xml
and search for '8080'. Change it to a port that isn't in use, and is
greater than 1024, as ports less than or equal to 1024 require superuser
access to bind under UNIX.
Restart Tomcat and you're in business. Be sure that you replace the "8080"
in the URL you're using to access Tomcat. For example, if you change the
port to 1977, you would request the URL http://localhost:1977/ in your browser
HOWEVER, you will probably find that simply changing this port is not enough and that multiple
tomcats will fight over certain other ports.
I have attached a sample server.xml file to this page, showing which ports I needed to change in order to enable
multiple tomcats to co-exist happily using the tomcat bundle we're distributing via the link above.
Search for "KEA" in the file and you'll find all ports that I changed from the default values to other values.
-- KonaAndrews - 24 Feb 2005 | I | Attachment | Action | Size | Date | Who | Comment |
|---|---|---|---|---|---|---|
| | server.xml | manage | 17.3 K | 10 Mar 2005 - 15:31 | KonaAndrews | Sample server.xml |
![]() |
Click here for the AstroGrid Service Web |
This is the AstroGrid Development Wiki |
|