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

Upload Attachments Error after Server Migration

Discussion in 'XenForo Questions and Support' started by Hugh Edwards, Sep 23, 2016.

  1. Hugh Edwards

    Hugh Edwards Member


    I've just migrated my Xenforo Installation from Windows to Linux. I'm on V 1.4.4.

    I've copied over the files, updated the config.php to point to the database and all is working except being able to upload file attachments to threads. I suspect this is because somewhere in the system it's looking for our old e:\windowsdirectory\blahblahblah and we need to update that to /var/www/ etc for the physical path - but I can't find out where to change that.

    Can anyone shed any light on this for me please? And if I'm not right in my presumptions, how to fix this issue?

    FYI there are read and write permissions for the user so I doubt it's that. :)


  2. Brogan

    Brogan XenForo Moderator Staff Member

    XF doesn't use any hard coded server paths in that manner.

    Moving an installation to a different host typically doesn't require anything other than what you have done.

    What happens when you attempt to upload an attachment to a post?
    What is the actual error message?
  3. Hugh Edwards

    Hugh Edwards Member


    Here's the error:
    Screen Shot 2016-09-23 at 13.21.26.png

    ....but it seems to be size related - I can upload less than 1 MB but not above, even though my attachments in the Options: Attachments are set to 5000. Also, when I upload images now, they upload but I no longer get the option to insert a thumbnail or full image now as I have done here....it just uploads.....?
  4. Brogan

    Brogan XenForo Moderator Staff Member

    That would suggest some sort of server limit or setting, which would be consistent with it starting after moving servers.

    It could be one of these:
  5. Hugh Edwards

    Hugh Edwards Member

    Ok - we can see that on the server.

    Any idea why I might not be allowed to insert the thumbnail or full image all of a sudden?
  6. Hugh Edwards

    Hugh Edwards Member

    (P.s., thanks for your help so far!)
  7. Brogan

    Brogan XenForo Moderator Staff Member

  8. Hugh Edwards

    Hugh Edwards Member

    Is that a change needed in PHP or the config file? Sorry, I'm a little confused!
  9. Robru

    Robru Well-Known Member

    Attachments -> add -> mp3 ?
  10. Hugh Edwards

    Hugh Edwards Member

    Brogan - the bit that does the thumb/full image option - is that Javascript? I ask because I think I have seen some other areas on NGINX/PHP-FGM where javascript isn't loading and I suspect this may be the issue?
  11. Mike

    Mike XenForo Developer Staff Member

    If it's a small image, it won't be the max pixel size issue. If you aren't getting the option there, then your server is likely missing GD (or Imagick, if you had previously selected it). It's probably worth going to the installer; it should do a requirements check for you.
  12. Hugh Edwards

    Hugh Edwards Member

    Hi Mike.

    That's handy - thank you - so essentially, just make like I'm going to install it again, and see what the installation says? The only issue is that I'm on 1.4.4 - is there an installer available for that?
  13. Mike

    Mike XenForo Developer Staff Member

    The <url>/install/ page is also the upgrader. It will detect what it needs to do. But you shouldn't even need to upload new files -- it should tell if there are any errors.

    If you prefer, you can use the requirements script from here: https://xenforo.com/purchase/
  14. Hugh Edwards

    Hugh Edwards Member

    Thanks Mike - that's the one - I was missing PHP GD on the new server. :)

    Thanks for all your help - that script is very useful!

Share This Page