The script is /user/web/cgi-bin/cgierror.pl. It is fairly simple. If a user script generated the error, it prints a message indicating to whom the script belongs and showing relevant parts of the error logs. For non user scripts, it prints an error message. If no script is involved, the "Internal Server Error" message is printed.
To enable the script, you must edit srm.conf. Add the following line:
ErrorDocument 500 /cgi-bin/cgierror.plA HUP signal needs to be sent to the server when the configuration files are changed.
If for some reason cgierror.pl is unable to run correctly, the server will handle it gracefully and report an "Internal Server Error".
The script bin/thermgraph.pl is run from a cron job at 11:05am and 11:05pm. It generates the page graphs.html and all of the graph images in graphs/.
The file thermometers contains the locations of all the current thermometers. Each line describes one thermometer. A thermometer description contains a room name, a server name, a warning theshold, and a room number. Each field is delimited by tabs. The file looks like:
machine room console 75 3300 aleutian lab kiska 80 3352 dance lab waltz 80 3353 rock lab quartzite 80 3308This file is used by the scripts to generate the web pages and graphs.
The install script copies a number of scripts into /usr/cpssbin/thermometer, modifies the crontab, /etc/services and adds a startup script.
The warning threshold defaults to 75. To change this you need to edit /usr/cpssbin/thermometer/warn.
There is a bug with the thermometer startup script. It grabs the console when the machine boots up. I do not know how to fix this.
You need to add a new thermometer to /user/web/htdocs/facility/labtemps/theremometers by hand.
A QTek thermometer must be attached to each thermometer server. Please see the "Qtek Software Thermometer User Guide" for details about the thermometers. Special cables need to be made for the thermometers. See the guide for details. The thermometers must be attached to an RS232 serial port. It may be necessary to change the jumpers in the server. On an ULTRA-10, the jumpers are JP3 and JP4.
The technical report submission script is /user/web/cgi-bin/tech-sub.
The local tech report information is in /user/web/htadmin.
The tech report information is stored in tech_reports.bib. This should belong to group faculty and be writable by group. Online versions of the tech reports are stored in ./TR.
updateDB.pl updates the tech report library. It is called by updateall which runs nightly.
authoraliases is a human generated file used by updateDB.pl. It contains a list of aliases an author is knowned by (e.g. B. Smith=Smith,Bob). This is to ensure that papers written by the same author will appear together. Periodically a human should view the tech reports sorted by author, looking for possible aliases to be added.
Periodically the dienst server gets confused. When this happens, it generates an error when someone tries to view a tech report. The solution is to kill the server and restart it. Kill the server by using
The contact information is displayed in UI_Server/trs.pl. Indexer/access_tr_database.pl and Indexer/parse_bib_file.pl extract the information from the bib file and were modified to handle the contact field.
The author alias feature was added to dienst. The code for this is in updateDB.pl.
Everytime a cgi script mails a message, it is logged to /user/web/logs/mail_log. Log entries look like:
[Tue Dec 1 17:53:21 EST 1998] SCRIPT=/cgi-user/xujinshe/chen.sh ARGS=-i xujinshe [Tue Dec 1 08:12:22 EST 1998] SCRIPT=/cgi-user/barrios1/formmail3.pl URL=http://ism.ferris.edu/students/b/bigottmi/ ARGS=-tSCRIPT indicates which script sent the mail. URL indicates which page referenced the script.
/usr/lib/sendmail is a link to /usr/lib/sendmail.web which looks like the following:
#!/opt/bin/perl
#
# only log if the mail is from nobody
#
$ENV{'PATH'}="";
if ($< == 60001)
{
open (LOGFILE, ">>/user/web/logs/mail_log") || die "Cannot open logfile";
flock (LOGFILE, 2);
seek (LOGFILE, 0, 2);
$date=`/usr/bin/date`;
chop $date;
print LOGFILE "[$date] ";
print LOGFILE "SCRIPT=$ENV{'SCRIPT_NAME'} ";
if ($ENV{'DOCUMENT_URI'})
{
print LOGFILE "URL=$ENV{'DOCUMENT_URI'} ";
}
elsif ($ENV{'HTTP_REFERER'})
{
print LOGFILE "URL=$ENV{'HTTP_REFERER'} ";
}
print LOGFILE "ARGS=@ARGV\n";
close(LOGFILE);
#flock(LOGFILE,8);
}
exec '/usr/lib/sendmail.bin', @ARGV;
The original sendmail has been renamed /usr/lib/sendmail.bin.
man2html handles most man pages. There are a few rare troff constructs it does not handle correctly, and some pages are formatted strangely. It gets it right 99% of the time.
In order for troff2html to handle pic requests correctly, /user/web/htdocs/tmp must be a symbolic link to /tmp.
15 05 * * * /soft/sparc/adm/Scripts/pidpasswd.pl > /user/cgi/web/Vote/.htpasswd
In order for voting to work, the script withrow.pl must be able to write in the Results/Withrow directory. Currently withro.pl is setuid calend44 and Results/Withrow has acls on it that permit calend44 to write there.
If the voting script fails, it should print out a message to the voter telling them that something went wrong.
The voting results are stored in Results. To start a new vote, simply clear the contents of this directory. NOTE!! Do not do this until the people handling the Withrow award have counted the votes.