Cannot upgrade Wordpress to 3.8.1

  • Answered
Hi Team,
I am unable to update my wordpress after a recent attack on my website.
The error I am receiving is as follows:

Downloading update from…

Warning: touch() [function.touch]: Unable to create file /tmp/wordpress-3.tmp because No such file or directory in /home/illest6/public_html/wp-admin/includes/file.php on line 155

Warning: unlink(/tmp/wordpress-3.tmp) [function.unlink]: Operation not permitted in /home/illest6/public_html/wp-admin/includes/file.php on line 479

Download failed.: Could not open handle for fopen() to /tmp/wordpress-3.tmp

Installation Failed

Hello Brandon, You could possibly be having issues relating to the /tmp directory WordPress is trying to save temporary files to. I'd recommend checking out our guide on fix WordPress download failed errors on update. In that guide it mentions editing your WordPress wp-config.php file and adding this line towards the top:
define('WP_TEMP_DIR', ABSPATH . 'wp-content/');
That should set the temporary directory for WordPress to download its update files to, and it should be a folder within your account so you shouldn't run into permission issues. If that's not working and you did have a WordPress website that was hacked, you also might find our guide on how to reinstall WordPress after a hack helpful. - Jacob
It appears that the previous hack may have damaged your WordPress core files. To resolve the issue, as well as perform the upgrade, you may still update WordPress manually which is quite simple. Do so so, you may follow WordPress' guide on manually updating WordPress.