WordPress.org

Ready to get started?Download WordPress

Forums

Moved site to new server, uploads not working (11 posts)

  1. Courtney
    Member
    Posted 1 year ago #

    Hi there,

    I just moved a site from one server to another, changing the URL. The site is working just how expected, with one exception. I cannot upload any files. When I try to do so, I get a notice that the file cannot be moved into the uploads directory.

    The path that it shows to the uploads directory contains the beginning of the old path plus the new path. I have tried to updated the "Store uploads in this folder" media settings, and even tried providing the full URL path to the files, but neither approach is working.

    Is there somewhere else in WP where I can change this setting?

    Many thanks!

  2. Courtney
    Member
    Posted 1 year ago #

    Error: The uploaded file could not be moved to /var/www/vhosts/liveearthfarm.net/httpdocs/wp-content/uploads/2012/10.

    /var/www/ is from the old path....

  3. Courtney
    Member
    Posted 1 year ago #

    Update:
    sorry, /var/www/vhosts/is from the old path.

    so far I have tried resaving my permalink structure and defining the uploads location in my config file but neither has worked.

    http://www.liveearthfarm.net.

  4. fonglh
    Member
    Posted 1 year ago #

    Make sure the folder is writeable by the web server. Ask your hosts about it if you're unsure.

  5. Courtney
    Member
    Posted 1 year ago #

    The permissions on the uploads directory are set to 775.

  6. fonglh
    Member
    Posted 1 year ago #

    Which means the web server can't write to it if it's neither the owner nor the group.

    Some hosts run Apache under the nobody user, so you'll have to set the last digit to 7. There might also be a way to run Apache as your own user, but you'll have to check with your hosts.

  7. Courtney
    Member
    Posted 1 year ago #

    I had help moving the database, and will need to help to figure out Apache's role. Once I'm able to verify that Apache is the owner or part of the group, how can I correct the path to the uploads directory?

  8. fonglh
    Member
    Posted 1 year ago #

    Apache is the web server software. There's nothing wrong with the path, the problem is that the software isn't allowed to write files into the folder.

  9. Courtney
    Member
    Posted 1 year ago #

    I've updated the permissions on the uploads folder to 777 because, as you suggested, the webserver was not able to write to it. But I'm still getting the same error as noted above. It appears to be searching for the old absolute path that does not exist anymore.

  10. fonglh
    Member
    Posted 1 year ago #

    Can you SSH into the server and see if that's the right path?

  11. Courtney
    Member
    Posted 1 year ago #

    Fonglh, Thank you very much for your help! I changed the permissions for the upload directory, but not for the child directories. After changing the child directories to 777, everything works like a dream now.

    Thank you for taking the time, and being so patient with me!
    I hope that you have a wonderful rest of your weekend!

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags