CloudLinux PHP Failed to write session data

Created:

2017-06-07 21:14:58 UTC

Modified:

2017-08-16 16:45:27 UTC

0

Was this article helpful?


Have more questions?

Submit a request

CloudLinux PHP Failed to write session data

Applicable to:

  • Plesk for Linux

Symptoms

CloudLinux CageFS enabled for the subscription

Website log /var/www/vhosts/system/example.com/logs/error_log contains the following:

CONFIG_TEXT: PHP Warning : Unknown: Failed to write session data (files). Please verify that the current setting of session.save_path is correct (/var/lib/php/session) in Unknown on line

PHP sessions folder is created and permissions are normal.

PHP session path is correctly defined in php.ini

PHP handler assigned to domains isn't FastCGI.

Cause

CageFS skeleton /etc/cagefs/cagefs.mp does not contain session path

Resolution

Connect to the server using SSH

Edit /etc/cagefs/cagefs.mp adding /var/lib/php/session into common for all users section.

Remount CageFS skeleton directory:

# cagefsctl --remount-all

Have more questions? Submit a request
Please sign in to leave a comment.