Thursday, December 4, 2008

Moodle: Increasing Max File Upload Size

One of the first hurdles myself and other rookie Moodle implementers have to overcome is increasing the maximum file upload size. Moodle defaults to a measly 2 MB maximum file upload size which is pretty limiting. Through my research I found that many other people struggle with the same problem especially when Moodle is installed on a hosted non dedicated server which is the situation I am in. Here's a brief rundown of how I was able to increase the max file upload size for moodle on a hosted server.

The key to confusion is when you search for answers to this problem on Moodle forums most of the posts instruct to edit the "Max Upload Size" settings (there's 3 of them) in the php.ini file. Problem is that if you are on a hosted server sometimes you don't have access to this file through the Cpanel. But because of the fantastic Moodle community, I finally found more specific instructions for accomplishing this task on a hosted server.

On a hosted server you need to access these settings through FTP. By accessing Moodles files through FTP I was able to access both the .htaccess file and the php.ini file. Once I found the files it was easy to find the line of code to change. Many of the posts on Moodle forums recommend changing these settings in both the .ht access and php.ini files so make sure you check both. The screen shot below points out the files that contain these settings.

1 comment:

PK said...

Maybe it's good to point you have no guarantee you will find .htaccess or php.ini on your hosting.
Some hostings even prevent you to upload new .htaccess file, if you'll try, you'll get error no.500, server misconfiguration. In these cases you are totally and utterly dependent on the hosting admin.
But I am glad you had luck with changing upload size, sometimes it is little bit tedious :).