• 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

Plesk doesn't serve VirtualHosts on port 80

X

xanadu.dm

Guest
We just installed plesk 8.6 for linux on our RHEL 5.2 server.

However if we create a domain in Plesk it doesn't serve the domain.

To further investigate the problem I would need some help:

1) Should there be a "Listen 80" in the config files /etc/httpd/conf/httpd.conf or in /usr/local/psa/admin/conf/httpsd.conf ? I think it should be as otherwise you can't telnet to port 80.
Normally, should the installer add this? In the httpsd.conf file it says you shouldn't edit that file. However I didn't find an option to do it via the web-admin interface.
2) What other steps should you do so the vhosts httpd.include files are processed so it serves vhosts?

this is a part of the content from the file httpsd.conf:

#Listen 3000
#Listen 12.34.56.78:80
Listen 8443
Listen 8880

#
# BindAddress: You can support virtual hosts with this option. This directive
# is used to tell the server which IP address to listen to. It can either
# contain "*", an IP address, or a fully qualified Internet domain name.
# See also the <VirtualHost> and Listen directives.
#
#BindAddress *

As you can see there is no "Listen 80" defined here. Also the BindAddress * is commented out, shouldn't this be enabled as well? I also miss a section "NameVirtualHost *", or isn't this needed with plesk.

Thanks.
 
httpsd is the webserver for the Plesk web interface (https on port 8443), httpd is the webserver for your sites (http on port 80, https on port 443). 'Listen 80' should be in /etc/httpd/conf/httpd.conf, not in httpsd.conf.

You shouldn't need to edit any of these files yourself if everything was installed correctly. Is httpd running?
 
Thank you for the information. I uncommented the #Listen 80 now. telnet to port 80 works so that's ok.
However could someone post his/her httpd.conf so I can check if I'm missing anything else?
I just created a domain without SSL and want it to be recognised as a virtual host.
 
The virtual hosts are not defined in httpd.conf, they are defined in the conf/httpd.include files in a domain's home directory which are included in /etc/httpd/conf.d/zz010_psa_httpd.conf. You shouldn't edit any of these files manually.

Is DNS working for the domain you created?
 
Thanks, things start to clear up how the config is done.

this is what i get in the /var/log/httpd/error_log when starting psa.

[notice] suEXEC mechanism enabled (wrapper: /usr/sbin/suexec)
[Fri Aug 29 13:07:54 2008] [warn] RSA server certificate CommonName (CN) `plesk' does NOT match server name!?
[Fri Aug 29 13:07:54 2008] [warn] RSA server certificate CommonName (CN) `plesk' does NOT match server name!?
[Fri Aug 29 13:07:54 2008] [warn] Init: SSL server IP/port conflict: default-172-16-7-10:443 (/etc/httpd/conf.d/zz010_psa_httpd.conf:78) vs. webmail:443 (/etc/httpd/conf.d/zz010_psa_httpd.conf:133)
[Fri Aug 29 13:07:54 2008] [warn] Init: You should not use name-based virtual hosts in conjunction with SSL!!
[Fri Aug 29 13:07:54 2008] [notice] Digest: generating secret for digest authentication ...
[Fri Aug 29 13:07:54 2008] [notice] Digest: done
[Fri Aug 29 13:07:54 2008] [notice] mod_bw : Memory Allocated 0 bytes (each conf takes 28 bytes)
[Fri Aug 29 13:07:54 2008] [notice] mod_bw : Version 0.8 - Initialized [0 Confs]
PHP Fatal error: [ionCube Loader] The Loader must appear as the first entry in the php.ini file in Unknown on line 0

The server is configured with two ethernet interface which are bonded to bond0 (ip 172.16.7.10).
Should I alter my configuration to get this working?

I'm testing from a Windows server in the same network where I have edited the windows hosts file to point the domains I created to the ip of the webserver (172.16.7.10). So DNS shouldn't be the problem (a ping point the correct ip for the domain).
 
this is what i get in the /var/log/httpd/error_log when starting psa.

/var/log/httpd/error_log is the error log for the apache serving your domains, not the error log for psa.

[Fri Aug 29 13:07:54 2008] [warn] Init: SSL server IP/port conflict: default-172-16-7-10:443 (/etc/httpd/conf.d/zz010_psa_httpd.conf:78) vs. webmail:443 (/etc/httpd/conf.d/zz010_psa_httpd.conf:133)
[Fri Aug 29 13:07:54 2008] [warn] Init: You should not use name-based virtual hosts in conjunction with SSL!!

Do you have any name-based virtual hosts in your /etc/httpd/conf.d/zz010_psa_httpd.conf? Ours don't have any.

PHP Fatal error: [ionCube Loader] The Loader must appear as the first entry in the php.ini file in Unknown on line 0

This doesn't look too good either.

The server is configured with two ethernet interface which are bonded to bond0 (ip 172.16.7.10).
Should I alter my configuration to get this working?

See Server > IP Addresses in Plesk and check if the correct interfaces and IP addresses are set up.
 
Finally figured out what the problem was, it had all to do with the following line from the error_log:

PHP Fatal error: [ionCube Loader] The Loader must appear as the first entry in the php.ini file in Unknown on line 0

At the end, apache wasn't fully loaded with Zend Optimizer functionality.
Found a solution here:

http://kb.odin.com/article_41_1520_en.html

Thanks for pointing me in the right direction!
 
Back
Top