Installation

Ubuntu 18.04 apache2 crashes on startup (double free)

Ubuntu 18.04 apache2 crashes on startup (double free)

by Richard Humphrey -
Number of replies: 3
Hello-
I am doing a new install of Webwork on Ubuntu 18.04.3 with apache 2.4.29 and now that everything is in place, when I start the apache2 service it crashes.

In /var/log/apache2/error.log
There is just one line,
double free or corruption (!prev)

I've pasted the syslog error at the bottom of this post.

We've installed the mysql database from our old webwork install, all the dependencies have been met.

I have run /opt/webwork/webwork2/bin/check_modules.pl
and all modules are present, although there is one error on json:

Iterator::Util found and loaded
Prototype mismatch: sub main::from_json: none vs ($@) at (eval 427) line 1.
Prototype mismatch: sub main::to_json: none vs ($@) at (eval 427) line 1.
JSON found and loaded

I'm including the webwork config file for apache 2.4 manually at the end of /etc/apache2/apache2.conf The file is unmodified from the git repo.

There just isn't enough enough info in these errors for me to proceed.

Since this is on a very standard version of Linux, I can imagine that a lot of people are seeing this error and maybe there is an easy fix.

Does anyone have any ideas? (HELP!)

Thanks!
=Rich Humphrey
System Administrator, Cornell Math Dept.

Syslog error:

systemd[1]: Starting The Apache HTTP Server...
Jan 8 16:16:45 webwork2 apachectl[6328]: webwork.apache2-config: WeBWorK server is starting
Jan 8 16:16:45 webwork2 apachectl[6328]: webwork.apache2-config: WeBWorK root directory set to /opt/webwork/webwork2 in webwork2/conf/webwork.apache2-config
Jan 8 16:16:45 webwork2 apachectl[6328]: webwork.apache2-config: The following locations and urls are set in webwork2/conf/site.conf
Jan 8 16:16:45 webwork2 apachectl[6328]: webwork.apache2-config: PG root directory set to /opt/webwork/pg
Jan 8 16:16:45 webwork2 apachectl[6328]: webwork.apache2-config: WeBWorK server userID is www-data
Jan 8 16:16:45 webwork2 apachectl[6328]: webwork.apache2-config: WeBWorK server groupID is www-data
Jan 8 16:16:45 webwork2 apachectl[6328]: webwork.apache2-config: The webwork url on this site is https://webwork2.math.cornell.edu/webwork2
Jan 8 16:16:45 webwork2 apachectl[6328]: webwork.apache2-config: The webwork smtp server address is mail.math.cornell.edu
Jan 8 16:16:45 webwork2 apachectl[6328]: webwork.apache2-config: The webwork smtp server port is 25
Jan 8 16:16:45 webwork2 apachectl[6328]: webwork.apache2-config: The webwork smtp server protocol is 'not ssl'
Jan 8 16:16:45 webwork2 apachectl[6328]: Check in with MAA site
Jan 8 16:16:45 webwork2 apachectl[6328]: PING webwork.maa.org (38.81.195.209) 100(128) bytes of data.
Jan 8 16:16:45 webwork2 apachectl[6328]: 108 bytes from webwork.maa.org (38.81.195.209): icmp_seq=1 ttl=51 time=19.1 ms
Jan 8 16:16:45 webwork2 apachectl[6328]: --- webwork.maa.org ping statistics ---
Jan 8 16:16:45 webwork2 apachectl[6328]: 1 packets transmitted, 1 received, 0% packet loss, time 0ms
Jan 8 16:16:45 webwork2 apachectl[6328]: rtt min/avg/max/mdev = 19.164/19.164/19.164/0.000 ms
Jan 8 16:16:46 webwork2 apachectl[6328]: Aborted (core dumped)
Jan 8 16:16:46 webwork2 apachectl[6328]: Action 'start' failed.
Jan 8 16:16:46 webwork2 apachectl[6328]: The Apache error log may have more information.
Jan 8 16:16:46 webwork2 systemd[1]: apache2.service: Control process exited, code=exited status=134
Jan 8 16:16:46 webwork2 systemd[1]: apache2.service: Failed with result 'exit-code'.
Jan 8 16:16:46 webwork2 systemd[1]: Failed to start The Apache HTTP Server.

In reply to Richard Humphrey

Re: Ubuntu 18.04 apache2 crashes on startup (double free)

by Richard Humphrey -
Hey-
I believe this part is solved, so rather than remove my request I'll post the solution, since finding it would have made my day a lot better.
I was going through the 'upgrading with github' instructions because this is an upgrade from an older webwork installation.
I looked through the instructions for "Installation Manual for 2.13 on Ubuntu 18.04"
and found a step I did not know about,

# a2dismod mpm_event
# a2enmod mpm_prefork

and related configs.

I did this part and the crash stopped happening.

Now going back and following all steps in the second document.

=Rich
In reply to Richard Humphrey

Re: Ubuntu 18.04 apache2 crashes on startup (double free)

by Arnold Pizer -
For your information, there is a new version of the installation instructions for WeBWorK version 2.15: http://webwork.maa.org/wiki/Installation_Manual_for_2.15_on_Ubuntu_18.04

Arnie