• 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

CGI Scripts only run in /cgi-bin/ subfolder

ryanz

Basic Pleskian
Hi,

We also have this problem where .cgi and .pl scripts only run in a /cgi-bin/subfolder and not in the root of the domains cgi-bin.

The permissions seem fine but when the file is copied from the cgi-bin root directly to the subdirectory it works perfectly.

Also tried to copy psa-suexec to /usr/sbin/suexec but no luck.

The domain error log shows this:
Premature end of script headers: filename.cgi

The suexec log shows this:
[2007-03-07 21:39:53]: uid: (10001/ftpuser) gid: (10001/10001) cmd: filename.cgi
[2007-03-07 21:39:53]: target uid/gid (10001/10001) mismatch with directory (10001/2523) or program (10001/10001)

I see some other users on this forum have the same problem.
 
Just a follow up on the above post.

The normal group permissions for the cgi-bin directory are:

drwxr-x--- ftpuser:psaserv cgi-bin

But I notice that the .cgi and .pl files will run from the cgi-bin root if you change the cgi-bin folder permissions to:

drwxr-x--- ftpuser:psacln cgi-bin

This means that none of our domains will work as it is and that we need to change the permissions on all of them.

Does anyone have feedback or comments on this to have suexec and cgi-bin work with ftpuser:psaserv
 
Hello,

You should try the following:

search for psa-suexec

replace your suexec with that.

Backup the suexec first:)
 
Back
Top