2 installations on same system

2 installations on same system

by Lars Jensen -
Number of replies: 3
Is it possible to have two webwork installations on the same webwork system, without experiencing any interference?

We have webwork installed in /opt/webwork/webwork2, /opt/webwork/pg, etc. -I was wondering if I can install a second instance of webwork in a  /opt/wwktest/webwork2, /opt/wwktest/pg, etc.  directory, with its own database, of course.

The reason I may want to do this is to test cvs updates on the wwktest instance of webwork before I do the updates on out production system.

In reply to Lars Jensen

Re: 2 installations on same system

by Sam Hathaway -
Hi Lars,

If you run two versions of WeBWorK under the same Apache instance, you'll end up with a mix of the two versions. This is because mod_perl loads Perl modules globally, and once one version of a module is loaded it won't be loaded again.

You can, however, run a second instance of Apache on a different port. This is what we do on our development machine. Take a look at these files in the WeBWorK distribution:

  • conf/devel-site.apache2-config - Contains the directives that are shared among all development systems on our server.
  • conf/devel.apache2-config - Contains directives that are unique to a particular development system.
  • bin/wwapache2ctl - Script to start/stop/restart a private Apache instance.
You'll want to modify devel-site.apache2-config to contain the appropriate directives/paths/URLs for your installation of Apache. Consult your main Apache config file for hints. You'll also need to customize paths in bin/wwapache2ctl.

Let me know if you get stuck.
In reply to Sam Hathaway

Re: 2 installations on same system

by Boyd Duffee -
Hi Sam,

I've been trying to run an second instance of WebWork, so that I can play with 2.5 alongside the production version of 2.4.8 and after editing the above files, I get a Address already in use: make_sock: could not bind to address. I've even gone and created another ip address on the loopback for it to listen on, but still the same error. This is all while the production version is running.

Any hints on where to look next?
In reply to Boyd Duffee

Re: 2 installations on same system

by Dick Lane -
The command
    apache2ctl  graceful
will generate such an error from make_sock (and mention not opening log files).

The fix for this particular issue is running the command as privileged, e.g.,
    sudo  apache2ctl  graceful

I do not know whether that will suffice for your larger objective.