• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion
  • Inviting everyone to the UX test of a new security feature in the WP Toolkit
    For WordPress site owners, threats posed by hackers are ever-present. Because of this, we are developing a new security feature for the WP Toolkit. If the topic of WordPress website security is relevant to you, we would be grateful if you could share your experience and help us test the usability of this feature. We invite you to join us for a 1-hour online session via Google Meet. Select a convenient meeting time with our friendly UX staff here.

Issue Subdomain problem

Topkat

New Pleskian
Hi, I have a domain called example.com on Plesk Onyx 17.8.11 with CentOS Linux 7.6.1810. Yesterday I created a new domain called foo.com. The problem is that if I go to any subdomain on example.com such as xyz.example.com, it shows the homepage of foo.com (the new domain I just created).

I wasn’t able to add a new domain to Plesk until I ran the commands in the link below:

Unable to create object in Plesk: SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry for key 'PRIMARY'

What could be the problem? When I visit xyz.example.com, it says the SSL certificate is invalid because it’s using the certificate from foo.com.

I have tried deleting foo.com and adding it again, but I get the same problem.
 
Looks like database inconsistency. Have you tried to fix it with

# plesk repair db

oк with solutions from mentioned KB article?
 
Thanks for your reply. I ran "plesk repair db" yesterday and it repaired the table. I ran the command again just now and it said the db is ok, but I still have the problem.

# plesk repair db

Warning: Current locale is unusable. Using 'C' instead.

Checking the Plesk database using the native database server tools .. [OK]

Checking the structure of the Plesk database ........................ [OK]

Checking the consistency of the Plesk database ...................... [OK]

Error messages: 0; Warnings: 0; Errors resolved: 0

What is the warning for?
 
Last edited:
I also have a wildcard subdomain for example.com (*.example.com) that used to forwards to the main domain (example.com). After running the auto_increment_fix update to add an extra domain, the wildcard subdomain for *.example.com displays *.example.com in the address bar, but shows foo.com's homepage.

Could I edit something in the psa database to fix the problem?

I removed my wildcard subdomain from example.com and then added it again, but the same problem persists.
 
Last edited:
I'd suggest you contact Plesk Support Team for fixing this issue directly on your Plesk server or in Plesk database.
 
Back
Top