There's a bug in some PHP versions on Linux (and probaly other Unices aswell) where disk_free_space returns false when the free space is very large (larger than what can be stored in a C long int variable). In that case, even if you have tons of free space, it simply returns false (i.e., no free space at all).
If you are really sure you have free space in the partition that holds your $CFG->datatroot directory, then edit lib/setup.php and comment out the following lines of code (it seems they are going to be removed in the 1.9.x version anyway, see MDL-19222):
// Need to disable debugging since disk_free_space()
// will fail on very large partitions (see MDL-19222)
$freespace = @disk_free_space($CFG->dataroot.'/sessions');
if (!($freespace > 2048) and $freespace !== false) {
echo '<html><body>';
echo '<table align="center"><tr>';
echo '<td style="color:#990000; text-align:center; font-size:large; border-width:1px; '.
' border-color:#000000; border-style:solid; border-radius: 20px; border-collapse: collapse; '.
' -moz-border-radius: 20px; padding: 15px">';
echo '<p>The session partition is full. It is not possible to login at this time.</p>';
echo '<p>Please notify server administrator.</p>';
echo '</td></tr></table>';
echo '</body></html>';
die;
}
Saludos. Iñaki.
I've solved the problem by editing the lib/setup.php. Only delete this lines:
//// LINE 423 TO 434 /////
if (!(disk_free_space($CFG->dataroot.'/sessions') > 0)) {
echo '<html><body>';
echo '<table align="center"><tr>';
echo '<td style="color:#990000; text-align:center; font-size:large; border-width:1px; '.
' border-color:#000000; border-style:solid; border-radius: 20px; border-collapse: collapse; '.
' -moz-border-radius: 20px; padding: 15px">';
echo '<p>The session partition is full. It is not possible to login at this time.</p>';
echo '<p>Please notify server administrator.</p>';
echo '</td></tr></table>';
echo '</body></html>';
die;
}
And it will continue installing normaly.
I had the same problem this morning while upgrading from 1.9.6 to 2.0.2.
I located the code that needs to be disabled in \lib\sessionlib.php
After disabling lines 345 to 347 the install proceded normally.
The lines to comment out are:
if (!($freespace > 2048) and $freespace !== false) {
print_error('sessiondiskfull', 'error');
}
I hope that this helps someone.
Not surprising considering that the message was posted three years ago. Try:
What that says is to change line 345 in /lib/sessionlib.php
from
345: if (!($freespace > 2048) and $freespace !== false) {
to
if (!($freespace > 2048) and $freespace !== false and $freespace !== null)
which seems cleaner than just commenting out the whole error message suggested above. Thanks!