Title: Checking the Server
1Checking the Server
2Location of Server Files on the Virtual Machine
- On your virtual machine
- The Tomcat servlet engine is in
/usr/local/javadev/apache/tomcat-5.5.12 (this is
the value of CATALINA_HOME) - The BES, data handlers and related source files
are in /usr/local/src. The BES has been built and
installed in /usr/local/ (prefix) - The OLFS web archive file is CATALINA_HOME/webapp
s/opendap.war - BES bes.conf, found at prefix/etc/bes/bes.conf
- OLFS olfs.xml and catalog.xml, found at
CATALINA_HOME/content/opendap
3Background Starting the Server
- Start the BES (back-end data processing
component) - Use bescmdln to verify its working
- Start Tomcat This automatically starts all
installed servlets - Servlets are installed by copying the .war file
to the servlets webapps directory - Verify its working using a web browser
4Start the BES
5Verify the BES is running
6Start Tomcat the OLFS
- Typical steps
- Unpack the olfs jar-file
- Copy the opendap.war file to Tomcats webapps
directory - Start Tomcat
- Since all but the last step has been done
already, start Tomcat - /usr/local/javadev/apache-tomcat-5.5.12/bin/startu
p.sh
7terminal view
8Verify Tomcat is running
http//localhost8080
9and Hyrax
http//localhost8080/opendap
10Troubleshooting
- The getdap command line client
- Can request any of the DAP response objects
- Can act as a simple, generic web client
- When even getdap cannot diagnose a problem, use
telnet!
11Troubleshooting with getdap
- Use getdap to get
- The DAS, DDS, Data, DDX
- Version information
- Use telnet to view the raw HTTP response
- If the server times out too quickly, use expect
to control telnet
12Use the -a option to get a DAS response
Also provide a valid URL http//localhost8080/ope
ndap/data/nc/fnoc1.nc
13Use the -d option to get a DDS response
14or drop the -d option and append the .dds
suffix
15Use the -D (data) and -c (constraint)
options to get a data response.
A constraint expression with just one variable.
We got this from the DDS above
16This constraint is asking for the values of
time between indexes 2 and 6 (every second
value).
17Appending the string version to the server root
name requests version information. It comes back
in an XML document.
18Telnet reveals all
- Use telnet to pass HTTP commands directly to the
opendap web application - Open the connection using the host name and port
number - Use the GET command, the pathname part of the
URL including the DAP request extension and
HTTP/1.1 or HTTP/1.0 - Often you will need to supply a Host ltnamegt
header - A blank line.
19Connect to the Tomcat or Apache server
GET ltpathnamegt HTTP/1.1 (or 1.0) - hit return
quickly!
Host header is important for a virtual server
Heres the payoff - we can see all of the
headers set by both the web app and the server,
plus the response. Be cautious with data
responses because they are binary and will mess
up your terminal session. Note the HTTP 1.1
chunking counts (c5 and 0)