• 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 7.5.2 killed suexec (cgi and perl) and PHP needed tweaking.

I

iMedia

Guest
Since upgrading to 7.5.2, I have been unable to execute cgi and perl scripts outside the users httpdocs --- in other words
/home/httpd/vhosts/<DOMAIN>/httpdocs/script.pl works fine.

/home/httpd/vhosts/<DOMAIN>/cgi-bin/script.pl doesn't.

All permissions and user:group settings have been checked and rechecked, both on scripts and on suexec.

I had a central location install for Awstats that worked great using:
/etc/httpd/conf.d/awstats.conf...

Alias /awstatsclasses "/usr/local/.../classes/"
Alias /awstatscss "/usr/local/.../css/"
Alias /awstatsicons "/usr/local/.../icon/"
ScriptAlias /awstats/ "/usr/local/.../cgi-bin/"

<Directory "/usr/local/...">
Options None
AllowOverride None
Order allow,deny
Allow from all
</Directory>

so... any cgi/perl script out of the users web root stopped working. And I've been unable to repair this using the traditional suexec troubleshooting methods.

Any notes from anyone else?

PS: My server provider has issued two trouble tickets and stated they are aware of this issue. Their response:
...they do know the problem with the suexec permissions with the plesk upgrade to 7.5....

ALSO: the Plesk 7.5.2 updater included PHP 4.3.10 but did not upgrade ioncube causing some functions in PHP, specifically foreach(), to fail --- due to security patches. Upgrading ioncube does the trick, but I simply commented out the mod.

This can be worked-around by commenting-out:
#zend_extension=/usr/lib/php4/ioncube_loader_lin_4.3.so in
#/etc/php.d/ioncube.ini

Any notes from others?
 
As I remember the .pl files inside webroot are managed by mod_perl. And files inside cgi-bin are managed by CGI and suexec.

If you want your .pl files to work inside cgi-bin directory, then check that you able to run this files through the command line. If you can then try accessing this script through the browser and then check suexec log file for the problems.
 
suexec

yes, I can run the scripts through the CLI.

I followed all troubleshooting procedures for suexec, .pl, and cgi, scripts 500 Internal Server Error.

suexec_log:

[2005-05-02 18:23:59]: command not in docroot (/usr/.../cgi-bin/awstats.pl)
[2005-05-02 18:31:53]: uid: (10012/joejp) gid: (10001/10001) cmd: awstats.pl

/conf.d/awstats.conf:

Alias /awstatsclasses "/usr/.../classes/"
Alias /awstatscss "/usr/.../css/"
Alias /awstatsicons "/usr/.../icon/"
ScriptAlias /awstats/ "/usr/.../cgi-bin/"

<Directory "/usr/...">
Options None
AllowOverride None
Order allow,deny
Allow from all
</Directory>

----

used to all work great. :(
 
I am having similar issues (off and on).

Plesk uses a different suexec. And if it gets overwrote or anything else your cgi is outside the doc root and wont work. If you run the script from shell it will work.

I had mine fixed but when I did the last updater it broke it again. Plesk said something about a compile problem and they would work on it.

Currently I have a domain that is driving me script errors. Not all my domains but this one. What is odd is that 755 seems to have more permission than 777.

If I 777 folders and mny test file, it gives me a 500 error. If I 755 them it runs.

I am just digging into this now, but I can assure you that your issues sound very similar to mine !

Rich
 
a solution

I had the same problem after doing an update on Plesk 8. The solution was to create a symbolic link.

/usr/sbin/suexec -> /usr/local/psa/suexec/psa-suexec
 
Back
Top