• Please be aware: Kaspersky Anti-Virus has been deprecated
    With the upgrade to Plesk Obsidian 18.0.64, "Kaspersky Anti-Virus for Servers" will be automatically removed from the servers it is installed on. We recommend that you migrate to Sophos Anti-Virus for Servers.
  • The Horde webmail has been deprecated. Its complete removal is scheduled for April 2025. For details and recommended actions, see the Feature and Deprecation Plan.
  • We’re working on enhancing the Monitoring feature in Plesk, and we could really use your expertise! If you’re open to sharing your experiences with server and website monitoring or providing feedback, we’d love to have a one-hour online meeting with you.

Question Dual Wordpress websites on single host - webpages mixed up - HowTo solve?

ipanini

New Pleskian
Server operating system version
Ubuntu 20.04.6 LTS
Plesk version and microupdate number
18.0.53
Hi folks,

Just very recently set up a virtual server that is using Plesk.
I'm working my way through finding and learning as I go.
Goals is to set up 2 Wordpress sites on a single (IP) server.

I'm maybe oldschool, but my initial plan was to do most of the setup from the command line using ssh. In a previous post I have been strongly urged not to do so, but instead let Plesk do the work. So I did, but now I'm running into some problems that I'd like some help to straighten out.

So first I got my DNS settings right, and after that I got two Let's Encrypt certificates, one for each site.
So far so good.

My problem at the moment is that the two websites get mixed up. In plain Apache2, I believe this should be configured in vhosts.
As a side effect, on the second wordpress site, I get a certificate warning / error because it has the (correct) certificate of the other site.
Can anyone point me in the direction on how to solve this issue?

Thanks a lot!
 
You can pick the SSL certificate that the domain uses on the Websites & Domains > Hosting & DNS > Hosting dialog. First thing you can check is whether both of your domains are using their own SSL certificate.

In case of Wordpress, Wordpress stores its own URL in its database (options table, siteurl and homepage datasets). Sometimes users duplicate an installation and forget to update these two datasets, so that the duplicated Wordpress site will use the correct URL. It is also possible that URLs have been entered statically into CSS, JS, PHP scripts and Wordpress plugins or themes. In that case, maybe your Wordpress loads some resources from the wrong domain?
 
You can pick the SSL certificate that the domain uses on the Websites & Domains > Hosting & DNS > Hosting dialog. First thing you can check is whether both of your domains are using their own SSL certificate.

In case of Wordpress, Wordpress stores its own URL in its database (options table, siteurl and homepage datasets). Sometimes users duplicate an installation and forget to update these two datasets, so that the duplicated Wordpress site will use the correct URL. It is also possible that URLs have been entered statically into CSS, JS, PHP scripts and Wordpress plugins or themes. In that case, maybe your Wordpress loads some resources from the wrong domain?
Thanks for replying!
Will look into it and report back.
It's quite confusing as it has been quite a hassle to get the DNS TXT records set up for the _acme-challenge records in order to get the Let's Encrypt certificates right. My main question there was how to be able to test them from the command line, but that problem has been solved, so no issues there.

I did notice a setting in the Settings for Apache Webserver (I translate from German, so may not be 200% correctly worded).
There I find all Apache-Modules.
One of those is vhost_alias.

As I would normally prefer to configure on the command-line instead of through Plesk, I'm not at all sure what this really does. (This option was not enabled when I did the setup.)

Apart from that, I did not copy one site to the second site, so that should not be the issue.
Any further information about vhost_alias and the fact that it was not enabled earlier is more than welcome!

Thanks for sticking with me!
 
I think I found DNS settings, under Tools & Settings.
I did not touch those yet, and they seem quite "empty".
I did all the DNS settings at my domain reseller + gratisdns.de.
Will look into it and report back!
 
My problem at the moment is that the two websites get mixed up. In plain Apache2, I believe this should be configured in vhosts.
As a side effect, on the second wordpress site, I get a certificate warning / error because it has the (correct) certificate of the other site.
How did you set that up? You do have two separate wordpress installations, right? I don't think multisite is supported by plesk yet.
 
How did you set that up? You do have two separate wordpress installations, right? I don't think multisite is supported by plesk yet.
Yes, two separate wordpress installations.
Off course it does support this, underneeth it is the webserver that does the work. See here for documentation.
 
Back
Top