For example, you may select broad.cse.sc.edu
There are a few ways to do it
With ls command, you can find out how many subdirectories have already been created under /work
With df -k command,you can find out disk space that machine has under /work
For example, when using df -k on broad.cse.sc.edu, one line of the output is:
/dev/dsk/c0t0d0s5 15110050 9 14958941 1% /work
It means this machine has 14958941k byte spare space.
If there are a lot of subdirectories under /work or the spare space is not big enough ( 100M may be needed), you may need to think about selecting another machine.
Once selected a machine, write down its name. You need to login that machine every time when you want to use Tomcat.
If you could not create your own directory there, please select another machine.
This will make sure other students could not get into your directory.
Example: 15634 for student with SSN: xxx-xx-5643
You should find a line like <Connector port="8080" change it to be <Connector port="15643"
This is done by removing line <!-- and --> before and after it.
In this versions of Tomcat 5, the commented out entry distributed with Apache Tomcat is in error: it is missing the trailing slash (i.e., <Context ... debug="0" > instead of the proper <Context ... debug="0" /> ). So, you will need to insert the slash.
This entry should be put just below the following comment:
<!-- Define properties for each web application...
Note that the filename is web.xml, not server.xml
<user username="manager" password="<passwd>" roles="manager"/>
<user username="admin" password="<passwd>" roles="admin"/>
Here, <passwd> is the password you select for management.
These two lines should be put just before </tomcat-users>
*This step is shell dependent
setenv CATALINA_HOME /work/<userid>/jakarta-tomcat-5.0.16
setenv JAVA_HOME /usr/local/java1.4
Using command echo $CATALINA_HOME and echo $JAVA_HOME command do figure out what kind of shell you are using.
To avoid input these environment variables setting commands every time, you can put them in n/acct/s1/<userid>/SUN/.cshrc for csh or /acct/s1/<userid>/SUN/.bashrc for bash.
You can use echo $SHELL or ps command to figure out what kind of shell you are using.
If you get information like:
The JAVA_HOME environment variable is not defined correctly This environment variable is needed to run this program
Using command whereis java for a java install directory, for example /usr/local/java1.4.1,
and reset JAVA_HOME environment variable
You should get the Tomcat management home page.
Viewable on campus only, Connect to COEIT VPN Server for workaround for access from home.
Be careful that your browser does not try to change the file extension, yielding Hello.htm instead of Hello.html
You can add /work/<userid>/jakarta-tomcat-5.0.16/bin to PATH in your .cshrc (or .bashrc) file. Then you can use command startup.sh to startup and shutdown.sh to shutdown Tomcat server anywhere.
cd //This command make sure current directory is /acct/s1/<userid>/SUN/
ln -s /work/<userid>/jakarta-tomcat-5.0.16/webapps/ROOT/WEB-INF/classes /acct/s1/<userid>/SUN/csce590n/dev
The last command constructs a symbol link. I recommend you use it. You can also use mkdir csce590n/dev instead, but that means you need to copy your programs to your publish directory /work/<userid>/jakarta-tomcat-5.0.16/webapps/ROOT/WEB-INF/classes everytime.
To avoid input these commands every time, you can put them in /acct/s1/<userid>/SUN/ .cshrc for csh or /acct/s1/<userid>/SUN/.bashrc for bash
If you get compilation errors, go back and check your CLASSPATH settings. You most likely erred in listing the location of the JAR file that contains the servlet classes.
You need to copy the .class file to /acct/s1/<userid>/web/WEB-INF/classes/ first if you do not use symbol link.
here, you need to create subdirectory coreservlets yourself.
If you want to download and install Tomcat on your own computer, please check here for help.
*For csce590n Spring 2004 students only:
If you still have problem with installation and configuration, please send an email to firstname.lastname@example.org
Last modified:Tue Jan 27 6:38:45 EST 2004