Installation

Apache fails to start

Apache fails to start

by Eric Stroyan -
Number of replies: 2
I'm having a bit of a problem installing.
I've checked, and I think I've got all configuration files set.
On trying to start apache I get:

Syntax error on line 190 of /usr/opt/webwork/webwork2/conf/webwork.apache-config:
renderViaXMLRPC.pm requires that the top WeBWorK directory be set in $WeBWorK::Constants::WEBWORK_DIRECTORY by webwork.apache-config or webwork.apache2-config
Compilation failed in require at (eval 978) line 3.
BEGIN failed--compilation aborted at /usr/opt/webwork/webwork2/lib/WeBWorK.pm line 86.
Compilation failed in require at /usr/opt/webwork/webwork2/lib/Apache/WeBWorK.pm line 35.
BEGIN failed--compilation aborted at /usr/opt/webwork/webwork2/lib/Apache/WeBWorK.pm line 35.
Compilation failed in require at /usr/opt/webwork/webwork2/conf/webwork.apache-config line 50.

/usr/local/sbin/apachectl start: httpd could not be started

any ideas?
Thanks.
In reply to Eric Stroyan

Re: Apache fails to start

by Michael Gage -
Try adding this to your webwork.apache-config file.

# Set this variable to the path to your WeBWorK installation.
my $webwork_dir = "/opt/webwork/webwork2";

# Cache this value for use by other scripts not necessarily in the Apache2 hierarchy
# Different scripts use different locations :-)

$ENV{WEBWORK_ROOT} = $webwork_dir;
$WeBWorK::SeedCE{webwork_dir} = $webwork_dir;
$WeBWorK::Constants::WEBWORK_DIRECTORY = $webwork_dir;


near the top. (See webwork.apache2-config.dist for comparison).


I'm afraid we haven't been testing the webwork.apache-config.dist adequately since many installations (and the developers) are now using apache2. Let me know if there are still difficulties.

I have uploaded this fix to trunk, so you should be able to download a new copy of webwork.apache-config with this change in it.

--Mike


In reply to Michael Gage

Re: Apache fails to start

by Eric Stroyan -
That seems to have done the trick!
I probably should move over to apache2, but old habits die hard!
Thanks again. You have made many students very happy, though they do not know it yet!