Can't upload files larger than ~120kb

Can't upload files larger than ~120kb

by Igor Lekic -
Number of replies: 3
Hi,
I'm having strange problem with Moodle 3.0.2. we have done migration from sared hosting to dedicated server on our faculty with upgrade and sinc then teachers can't upload files larger than ~130kb. Permissions are ok for moodledata, and php.ini is PHP Version 5.5.9-1ubuntu4.14, php.ini file is attached https://moodle.org/pluginfile.php/114/mod_forum/post/1321153/PHP%20Version%205.doc
All setings are set to max upload file size.

Debugging doesn't show any related erors, it show tvo warnings:

Warning: is_readable(): open_basedir restriction in effect. File(/proc/loadavg) is not within the allowed path(s): (/var/www/clients/client1/web1/web:/var/www/clients/client1/web1/private:/var/www/clients/client1/web1/tmp:/var/www/e-learning.ff.uns.ac.rs/web:/srv/www/e-learning.ff.uns.ac.rs/web:/usr/share/php5:/usr/share/php:/tmp:/usr/share/phpmyadmin:/etc/phpmyadmin:/var/lib/phpmyadmin) in /var/www/clients/client1/web1/web/lib/moodlelib.php on line 8849

Warning: is_executable(): open_basedir restriction in effect. File(/usr/bin/uptime) is not within the allowed path(s): (/var/www/clients/client1/web1/web:/var/www/clients/client1/web1/private:/var/www/clients/client1/web1/tmp:/var/www/e-learning.ff.uns.ac.rs/web:/srv/www/e-learning.ff.uns.ac.rs/web:/usr/share/php5:/usr/share/php:/tmp:/usr/share/phpmyadmin:/etc/phpmyadmin:/var/lib/phpmyadmin) in /var/www/clients/client1/web1/web/lib/moodlelib.php on line 8852

Firebug show error 500:
POST http://e-learning.ff.uns.ac.rs/course/dndupload.php 500 (Internal Server Error)
M.course_dndupload.upload_file @ dndupload.js:1panel.addButton.action @ dndupload.js:1e.Subscriber._notify @ yui_combo.php?rollup/3.17.2/yui-moodlesimple-min.js&rollup/1455923560/mcore-min.js:40e.Subscriber.notify @ yui_combo.php?rollup/3.17.2/yui-moodlesimple-min.js&rollup/1455923560/mcore-min.js:40e.CustomEvent._notify @ yui_combo.php?rollup/3.17.2/yui-moodlesimple-min.js&rollup/1455923560/mcore-min.js:39e.CustomEvent._procSubs @ yui_combo.php?rollup/3.17.2/yui-moodlesimple-min.js&rollup/1455923560/mcore-min.js:39e.CustomEvent.fireSimple @ yui_combo.php?rollup/3.17.2/yui-moodlesimple-min.js&rollup/1455923560/mcore-min.js:39e.CustomEvent._fire @ yui_combo.php?rollup/3.17.2/yui-moodlesimple-min.js&rollup/1455923560/mcore-min.js:39e.CustomEvent.fire @ yui_combo.php?rollup/3.17.2/yui-moodlesimple-min.js&rollup/1455923560/mcore-min.js:39a.fn @ yui_combo.php?rollup/3.17.2/yui-moodlesimple-min.js&rollup/1455923560/mcore-min.js:115


Beside this every thing else is working as it should.

Can smeone please help me with this?


Average of ratings: -
In reply to Igor Lekic

Re: Can't upload files larger than ~120kb

by Gareth J Barnard -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers

Have a look at both the PHP and Web server max upload size type directives - there are two to configure.  Also look in the PHP / Web server logs for error messages.

Average of ratings: Useful (1)
In reply to Gareth J Barnard

Re: Can't upload files larger than ~120kb

by Derek Chirnside -

Gareth is right, and there is even more information here: https://docs.moodle.org/30/en/File_upload_size

The fact that it is ~130 suggests there is one setting you have missed.

-Derek

Average of ratings: Useful (1)
In reply to Derek Chirnside

Re: Can't upload files larger than ~120kb

by Igor Lekic -

Thank you booth for tips, I have found a problem, it was in Apache host configuration, I added 

FcgidMaxRequestLen 268435456
FcgidConnectTimeout 360

to mod_fcgid.c and now we can upload larger files.