Installation help

 
 
Picture of Ivan Heran
After upgrade 1.9 - > 2.2 -> 2.3.1 - upload problem
 

Hi, after upgrade to 2.3.1 I cannot upload files. Each time receiving:

Error: The file ..... has no data in it - did you try to upload a folder?


I think permissions to folder moodledata is ok, in previous versions everything worked. Using Apache2 on Ubuntu server.

Any suggestions. Thank you.

 
Average of ratings: -
Picture of Helen Foster
Re: After upgrade 1.9 - > 2.2 -> 2.3.1 - upload problem
Group DevelopersGroup Documentation writersGroup Moodle HQGroup Particularly helpful MoodlersGroup Testers

Hi Ivan,

I've tried searching moodle.org and the Moodle Tracker for the error you mention and came up with no results at all, apart from your forum post and issue report MDL-34681. Tons of sites have upgraded 1.9 -> 2.2 -> 2.3.1 so it's very weird that nobody else has come across the same problem. Can you think of anything at all which might have caused it? Did you follow the Upgrading documentation exactly? Unfortunately developers won't be able to investigate MDL-34681 unless they have a way of reliably reproducing the problem.


 

 
Average of ratings: -
Picture of Ivan Heran
Re: After upgrade 1.9 - > 2.2 -> 2.3.1 - upload problem
 

Hi Helen,

thanks for your information. I tried to change many parameters and settings in according with upgrade documents, but no success. It is frustrating, that this kind of error message is not possible to find in forum or on the internet. I cannot beleive, that I am the first one, who received this message.

I will continue with research, if no success, I will be unhappy, but I have to go back to 1.9  sad

Ivan

 
Average of ratings: -
Gmads
Re: After upgrade 1.9 - > 2.2 -> 2.3.1 - upload problem
Group Particularly helpful MoodlersGroup Testers

Hi Ivan,

The problem you're having might be caused because the server is imposing a limit on the file upload size. Here are some suggestions:

  • Turn on debugging: http://docs.moodle.org/23/en/Debugging.
  • Check your server logs.
  • Go to Site administration > Server > PHP info, and check the values of the upload_max_filesize and the post_max_size parameters.
  • If you have access to the php.ini configuration file, you could increase those values, for example:
    • upload_max_filesize = 64M
    • post_max_size = 64M
  • If you cannot access that file, but your server allows using a custom php.ini file, you could create one at your moodle installation folder with the aforementioned two lines.
  • If you cannot create a custom php.ini file, but your server allows using an .htaccess (dot htaccess) file, you could create one at your moodle installation folder with the following two lines:
    • php_value upload_max_filesize 64M
    • php_value post_max_size 64M

Hope this helps. 

 
Average of ratings: -
Picture of Ivan Heran
Re: After upgrade 1.9 - > 2.2 -> 2.3.1 - upload problem
 

Hi, thanks for your reccomendation, I had these values set to 50M, changed it to 64M, but certainly no effect, because I am trying to upload very small PDF files and the error message is still the same sad

 
Average of ratings: -
Picture of Howard Miller
Re: After upgrade 1.9 - > 2.2 -> 2.3.1 - upload problem
Group DevelopersGroup Documentation writersGroup Particularly helpful Moodlers
The little routine that generates that error has this comment at the top
 
* Checks the contents of the given file is not completely NULL - this can happen if a
* user drags & drops a folder onto a filemanager / filepicker element


You might want to turn on Debugging and see if you get further warnings or notices.
 
Average of ratings: -
Picture of Thelma Polanco-Perez
Re: After upgrade 1.9 - > 2.2 -> 2.3.1 - upload problem
 

Hi Howard,

So that means that Moodle 2.3.1 doesn't allow you drag & drop folders? If I drag any individual or multiple files the system works fine but if I drag a folder I got an error (see image)

Thanks,
Thelma smile


 
Average of ratings: -
Martin in black and white
Re: After upgrade 1.9 - > 2.2 -> 2.3.1 - upload problem
Group DevelopersGroup Documentation writersGroup Moodle HQGroup Particularly helpful MoodlersGroup Testers

Correct - you can not drag a folder into Moodle.  This is actually a restriction of the browser technology, not Moodle itself.  There is no way we can implement support for that until the browsers support it.

 
Average of ratings:Useful (1)
Picture of Thelma Polanco-Perez
Re: After upgrade 1.9 - > 2.2 -> 2.3.1 - upload problem
 

Hi Martin,

Thanks for getting back on this issue. We're live on 2.3.1 now and were wondering if that could be possible as we'll start workshops and training for our faculty.

It was good to see you @the Moot!

Thelma

 
Average of ratings: -
Picture of Alexey Neizvestny
Re: After upgrade 1.9 - > 2.2 -> 2.3.1 - upload problem
 

I think the problem in access right to temporary directory for HTTP uploaded files. Check php.ini -> upload_tmp_dir

upload_tmp_dir

 
Average of ratings:Useful (1)
Picture of Ivan Heran
Re: After upgrade 1.9 - > 2.2 -> 2.3.1 - upload problem
 

Thanks for your reccomendation. My upload folder is /tmp (in php.ini upload_tmp_dir variable), there are rights 40777, it was th same in previous version and everything worked sad

 
Average of ratings: -
Picture of Ivan Heran
Re: After upgrade 1.9 - > 2.2 -> 2.3.1 - upload problem
 

The problem was found:

Thanks for all your posts. In full debugging mode I found the problem. It was open_basedir restriction, which was protecting /tmp folder and it was not accessible !!! When I changed upload_tmp_dir in php.ini to  ..... /moodledata/temp , upload was working.

I have no idea, why this was not a problem in Moodle 1.9.x, anyway, finally I used  ....open_basedir "/var/www/moodle/moodledata:/tmp" and no need to chage upload_tmp_dir in php.ini.

Thanks.

Ivan

 
Average of ratings:Useful (2)
Picture of Lucas Taylor
Re: After upgrade 1.9 - > 2.2 -> 2.3.1 - upload problem
 

Hey, i have the same problem, but i dont know where did you find "open_basedir", where are this value ?

Please, its urgent. I cant upload files, where i find the file to change the open_basedir ?

 
Average of ratings: -