1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Attaching Large Files - Size Issue

Discussion in 'XenForo Development Discussions' started by DaiAku, Feb 3, 2014.

  1. DaiAku

    DaiAku Active Member

    Hi There,

    We are having issues uploading attachments over 1M in size and cannot understand why. We get an unspecified error or error message with no details. We have been testing with jpg files specifically and if they are too big it just get rejected.

    We have set the limit pretty high and still issues as well tried turning off the flash uploader but that did not help either.

    Screenshot 2014-02-03 12.00.04.png

    Any ideas?

  2. MattW

    MattW Well-Known Member

    What settings do you have in your PHP.ini file for the upload values?
  3. DaiAku

    DaiAku Active Member

    Hi @MattW - great question. We are using plesk to manage our server - where do we find that setting? Cannot find it so far.
  4. MattW

    MattW Well-Known Member

    Not sure in Plesk. You can access PHPINFO via the tools URL in the ACP of XenForo.

    Go to the Tools tab, and add phpinfo to the end of the URL.

    It will tell you in there what the upload variables are

    Brandon Sheley likes this.
  5. Zantetsuken

    Zantetsuken Member

    It's set as: upload_max_filesize = 128M
  6. DaiAku

    DaiAku Active Member

  7. AndyB

    AndyB Well-Known Member

    Looks like your PHP settings are correct.

    I suggest contacting your host and explaining the problem. They should be able to quickly resolve the issue.
  8. DaiAku

    DaiAku Active Member

    Ok thanks. We will try them :).
  9. DaiAku

    DaiAku Active Member

    Ok, it does not look like it is on the server side as far as we can tell. Still looking talking to the tech people but we were able to upload large files through plesk and ftp with no problems to the server. Here is a step by step of exactly what is going on. If anyone has seen this before and could provide help it would really be appreciated. If we reduce the size of this picture to 25% of its original size it will work.

    Here we go. It all started with a picture of my cat who like flowers. :)

    Willey With Flower.jpg

    Here are the steps to upload the file that I take that is causing problems:

    Create a post:

    Create a post.png

    Upload a file:

    Select a file.png

    Select the cat picture:


    Unknown error with little info is provided :( :


    We are using @Chris Deeming 's Xen Media Gallery but the setting look fine there too.

    Xen Media Gallery Settings 1.png

    Xen Media Gallery Settings 2.png

    Any help would be greatly appreciated.


  10. Chris D

    Chris D XenForo Developer Staff Member

    Xen Media Gallery would be completely unrelated to the issue of being unable to upload the image to a thread. (None of my code runs there).

    But, are you able to successfully upload the image to the gallery? If you get the same error it is more than likely still going to be a server issue.

    What is the actual file size of the image?

    Also, you could check some values in phpinfo.

    Go to:


    Search the page for post_max_size

    What is that value?
  11. DaiAku

    DaiAku Active Member

    Hi Chris,

    Thanks for following up. We cannot upload files to the gallery either - this is where we first discovered the problem but then saw it seemed to be across the entire forum. We do get the same error with the gallery.

    The actual file size is 3.3M and well below the limits.

    post_max_size is 8M.

    Not sure if that sheds any light on anything.

    The server folks seem baffled too. :(

  12. Chris D

    Chris D XenForo Developer Staff Member

    I'm not sure if your server is having issues at the moment. I decided to register to see if I could upload some large files to the gallery and I had an nginx gateway timeout.

    Sorry for asking you the php questions again, I only just read the rest of the thread :)
  13. DaiAku

    DaiAku Active Member

    Not a problem with the question.

    We have manual member approvals on right now. You are now approved as a member - please try to upload a file now.
  14. Chris D

    Chris D XenForo Developer Staff Member

    Thanks for the manual approval. It's odd how I got an nginx timeout error though. If the server is under load right now, or having some other sort of connectivity issues, that could most certainly interrupt file uploads.

    Aside from that, do they have anything like mod_security enabled on the server? That has been known to cause issues with file uploads from time to time.

    Also, according to the code, the particular error you're getting is quite generic, but it does send a warning to the browser console. After the upload fails is there any further information logged there?

    Anything in the actual Server Error log in the Admin CP?

    Finally, if you disable all add-ons and try again, does that make any difference?
  15. DaiAku

    DaiAku Active Member

    We just got this weird server error too that I just saw in the admin panel:

    Error Info
    Zend_Gdata_App_HttpException: Read timed out after 10 seconds - library/Zend/Gdata/App.php:688
    Generated By: Unknown Account, 10 minutes ago
    Stack Trace
    #0 /var/www/vhosts/precursorgames.com/httpdocs/forums/library/Zend/Gdata.php(219): Zend_Gdata_App->performHttpRequest('GET', 'http://spreadsh...', Array, NULL, NULL, NULL)
    #1 /var/www/vhosts/precursorgames.com/httpdocs/forums/library/Zend/Gdata/App.php(875): Zend_Gdata->performHttpRequest('GET', 'http://spreadsh...', Array)
    #2 /var/www/vhosts/precursorgames.com/httpdocs/forums/library/Zend/Gdata/App.php(763): Zend_Gdata_App->get('http://spreadsh...', NULL)
    #3 /var/www/vhosts/precursorgames.com/httpdocs/forums/library/Zend/Gdata/App.php(205): Zend_Gdata_App->importUrl('http://spreadsh...', 'Zend_Gdata_Spre...', NULL)
    #4 /var/www/vhosts/precursorgames.com/httpdocs/forums/library/Zend/Gdata.php(162): Zend_Gdata_App->getFeed('http://spreadsh...', 'Zend_Gdata_Spre...')
    #5 /var/www/vhosts/precursorgames.com/httpdocs/forums/library/Zend/Gdata/Spreadsheets.php(266): Zend_Gdata->getFeed('http://spreadsh...', 'Zend_Gdata_Spre...')
    #6 /var/www/vhosts/precursorgames.com/httpdocs/forums/library/Zend/Gdata/Spreadsheets.php(333): Zend_Gdata_Spreadsheets->getListFeed(Object(Zend_Gdata_Spreadsheets_ListQuery))
    #7 /var/www/vhosts/precursorgames.com/httpdocs/forums/library/UpdateMailingList/CronEntry.php(44): Zend_Gdata_Spreadsheets->insertRow(Array, 'tvtXWpmVO7cMnKp...', 'od6')
    #8 [internal function]: UpdateMailingList_CronEntry::UpdateMailingList(Array)
    #9 /var/www/vhosts/precursorgames.com/httpdocs/forums/library/XenForo/Model/Cron.php(356): call_user_func(Array, Array)
    #10 /var/www/vhosts/precursorgames.com/httpdocs/forums/library/XenForo/Deferred/Cron.php(24): XenForo_Model_Cron->runEntry(Array)
    #11 /var/www/vhosts/precursorgames.com/httpdocs/forums/library/XenForo/Model/Deferred.php(252): XenForo_Deferred_Cron->execute(Array, Array, 9.9999949932098, '')
    #12 /var/www/vhosts/precursorgames.com/httpdocs/forums/library/XenForo/Model/Deferred.php(378): XenForo_Model_Deferred->runDeferred(Array, 9.9999949932098, '', false)
    #13 /var/www/vhosts/precursorgames.com/httpdocs/forums/library/XenForo/Model/Deferred.php(331): XenForo_Model_Deferred->_runInternal(Array, NULL, '', false)
    #14 /var/www/vhosts/precursorgames.com/httpdocs/forums/deferred.php(23): XenForo_Model_Deferred->run(false)
    #15 {main}
    Request State
    array(3) {
      ["url"] => string(45) "http://precursorgames.com/forums/deferred.php"
      ["_GET"] => array(0) {
      ["_POST"] => array(3) {
        ["_xfRequestUri"] => string(77) "/forums/index.php?threads/my-current-reading-list-and-recommended-lists.3078/"
        ["_xfNoRedirect"] => string(1) "1"
        ["_xfResponseType"] => string(4) "json"
  16. DaiAku

    DaiAku Active Member

    Hi Chris,

    I will check with them on mod_security. and will try to disable all of the add-ons to see what that does.

  17. Chris D

    Chris D XenForo Developer Staff Member

    I would ask your hosts to also investigate that error you posted above and the gateway timeout I reported.

    Both are indicative of connection issues and could have a detrimental affect on uploading images.
  18. DaiAku

    DaiAku Active Member

    Addition note - our forums were hacked a couple weeks back and they did mess with our data base but we thought we had fixed it. @Zent
    Ok will do thanks.
  19. DaiAku

    DaiAku Active Member

    Addition note - our forums were hacked a couple weeks back and they did mess with our data base but we thought we had fixed it @Zantetsuken spent some time on this.
  20. Chris D

    Chris D XenForo Developer Staff Member

    What was the cause of the hack? How did they get in?

    Who is your host?

Share This Page