![]() | CSCI A348/A548Lecture Notes 1 Fall 1999 |
cgi-bin
directory. The
"Hello World!"
program
in perl
and the
"Hello World!"
program
in Java
. A preview of things to come.
Introduction and announcements:
LH 102 (TR, 7pm)
LH 115 (W
or R 4:40pm)
.
Access provided by the instructor.
LH 115
or
LH016
as posted or by appointment.
ac.csci.a348
E-mail:dgerman@indiana.edu
Telephone:855-2510
Office:Franklin Hall M005
http://accounts.ucs.indiana.edu
to create your own account if you don't have one.
You will need to have an IUB Network ID. If you experience any
difficulties please ask your instructor for help.
LH004
.
You can get individual access
to the room if you go to LH215
with your student photo ID and request access.
You will need to fill out a form and shortly after that you will be able to
use your student ID to enter the room.
Initial server setupThis course is mostly oriented towards providing functionality (transactions) rather than just static hierarchies of documents although we will discuss those as well.
CGI and Perl (server side) programming
Client side (Java and Javascript) programming
Writing and understanding servers and clients
Network protocols
Java servlets and Java RMI
Web security
Web site design considerations
Team projects
Programming will be present throughout the course since we will want to build an understanding of how things work on the web so that we can program into it the desired behaviour. At the same time programs are easier to grade.
The following is related to the material that starts on page 68 in your textbook (Stein). You will need to use your own username and port number (once you are being assigned one) to install Apache on the machine that has been assigned to you.
dgerman
)
tucotuco
)
19904
)
mkdir apache
cd apache
cp /u/dgerman/apache_1.3.1-sparc-sun-solaris-26.tar.gz apache.tar.gz
You would otherwise get it from http://www.apache.org
For the next sequence of commands explanations will be provided in the labs and lecture.
gunzip apache.tar.gz
tar xvf apache.tar
cd
mkdir httpd
cd httpd
cp -R ../apache/apache_1.3.1/* .
mv src/httpd-solaris26 httpd
cd conf
cp httpd.conf-dist httpd.conf
vi httpd.conf
and make the following changes:
ServerRoot /u/dgerman/httpd
Port 19904
You need to use your own username and the port assigned to you! Ports will be distributed in the lab and will be posted on the course web page.
Also add a line like this
LockFile /tmp/apache.lockfile.your_username
at the end of httpd.conf
. Make sure it ends in
your username.
cp srm.conf-dist srm.conf
vi srm.conf
and make the following changes:
DocumentRoot /u/dgerman/httpd/htdocs
ScriptAlias /cgi-bin/ /u/dgerman/httpd/cgi-bin/
cp access.conf-dist access.conf
vi access.conf
and make the following changes
<Directory /u/dgerman/httpd/htdocs>
<Directory /u/dgerman/httpd/cgi-bin>
Underlined strings need to be replaced with your coordinates.
cd ..
Try http://tucotuco.cs.indiana.edu:19904
now.
Again, what's underlined should be replaced with your own coordinates.
./httpd -d .
Try http://tucotuco.cs.indiana.edu:19904
again now.
cd logs
kill -HUP `cat httpd.pid`
cd logs
kill `cat httpd.pid`
/u/dgerman/httpd/htdocs/index.html
)
#!/usr/bin/perl
print qq{
Welcome to the course.
};
and place it in /u/dgerman/httpd/cgi-bin/hello
Make it executable and try
http://tucotuco.cs.indiana.edu:19904/cgi-bin/hello
now. Change the hello script to send back a larger HTML document.
Hello.java
:
class Hello { public static void main (String[] args) { System.out.println("Hello, world."); } }
Hello.java
. Make sure that the index.html
file in your document root directory identifies you and your server
and add a document on your web site that details the steps you took
to install your server, what they mean, and why we take them.