Are you hosting your WordPress sites on one of those hosts where WordPress asks you to provide FTP details before upgrading itself or upgrading plugins? So when you click to do an upgrade, instead of just launching into the update process, you get a screen that looks like this instead:
I don’t have experience with loads and loads of different hosts, but I can tell you that when hosting on Media Temple (gs), upgrades generally “just work”, but if you are using their more powerful (dv) service (which I definitely recommend), you’ll run into the FTP thing.
Under the hood
A while back, Joost De Valk had the same problem and created a plugin that helped him and may help you. As he explains it:
Filesystem access is available, the files are owned by me, but the webserver doesn’t run as me, and thus, WordPress doesn’t detect the automatic update correcly.
The core of the issue is that when WordPress does these upgrades for you on your behalf, it is the server that is doing the work, which runs as the ‘apache’ user. By default, at least on the (dv) server, the ‘apache’ user doesn’t have write access to your web directories.
Something that may be useful, Media Temple has an article called Run PHP with FastCGI1 with a potential solution.
Because of the ownership that Plesk assigns to your website files and directories, Apache does not have permission to write to your web directories by default. This can cause permission errors in some applications – for example, a PHP upload script.
1 Editor’s note: 404 link removed.
And SO ANYWAY…
If you just want to fix it and not fiddle with plugins or fancy server altering techniques, the easiest way is just to provide your FTP details. You can do that as WordPress asks you for them.
Or to save yourself the hassle, you can provide these details in your wp-config.php file and auto upgrading will be back to “just working”.
Here is the full set of things you can define as per the Codex:
define('FS_METHOD', 'ftpext'); define('FTP_BASE', '/path/to/wordpress/'); define('FTP_CONTENT_DIR', '/path/to/wordpress/wp-content/'); define('FTP_PLUGIN_DIR ', '/path/to/wordpress/wp-content/plugins/'); define('FTP_PUBKEY', '/home/username/.ssh/id_rsa.pub'); define('FTP_PRIKEY', '/home/username/.ssh/id_rsa'); define('FTP_USER', 'username'); define('FTP_PASS', 'password'); define('FTP_HOST', 'ftp.example.org'); define('FTP_SSL', false);
However, I only needed these to get mine to work:
define('FS_METHOD', 'ftpext'); define('FTP_BASE', '/var/www/vhosts/chriscoyier.net/httpdocs/'); define('FTP_USER', 'username'); define('FTP_PASS', 'password'); define('FTP_HOST', 'host'); define('FTP_SSL', false);
If you have trouble getting the full set to work, definitely try paring back to my trimmed down example.