Failed to start The Apache HTTP Server

I did not uninstall it, I asked if uninstalling it could be the way but it seems not.

What’s next? No chance to recover?

This shows me that it was not installed. It was installed when you installed Virtualmin, so something changed…somebody or something uninstalled it, which broke your Apache. That’s not in question or under discussion…that’s absolutely what happened. How/why, I don’t know.

The new alarming thing is that a core Apache package seems to have also been uninstalled. Check it: dpkg -l apache2-bin

Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name           Version         Architecture Description
+++-==============-===============-============-===================================================
ii  apache2-bin    2.4.52-1ubuntu4 amd64        Apache HTTP Server (modules and other binary files)

Here it is the packages I have installed on Virtualmin:

I mean, I see installed. Are there any further steps which can be made to solve?

Hope it may help from error.log:

[Mon Nov 21 00:00:06.986602 2022] [mpm_event:notice] [pid 845:tid 139666938759040] AH00489: Apache/2.4.52 (Ubuntu) mod_fcgid/2.3.9 OpenSSL/3.0.2 configured -- resuming normal operations
[Mon Nov 21 00:00:06.986693 2022] [core:notice] [pid 845:tid 139666938759040] AH00094: Command line: '/usr/sbin/apache2'
[Mon Nov 21 15:41:11.931131 2022] [mpm_event:notice] [pid 845:tid 139666938759040] AH00493: SIGUSR1 received.  Doing graceful restart
[Mon Nov 21 15:41:13.518313 2022] [mpm_event:notice] [pid 845:tid 139666938759040] AH00489: Apache/2.4.52 (Ubuntu) mod_fcgid/2.3.9 OpenSSL/3.0.2 configured -- resuming normal operations
[Mon Nov 21 15:41:13.518366 2022] [core:notice] [pid 845:tid 139666938759040] AH00094: Command line: '/usr/sbin/apache2'
[Mon Nov 21 16:03:45.032209 2022] [mpm_event:notice] [pid 845:tid 139666938759040] AH00493: SIGUSR1 received.  Doing graceful restart
[Mon Nov 21 16:03:45.536368 2022] [mpm_event:notice] [pid 845:tid 139666938759040] AH00489: Apache/2.4.52 (Ubuntu) mod_fcgid/2.3.9 OpenSSL/3.0.2 configured -- resuming normal operations
[Mon Nov 21 16:03:45.536404 2022] [core:notice] [pid 845:tid 139666938759040] AH00094: Command line: '/usr/sbin/apache2'
[Tue Nov 22 08:54:28.448282 2022] [mpm_event:notice] [pid 845:tid 139666938759040] AH00491: caught SIGTERM, shutting down

If I had this problem on an RHEL-based server, I would try installing PHP-FPM for my installed PHP versions. But I don’t know if that will break the system even more on Ubuntu.

There are no errors in that error_log.

Are you still seeing errors about loading mpm when restarting it? That is, as far as I know, the problem we’re trying to figure out.

Joe, I had OP comment out the references to the fcgid module when I suspected it was calling FastCGI when he was using PHP-FPM.

And the following post.

That may need to be undone now.

Richard

If I try to enable sudo a2enmod mpm_event I get this:

Considering conflict mpm_worker for mpm_event:
ERROR: Module mpm_worker is enabled - cannot proceed due to conflicts. It needto be disabled first!
Considering conflict mpm_prefork for mpm_event:

Hope it may help.

Maybe sudo a2dismod mpm_event?

No promises.

Hi Richard

The module mpm_event is already disabled, the last output maybe suggests to disable mpm_worker module in order to get mpm_event running, isn’t it?

Yes, I believe you’re right. I’d still like to know where PHP-FPM went, though. Was this a routine update that trashed Apache?

Richard

Haha, I honestly don’t know, I’ve already shared the error log without success like the other shares. The problem is that it is unsolvable since not even the Staff knows which way to turn. At this point the solutions can be to reinstall Apache or Virtualmin or to migrate to other platforms.

You can’t just reinstall Virtualmin. It has to be installed on a clean minimal OS or you will just compound your problem by many orders of magnitude. Also, I doubt that it’s a Virtualmin problem. If it were, we’d have a bazillion people on the board with the same problem.

At this point I have to wonder whether there was a transitory problem with a repo, because none of this makes any sense.

You can reinstall Apache if you back up certain files that may need to be restored post-reinstall; but again, I have no idea where those files would live on Ubuntu.

Maybe @tpnsolutions or @calport can be of service. I’m not sure how familiar they are with Ubuntu, but I have no doubt that either of them are more knowledgeable about it than I am.

Richard

1 Like

If you were previously using mpm_event, you need to figure out why mpm_event isn’t loading. It doesn’t make sense to spend all this time getting further and further away from the configuration that was working previously. (And to do that you need to find where it’s failing to load in the log and solve whatever problem it has.)

Reinstalling Virtualmin can’t possibly do anything good. Virtualmin didn’t cause any of this, and reinstalling it will just break a bunch of new stuff (and you’ve already broken a couple of new things, it seems like).

That’s correct, do you know what/where to verify in order to make it clear?

In addition to the error_log, try:

apachectl configtest

But, you already know you don’t have any MPM. And, since you were using mpm_event, that’s the problem you need to be solving. This isn’t complicated…it’s just weird. I don’t know how you got here.

If you disabled mpm_event, undo that. Try to restart Apache. Look at the errors. Fix the errors. (And, try not to make new errors by randomly changing stuff without knowing why…)

Here it is theoutcome:

AH00534: apache2: Configuration error: No MPM loaded.
Action 'configtest' failed.
The Apache error log may have more information.

image

I did not touch any module until today in order to enable mpm_event

Again. WHY isn’t it loading?

Does it (mod_mpm_event.so) exist?

yes usr/lib/apache2/modules/mod_mpm_event.so