• 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

open_basedir restriction to /tmp ... all web based uploads broken since update

ShoneA

Basic Pleskian
As the title says, all the web based uploads on our server has been broken since we upgraded to plesk 10 on friday.

osCommerce error example:
---------------------------------
PHP Warning: file_exists() : open_basedir restriction in effect. File(/...path/httpdocs/install) is not within the allowed path(s): (/...path/httpdocs/:/tmp/) in /...path/httpdocs/includes/header.php on line 15

WordPress error example:
---------------------------------
PHP Warning: file_exists() : open_basedir restriction in effect. File(/...path/httpdocs/.maintenance) is not within the allowed path(s): (/...path/httpdocs/:/tmp/) in /...path/httpdocs/wp-includes/load.php on line 142

Only strange thing I noticed was the /tmp folder was owned by one of the users in the plesk account, but I'm not sure if that was like that before. Our other server has root as the owner, still running Plesk 9.5.

Side note: I'm not sure why it's looking at an install directory in that error. I should mention that I receive no errors at all when the uploads fail. The page just loads as usual but nothing changes.

Does anyone know how to solve this issue?
 
Last edited:
edit: sorry wrong answer
 
Last edited by a moderator:
I just noticed that sessions are being stored just fine as of now, it's only web based file uploads that fail, like in wordpress the error is:

file.jpg has failed to upload due to an error
Missing a temporary folder.
 
We managed to fix web based uploads by defining the /tmp folder in php.ini (double checked phpinfo() and it really wasn't defined). But we are still getting those same errors in the log files and we have a php bulk email system named ListMessenger that is unable to tell if the directory set has it's files in it. It errors saying:

"The ListMessenger Directory Path you have entered does not exist or is unreadable by PHP. Please enter the full directory path from root, to your ListMessenger directory to update this preference."

The correct path is the same and confirmed to be correct, and used to work prior to this upgrade.


UPDATE: It seems this problem is being caused by us running a custom build of php that's outdated. I didn't actually know that at the time, so I have to get it upgraded and test then.
 
Last edited:
Try to change Php Apache Module in Php Application CGI in Plesk Hosting & Domain Settings for this domain. I have same problem if i choose php in Apache Module but if change then work currectly...

Send feedback! Have a nice day!
 
Back
Top