“Error: Could not open archive part file” Error When Updating Joomla

Yesterday morning, a client emailed us that he wasn’t able to update his Joomla website from version 3.7.5 to version 3.8.3. He told us that he was seeing an “an ajax error of some sort” after clicking on the Update Now button. We immediately thought that he had permission issues on the restore.php file, but we quickly realized that this wasn’t the case.

The “ajax error” that the client was seeing was this one:

Error: Could not open archive part file /home/[cpanel-user]/public_html/tmp/Joomla_3.8.3-Stable-Update_Package.zip for reading. Check that the file exists, is readable by the web server and is not in a directory made out of reach by chroot, open_basedir restrictions or any other restriction put in place by your host.

Additionally, the following warning was being displayed:

JFolder::create: Could not create folder.Path: /home/[cpanel-user]

We quickly examined the permissions (and the ownership) on the logs and the tmp folders, and they were both OK. What could it be, we wondered? We couldn’t think of anything, and so, in a moment of despair, we copied the value of the $tmp_path variable from the configuration file, and we tried to cd to it in the shell, but we got the following error:

-bash: cd: /home/[cpanel-user]/public_html/tmp: No such file or directory

How could it be? So we carefully examined the path, and it turned out there was a typo in [cpanel-user] (for example, itoctopus was spelled itoctopos). We fixed the typo, and then we refreshed the update page (by pressing F5), but still, we saw the same error. We were sure that what we did should have fixed the problem, but, for some reason, it didn’t.

After a few minutes of extreme frustration, we remember that we had to browse off the update page, and then go back, and so we did that: we went to the System – Control Panel page, and then we clicked on the Update Now button, and this time, it worked!

We hope that you found this post useful, and that it helped you update your Joomla website. If it didn’t, or if you need help, then please contact us. We will fix your problem quickly, cleanly, and affordably!

No comments yet.

Leave a comment