Automatic wordpress upgrade error: Error: There was an error connecting to the server, Please verify the settings are correct.

Try to give www-data permission in wordpress directory:

cd /yourwordpress_dir/
sudo chown -R www-data:www-data *

This entry was posted in wordpress and tagged , , , . Bookmark the permalink. Post a comment or leave a trackback: Trackback URL.

23 Comments

  1. Posted July 11, 2009 at 2:55 pm | Permalink

    Fred,

    Have been using WordPress for a short time, but have always had problems with upgrading. I’m hosting on my Leopard Server, and WP runs fine otherwise. I’ve searched around and came upon your post.

    Changed the owner and group of all the files in the blog directory tree and it works! Just upgraded from 2.8 to 2.8.1.

    I did find I had to use “localhost” as my server, but other than that, it was seamless.

    Thanks!

  2. Mike
    Posted November 20, 2009 at 2:12 pm | Permalink

    Fred,

    Thanks for the tip regarding the www-data permission in the WordPress directory; I was able to finally use the automatic update function @ localhost. You saved me from hours of headaches!

    Thanks again

  3. Posted November 20, 2009 at 2:27 pm | Permalink

    You’re welcome! I had this problem too.
    Regards!

  4. Nnyan
    Posted January 11, 2010 at 5:48 pm | Permalink

    Just installed 2.9 and I do not have a www-data inside my WP folder

  5. mert
    Posted January 19, 2010 at 5:43 am | Permalink

    hello how do i give www-data permission ? can you explain ? i am having the update problem..

  6. Posted January 28, 2010 at 6:59 am | Permalink

    Run the following command (Debian/Ubuntu) in your WordPress directory (sudo required):

    sudo chown -Rf www-data *

  7. Posted January 28, 2010 at 7:08 am | Permalink

    Hi,
    www-data is not a folder. www-data is a user/group used for Apache.

  8. Posted February 3, 2010 at 2:42 am | Permalink

    Hi Fred! This seems like the solution I need! But when I try to give www-data permission, I get the error:

    chown: www-data: Invalid argument

    :-(

  9. Posted February 3, 2010 at 7:39 am | Permalink

    Hi Phil,
    try this:
    sudo chown www-data:www-data * -R
    What’s your OS?
    Regards

  10. Posted February 4, 2010 at 11:06 am | Permalink

    Thanks! Any ideas why even if a certain user is a member of the www-data group the upgrade sitll fails? I got very mixed results before i chown’d.

  11. Posted February 4, 2010 at 1:40 pm | Permalink

    Show your results.

  12. Posted February 5, 2010 at 2:30 am | Permalink

    Don’t worry too much, I tried explaining the ‘mixed’ results but it was terrible bug reporting so won’t bother. :)

    I should have said though that the owner of the folders/files was the same user being used to ssh in to the server through WP. However, it wouldn’t work correctly until www-data was the owner of the files/folders. I just assumed providing ssh details for a certain user would mean that was the user account under which the commands are performed; however, it seems like it’s actually all done under www-root by the server.

  13. Posted March 22, 2010 at 1:41 pm | Permalink

    Hi there

    I too was scatching my head trying to get the update to work, i put local host into the server box and low and behold it came to life, when I was convinced it wasnt going to work lol !

    Many thanks
    Woc

  14. Posted June 29, 2010 at 3:23 pm | Permalink

    Чувствуется сразу, что писал человек хорошо разбирающийся в этой теме

  15. Posted July 1, 2010 at 12:23 pm | Permalink

    Интересно, где Вы нашли столь полезную информацию. Буду признателен если дадите истинный источник

  16. Posted July 2, 2010 at 12:40 pm | Permalink

    Написано конечно всё правильно, хотя и только поверхностно. В любом случае спасибо

  17. Posted July 5, 2010 at 1:00 pm | Permalink

    Спасибо за полезную информацию! Обязательно подпишусь на рассылку

  18. Posted July 6, 2010 at 9:08 am | Permalink
  19. Posted October 31, 2010 at 1:57 pm | Permalink

    I will add your site to favorites. Great work!

  20. Posted November 1, 2010 at 7:51 pm | Permalink

    Interesting post i totally agree with the comments above. Keep us posting

  21. Posted November 3, 2010 at 5:35 pm | Permalink

    Of course, what a great site and informative posts, I will add backlink – bookmark this site? Regards, Reader.

  22. Posted January 15, 2011 at 5:46 pm | Permalink

    Great post. My environment, however, didn’t have ‘www-data’ user/group, but rather ‘apache’. With that, it worked great. Using httpd-2.2.15-1.fc12.2.i686.

  23. Posted February 5, 2011 at 10:53 pm | Permalink

    I am impressed with this website , real I am a fan .

Post a Comment

Your email is never published nor shared. Required fields are marked *

*
*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>