Any ideas on this? I earlier got an error on some update directory, and manually deleted it (unfortunately I didn’t write it down). I think I’ve done auto-upgrades on the same domain before.
Downloading update from http://wordpress.org/wordpress-3.1.3.zip… Unpacking the update… Warning: copy(/home/nwalters/public_html/wp-admin/includes/update-core.php) [function.copy]: failed to open stream: Permission denied in /home/myname/public_html/wp-admin/includes/class-wp-filesystem-direct.php on line 200 Could not copy files. Installation Failed
sounds like you need to think about a new host… do I dare ask where you’re hosted now?
But yes that’s a permission issue.
The simple fix is to change the user and group ownership of the files making them the same that PHP runs under. With shared hosting (100’s of accounts on the same server) a special mod is used to allow PHP to run as your user account. Most likely this is your situation. There are 2 simple fixes for this.
Add the following to your wp-config.php:
define('FS_CHMOD_DIR', (0755 & ~ umask())); define('FS_CHMOD_FILE', (0644 & ~ umask()));
This will allow WordPress to override your hosts wrong permissions settings.
If this doesn’t work you can force WordPress to use FTP to do the upgrade by defining your ftp credentials in wp-config.php
Add these lines to wp-config.php using your information:
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);
The 2 commented out lines would be used if you access your webhost with SSH and have an SSH private / public key pair.
If your on a private server or VPS PHP will most likely be running as either www-data or nobody. To fix this you would just run
chown www-data:www-data /home/nwalters/public_html/ -R from the command line to repair the ownership.
Hope this helps.
It looks like you don’t have permission. I would recommend doing a manual upgrade. Its a lot safer and you can always find the problem quicker. check out this link http://wpmu.org/oops-i-broke-wordpress-how-to-fix-your-auto-update-problems/