• 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

Symlinks problem

N

northernpaul

Guest
Hi,

I have a Plesk server running a number of sites, and have had Awstats running fine for a number of months. The awstats scripts are stored in /usr/local, with symlinks created in each domain directory as as been shown elsewhere in the forums.

In the past couple of days, Awstats has stopped working, saying I don't have permissions to access /awstats/awstats.pl on the server, and additionally a 403 Forbidden error was encountered when trying to use an ErrorDocument.

I have checked through the vhosts.conf for the domains in question, checked the permissions in the awstats directories and even tried adding a .htaccess file with Option FolowSymLinks intothe domain root, and it still fails with the same error.

I'm out of ideas of where to look next, and don't know if there is maybe some master config that is overriding the settings that I think should be working (Apache's not my strongest point...)?

Any help greatly appreciated...
 
Did you ever get this issue fixed? We are having a similar issue but not for AwStats?
 
Sadly not. We ended up altering the Awstats install script so that it placed a copy of the scripts into the domain it was being installed under instead of using symlinks.

Sorry I can't be of much help...
 
Actually i did manage to figuire it out for anyone else looking in to this.

PLESK writes to the httpd.include files

By default plesk will not allow the +FollowSymlinks option.

So we need to create a custom file named vhost_ssl.conf since you are trying to modify the config for the https folder on the domain. If you simply need it for the httpdocs folder you would create a file named vhost.conf

This file is used when PLESK rebuilds the http.include files for each domain so that your changes do not get overwritten by PLESK.

So I added the file: /home/httpd/vhosts/domain.com/conf/vhost_ssl.conf

which contains the following;

---------------------------------------------------------------------------------------------
<Directory "/home/httpd/vhosts/domain.com/httpsdocs">
AllowOverride All
Options +FollowSymLinks
</Directory>
---------------------------------------------------------------------------------------------

After sending PLESK the command to rebuild the conf files

/usr/local/psa/admin/sbin/websrvmng -v -a

and restarting httpd all is good and working great!
 
Back
Top