This guide walks you through the steps for installing and configuring the OCT.
The OCT has been tested on Redhat Linux versions 6.2 and 7.1 running on an Intel machine with 128 Meg RAM and 4 Gigs free local harddisk space.
The webserver software will execute as the user named octadmin. This user account will exist only on the machine that hosts the site, and all webmasters will administer the site as this single user.
Login as root, and type the following commands at the commandline: (NOTE: you can substitute any directory on your local harddisk as our "/scratch" directory.)
Logout as root, and login as octadmin. Then do:cd /scratch mkdir oct /usr/sbin/groupadd octadmin /usr/sbin/useradd -g octadmin -d /scratch/oct octadmin passwd octadmin chown octadmin oct
Add the following lines to the .bash_profile file (don't forget the leading period on the filename):cd
Then, back at the commandline, do:export OCT_HOME=/scratch/oct
source .bash_profile mkdir pkg
OCT is comprised from a collection of free, open-source tools. Download the following into the newly created pkg directory:
Downloads |
---|
http://photo.net/wtr/thebook/utilities.txt
Save this file as utilities.tcl
|
http://www.openacs.org/software.adp
Click on AOLserver Postgres Driver 2.0.0
|
http://www.postgresql.org/sites.html
Click on a mirror and download the 8Meg source file for version 7.1
|
http://www.aolserver.com
Download version 3.4
|
http://people.csail.mit.edu/u/l/lzollei/public_html/oct/download/
Download keepalive.tar.gz and oct.tar.gz (and all the above files, in fact)
|
As octadmin, do the following (be sure you renamed the file pkg/utilities.txt to utilities.tcl):
tar xzvf aolserver-3.4.tar.gz cd $OCT_HOME/pkg cd aolserver-3.4 make make install INST=$OCT_HOME/aolserver cp ~/pkg/utilities.tcl ~/aolserver/modules/tcl
Test AOLServer by doing:
Point your browser to: http://YOUR-MACHINE-NAME:8000 (but substitute your machine's name in place of YOUR-MACHINE-NAME, ie: http://oct.mit.edu:8000)cd $OCT_HOME/aolserver ./bin/nsd -kt sample-config.tcl
See it's threads by typing the following command (linux threads have differenct process IDs, or PIDs):
Stop it by looking up its main process's PID...ps -aux | grep nsd
...and killing it with the following command (substituting the PID you looked up in place of "YOUR-PID"):cat log/nspid.server1
kill -9 YOUR-PID
As octadmin, build the software by doing:
As root, create the "postgre" user by doing:cd $OCT_HOME/pkg tar xzvf postgresql-7.1.tar.gz cd postgresql-7.1 ./configure --with-x --prefix=$OCT_HOME/pgsql --exec-prefix=$OCT_HOME/pgsql --libdir=$OCT_HOME/pgsql/lib make
As postgre, edit your profile by doing:/usr/sbin/groupadd web /usr/sbin/useradd -g web -d /scratch/oct/pgsql postgre passwd postgre mkdir pgsql chown postgre.web pgsql
Add to the .bash_profile file:cd
Back at the command line, install the database by doing:OCT_HOME=/scratch/oct LD_LIBRARY_PATH=$OCT_HOME/pgsql/lib export OCT_HOME LD_LIBRARY_PATH
Create the database for oct by doing the following.source .bash_profile cd $OCT_HOME/pkg/postgresql-7.1 make install cd mkdir data cd bin ./initdb -D $OCT_HOME/pgsql/data
Test your postgresql installation.$OCT_HOME/pgsql/bin/postmaster -S -D $OCT_HOME/pgsql/data createdb octdb createlang --pglib $OCT_HOME/pgsql/lib plpgsql octdb
When the interactive terminal was open, it should have looked like this: (if not, there is a problem)psql octdb \q
Create a database user for octadmin.Welcome to psql, the PostgreSQL interactive terminal. Type: \copyright for distribution terms \h for help with SQL commands \? for help on internal slash commands \g or terminate with semicolon to execute query \q to quit octdb=>
psql octdb create user octadmin with password 'MYPASS'; \q
As octadmin, do:
cd $OCT_HOME/pkg tar xzvf pgdriver-2.0.tgz cd pgdriver-2.0 make NSHOME=$OCT_HOME/aolserver PGLIB=$OCT_HOME/pgsql/lib PGINC=$OCT_HOME/pgsql/include make install INSTALL=$OCT_HOME/aolserver
As octadmin, unpack the OCT by doing:
cd $OCT_HOME/pkg tar xzvf oct.tar.gz cd $OCT_HOME/aolserver cp ~/pkg/oct/aolserver/* . chmod 755 init chmod 755 kill chmod 644 nsd.tcl cp -r ~/pkg/oct/servers/* servers
Edit the init and kill scripts to reflect your installation.
Edit nsd.tcl to replace the MailHost, hostname, and MYPASS (that you used for database access above).
Edit servers/oct/tcl/init.tcl to suit your conference. PLEASE read the file's comments for instructions!
Load Data Model into Database
If the next step fails, then copy libraries from /scratch/oct/pgsql/lib to /usr/local/pgsql/lib. Do the following as the postgre user:
Then, do this as the octadmin user:cd $OCT_HOME/aolserver/servers/oct/pages/admin/sql psql octdb \i postgres.sql \q
cd $OCT_HOME/aolserver/servers/oct/pages/admin/sql psql octdb \i model.sql \dt \q
If you want to get fancy, install from http://www.arsdigita/free-tools/keepalive.html Otherwise, as octadmin, do:
Edit ka-init, ka-kill, and ka-nsd.tcl according to your installation. Edit servers/ka/config.ini to replace MY-MACHINE-NAME, MY-EMAIL, and the path to ka-kill. |
What Does Keepalive do? |
If you restart your machine, or if there's a power outage, it's nice if all your processes have been configured to restart automatically.
As root, edit /etc/inittab to add lines similar to:
Then apply your changes by entering the following on the command line as root:# Web Servers nsp1:2345:respawn:/scratch/oct/aolserver/init nsp2:2345:respawn:/scratch/oct/aolserver/ka-init
/sbin/init Q
This will restart AOLserver. As for the database, you can either restart it manually by typing the following as the postgre user...
... OR automatically depending on your version of Linux. For example, on Redhat Linux version 7.xx, add this file renamed /etc/rc.d/init.d/postgresql, and then run "chkconfig --add postgresql".$OCT_HOME/pgsql/bin/postmaster -S -D $OCT_HOME/pgsql/data
If you encounter trouble starting the database, note that the postmaster process will not start if something happened to create a state where some old lock files are left over. For example, if the postmaster process is not running (you don't see the postmaster process listed when you type: ps -aux), but there are lock files existing as /tmp/.s.PGSQL.*, then you will need to become root to delete these lock files.
If you find any mistakes in this documentation, or any bugs in the OCT code, please notify David Gering (gering@ai.mit.edu).
The reason OCT (Online Conference Toolkit) is called a "Toolkit" instead of a "Tool" is because you can alter and extend it to fit your conference. Useful resources in this regard are:
Useful Resources |
---|
Learn TCL
|
Learn SQL
|
Ask a very knowledgable and helpful community about using PostgreSQL with AOLserver
|
AOLserver documentation
|
PostgreSQL documentation
|
Why use AOLserver instead of Apache?
|
Why use PostgreSQL instead of MySQL?
|