Apache not serving virtual servers properly

Operating system|Ubuntu Linux 20.04.6|

Webmin version|2.101|

Usermin version|2.001|

Virtualmin version|7.8.2|

Hi,

I just updated the latest packages on my Ubuntu server and neither Apache or Dovecot servers would load.

I purged Apache and reinstalled and it has started. I can access virtualmin on port 10000 but cannot access the domain itself.

I cannot access my virtual servers and when I try to access the admin panel (of my wordpress site) it loads but gives an error that the server (at port 80) cannot be found. Something is not right with apache. Any guidance please?

I will worry about Dovecot later.

Geoff

:exploding_head:

So you deleted all of your configuration files, and replaced them with empty defaults…and you’re surprised your sites are gone?

To be clear, unless you have backups, or the config files in /etc/apache2/sites-available somehow survived the slaughter, you’ll need to disable and re-enable the website feature in all of your domains, and then reconfigure them with whatever customizations you’d made.

Of course I am surprised! The guidance didn’t mention that.

Now I have your attention, I was not able to log in earlier as although I could access forums.virtualmin.com, the login page on virtual min.com would not open. It’s working fine now.

Thanks Joe.

The config files have survived so how do I re-enable them?

I have copied one of the config files from sites-available to sites-enabled but as soon as I do and reboot apache, it once again will not start which is the problem I had immediately after updating the packages.

So how do I get it re-established?

less /var/log/apache2/error.log

Does that show anything that helps?

OK, I think I have cracked it. Each time I tried to restart apache2 it refused because (I finally realised) the relevant module for the instruction in the config file was not enabled. I slowly worked through the config file after each attempted restart enabling the listed module until eventually it restarted without error. The website is back live.

I now just need to enable all the others.

Thanks.

Geoff

You shouldn’t copy it, you should use a2en. Or just create a symbolic link (which is what a2en does).

Did you purge any other packages? (And, to be clear: uninstalling packages that you need is always a bad idea! Purging them is even worse of an idea.)

Joe,

I am suitably admonished. I did use a2en and a2dis to manage the restructuring.

I now need to get dovecote going. I will investigate myself and come back if I get stuck.

Geoff

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.