I am using cakephp 2 and getting this error many time
Warning (2): session_start(): open(/var/cpanel/php/sessions/ea-php71/sess_b6d87a5fe83ae3af3d27866faeabac35, O_RDWR) failed: No space left on device (28) [CORE/Cake/Model/Datasource/CakeSession.php, line 743]
But my server have too much space
Current Disk Usage Information Device Size Used Available Percent Used Mount Point /dev/loop0 3.9G 8.4M 3.7G 1% /tmp /dev/sda1 1.8T 424G 1.3T 26% /
I restarted server but still getting same error
How to fix this issue ?
Advertisement
Answer
Solution
Set session path
ini_set('session.save_path',realpath(dirname($_SERVER['DOCUMENT_ROOT']) . '/tmp')); ini_set('session.gc_probability', 1); session_start();
http://php.net/manual/en/function.session-save-path.php
OR Update session path at php.ini
/opt/cpanel/ea-php71/root/etc/php.ini