• Our team is looking to connect with folks who use email services provided by Plesk, or a premium service. If you'd like to be part of the discovery process and share your experiences, we invite you to complete this short screening survey. If your responses match the persona we are looking for, you'll receive a link to schedule a call at your convenience. We look forward to hearing from you!
  • We are looking for U.S.-based freelancer or agency working with SEO or WordPress for a quick 30-min interviews to gather feedback on XOVI, a successful German SEO tool we’re looking to launch in the U.S.
    If you qualify and participate, you’ll receive a $30 Amazon gift card as a thank-you. Please apply here. Thanks for helping shape a better SEO product for agencies!
  • The BIND DNS server has already been deprecated and removed from Plesk for Windows.
    If a Plesk for Windows server is still using BIND, the upgrade to Plesk Obsidian 18.0.70 will be unavailable until the administrator switches the DNS server to Microsoft DNS. We strongly recommend transitioning to Microsoft DNS within the next 6 weeks, before the Plesk 18.0.70 release.
  • The Horde component is removed from Plesk Installer. We recommend switching to another webmail software supported in Plesk.

vhost.conf file in PLESK not working as intended

S

Saif Bechan

Guest
I have configured a vhost file for my domain but it does not seem to work. These are the steps I took, please correct me if I am wrong.

First I made a file called vhost.conf in:

/var/www/vhosts/*domain*/conf/vhost.conf

The content of the vhost file looks like this:

<Directory /var/www/vhosts/*domain*/httpdocs>
php_admin_flag engine on
php_admin_flag display_errors on
</Directory>

Now in my /etc/php.ini i set display_errors=Off

After everything i rebuild with: /usr/local/psa/admin/sbin/websrvmng -a

But I don't see the any errors in my page. When i turn on the display_errors in /etc/php.ini only then can I see the errors.

I know for a fact that the vhost file is read, because when i type nonsense values i get an error when restarting apache saying there are errors in the vhost file.

Anyone know what the problem can be.

Should there be special settings in either the php.ini file or the httpd.conf file.

The httpd.conf i edit is in /etc/httpd/conf/httpd.conf. Is this the file that PLESK uses or is there another, because the values i see there do not really reflect the http folders of my domain. The httpd file looks like this now.


DocumentRoot "/var/www/html"

<Directory />
Order Deny,Allow
Deny from all
Options None
AllowOverride None
</Directory>

<Directory "/var/www/html">
Options None
AllowOverride None
Order allow,deny
Allow from all
</Directory>

Only this directory /var/www/html is not used by me, I use the directory /var/www/vhosts. The only folder found in /var/www/html is a folder called awstats. Does plesk use any other httpd.conf file i should know of.

I hope this all makes sense to anyone, and i hope i can find a solution
 
I found out what the problem is. I am running on FastCGI. When running fastCGI the php_admin_flags are ignored for some reason. There are some post to solve this problem, but neither of them offer an out-of-the-box solution to this.

Anyone have any suggestions on this.
 
Back
Top