Overview of WeBWorK system setup for WeBWorK 1.8 | topic started 10/16/2002; 5:53:27 AM last post 10/16/2002; 5:53:27 AM |
Arnold K. Pizer - Overview of WeBWorK system setup for WeBWorK 1.8 10/16/2002; 5:53:27 AM (reads: 2412, responses: 0) |
Overview of WeBWorK system setup
Where to put the WeBWorK files
The WeBWorK files can be placed almost anywhere but a reasonable location is
under
usr
The
The
How much disk space you need depends on how large your courses are, how much temporary data you keep, whether or not you do any "housekeeping", whether for example you have WeBWorK keep an access_log which can become huge, etc. It is difficult to give general guidelines. The actual system files take up less than 5 MB. The system log files can be many many times that size. A 100 student course might have 25 MB of actual permanent data and 250 MB of temporary data. If you are setting up a system which will have a substantial number of users, we recommend you set up tmp directories for courses under a separate file system (see linux.html). Disk space is very cheap --- it is a lot better to have too much than too little.
How does WeBWorK interact with the webserver?No WeBWorK files are directly accessible from the web. Rather all access is through two types of methods, one for cgi scripts and one for html files. The WeBWorK cgi directory can be accessed through either of two methods. The first method of accessing the WeBWorK cgi directory is through a link. One cgi link gives access to all of WeBWorK's cgi scripts. Note that this requires your webserver to be set up to follow symbolic links under the cgi-bin directory. If for some reason you do not want to set up your webserver this way, we suggest you first do so on a temporary basis and get WeBWorK running. Then you can move WeBWorK's cgi directory ( www/webwork/system/cgi )
so that it lies under the webserver's cgi-bin directory at which point a cgi
link will not be needed. Or you can use the second method which is our
recommended method.
The second (and recommended) method of accessing the WeBWorK cgi directory is through (at least with Apache) a ScriptAlias directive in
Apache's httpd.conf file. With this method it is not required that
your webserver to be set up to follow symbolic links for cgi scripts. Note that
the Apache performance tuning document mentions there is a performanace hit
(probably slight) if your webserver is not configured to follow symbolic links.
There is one html link that gives access to the html files used by the WeBWorK system. In addition there is one html link for every course that gives access to the html files used by each individual WeBWorK course (this link is set up when setting up a course). Note that this requires your webserver to be set up to follow symbolic links under the htdocs directory, i.e. the html document root Directions for configuring apache and setting up these links are given in the linux.html document.
What does the system setup script do?
This script is run only when you initially set up the WeBWorK system. It modifies all the scripts entering the correct path to perl on your system. It writes a webworkConfig.pm file and
webworkInit.pm files contain the correct path to WeBWorK on your
system and other configuration data. The webworkConfig.pm file is
located in the .../webwork/system/lib directory and the
webworkInit.pm files are located in the cgi ,
cgi/cgi-scripts , scripts and
courseScripts directories. Each of these four directories is a
subdirectory of .../webwork/system .
It sets the correct permissions and groups for all the files and directories. This is extremely tricky to get correct by hand if you want to have a functioning and secure system. It modifies the Global.pm file entering the cgi and html
WeBWorK URL's for your system. The variables defined in the Global.pm
file set defaults and parameters for the whole WeBWorK system. Defaults
can be over ridden for individual courses by redefining variables in the
individual course webworkCourse.ph files. The
Global.pm file is located in the
.../webwork/system/lib directory.
What does the course setup script do?This script is run every time a WeBWorK course is set up. It sets the correct permissions and groups for all the course files and directories. Any missing files or directories are created. It creates the webworkCourse.ph file. The variables defined
in this file set defaults and parameters for the individual course. System
defaults set in Global.pm can be over ridden for the individual
course by redefining variables in the webworkCourse.ph file. The
webworkCourse.ph file for the course mth161 is located
in the
.../webwork/courses/mth161 directory.
It creates a generic but functional index.html , i.e. a front
page, for the course. Almost certainly, professors will want to customize this
page. The index.html file for the course mth161 is
located in the .../webwork/courses/mth161/html directory.
|