Websites are showing default Apache page with custom vhosts template

Created:

2016-11-16 13:20:50 UTC

Modified:

2017-08-08 13:44:13 UTC

0

Was this article helpful?


Have more questions?

Submit a request

Websites are showing default Apache page with custom vhosts template

Applicable to:

  • Plesk 12.5 for Linux

Symptoms

Websites are showing default Apache (not Plesk) page.
Solution from article #213934145 does not help, but configuration files got created successfully.
Apache is running on default ports:

# netstat -ntpl | grep httpd
tcp 0 0 :::80 :::* LISTEN 31430/httpd
tcp 0 0 :::443 :::* LISTEN 31430/httpd

Output of apache settings from the configuration file returns the following:

# httpd -S
VirtualHost configuration:
xxx.xxx.xxx.xxx:8080 is a NameVirtualHost
default server default (/etc/httpd/conf/plesk.conf.d/server.conf:74)
port 8080 namevhost default (/etc/httpd/conf/plesk.conf.d/server.conf:74)
port 8080 namevhost lists (/etc/httpd/conf/plesk.conf.d/server.conf:290)
wild alias lists.*
port 8080 namevhost domain.tld (/etc/httpd/conf/plesk.conf.d/vhosts/domain.tld.conf:97)
alias www.domain.tld
alias ipv4.domain.tld
port 8080 namevhost example.com (/etc/httpd/conf/plesk.conf.d/vhosts/example.com.conf:97)
alias www.example.com
alias ipv4.example.com

Cause

Incorrect custom configuration templates.

Resolution

  1. Find what configuration templates contain information about ports, use httpd -S to find port values (8080 and 8081 in this example):

    # egrep -HR '8080|8081' /usr/local/psa/admin/conf/ | cut -d: -f1
    /usr/local/psa/admin/conf/templates/custom/server/vhosts.php
    /usr/local/psa/admin/conf/templates/custom/server.php
    /usr/local/psa/admin/conf/templates/custom/server/nameVirtualHost.php
  2. Update configuration templates with proper port values or force Plesk to use default templates by renaming /usr/local/psa/admin/conf/templates/custom directory.

  3. Re-create Apache configuration files:

    # /usr/local/psa/admin/bin/httpdmng --reconfigure-all
Have more questions? Submit a request
Please sign in to leave a comment.