First and foremost, thanks for everyone's incredible work on this module. It's revolutionizing Drupal!

Context

I am building a podcast website. I need to upload MP3 files that are typically about 75Mb in size.

Structure

I have a content type called 'Episode' and a file field called 'MP3'. This field's widget is the 'Media File Selector'. The field is set to upload the file to the standard public file system. Additionally, I have my php.ini file set with the following modifications:

upload_max_filesize = 100M
max_input_time = 1000
memory_limit = 100M
max_execution_time = 1000
post_max_size = 100M

Re-Creating Symptoms

1st method, via Submit:

  1. When creating or editing a node, find the 'MP3' field and click 'Select Media'. This brings up the Media modal as expected. You can browse for a local file as expected. The instruction text below the field says that files must be less than 100Mb (confirming that my PHP.ini settings are in effect).
  2. After browsing and selecting a large file (75Mb), click 'Submit'. The browser status shows the progress of the upload.
  3. Once the upload is complete, the browser waits for a response from the server for about 60 additional seconds. The modal window strangely shows the 'Media Browser' page as seen from within the administrative theme, complete with the rest of the page chrome and the Drupal admin tool bar. Drupal does not recognize the upload. The file never gets put in 'sites/default/files' and the Media module does not create a record for it. This problem does not occur with smaller files, such as images.

Error when selecting Submit.

2nd method, via Upload:

  1. When creating or editing a node, find the 'MP3' field and click 'Select Media'. This brings up the Media modal as expected. You can browse for a local file as expected. The instruction text below the field says that files must be less than 100Mb (confirming that my PHP.ini settings are in effect).
  2. After browsing and selecting a large file (75Mb), click 'Upload'. The browser status shows the progress of the upload. The modal window also has a progress bar for the file upload, but this does not seem to work, and the progress remains at 0% during the entirety of the upload.
  3. Once the upload is complete, the browser waits for a response from the server for about 60 additional seconds. Then, a browser error appears, stating that an AJAX request terminated abnormally, and that the server returned a 500 Internal Server Error. Drupal does not recognize the upload. The file never gets put in 'sites/default/files' and the Media module does not create a record for it. This problem does not occur with smaller files, such as images.

Error when selecting Upload.

NOTE: This problem did not occur when using the Media File Entity module, but is present now that File Entity is being used.

Files: 

Comments

Category:bug» support
Status:Active» Postponed (maintainer needs more info)

turn display_errors on in php. this will reveal the error and the reason for the 500 error

The root of the problem is that my host (Dreamhost) doesn't allow uploads greater than 128mb to the root tmp directory. When this filter fails, it gets caught by mod_security and throws the 500 error.

More info here:
"An unrecoverable error occurred. The uploaded file likely exceeded the maximum file size (128 MB) that this server supports."

I have tried bypassing mod_security with an .htaccess rule, but it doesn't seem to work. I ended up turning mod_security off ("Extra web security" in Dreamhost's control panel) but the file still fails to upload, simply with a different, unspecified error. To date, I have not found a good workaround for this, and I'm shopping for a new host that doesn't put these kinds of restrictions on me.