As CP 1.7.3 does neither get automatic updates nor offers a manual upgrade option to CP 2.x, today I re-installed Switch To ClassicPress in order to get the necessary upgrades done. I chose a blog that I don’t actually use anymore, but which is still online. I want to be sure that it works before I upgrade my main blog.
But when I tried to switch to CP 2.2, I got this error message:
Das Paket konnte nicht installiert werden. (= The package could not be installed.): PCLZIP_ERR_BAD_FORMAT (-10) : Invalid archive structure
I thought that CP 2.2 might be too far ahead of CP 1.7.3, so I tried CP 2.1.1, but with the same outcome.
After some research I found a hint that libzip might be missing or outdated in PHP. I installed the package php8.2-zip and tried again, but no change.
PCL Zip is the historic fallback that WP (and, therefore, CP) uses when it doesn’t detect the PHP Zip library. I doubt it’s been subject to much development for years, so that’s probably why it’s failing. The question is why you’re still falling back to it rather than using the PHP Zip module you’ve added.
Have you tried stopping and re-starting the server or trying PHP 8.3 instead?
EDIT: The other thing to check for is that you have enough space on the disk for the update to happen.
Restarted php8.2-fpm: no change.
Restarted nginx: no change.
Anything else? The whole system?
Hard disk space: 2.3 TB of free space on that partition should be enough, right?
I’d really like to avoid software versions that are not in the distributions’s repo (aside from web applications) because of the additional work with updates.
SOLVED! php8.2-curl was missing. I got the idea after I re-read my older threads here in this forum and found this: Update to 1.1.4 failed - #2 by james – older version, same problem.
So I had recognized before that major distri upgrades don’t automatically update all the PHP stuff from the former version. This happened here some time ago when I upgraded from Devuan 3 to Devuan 4. I had to install all the PHP stuff anew, as Devuan 3 came with PHP 7.4, and Devuan 4 with 8.2. I was pretty sure that I got all the modules that I had installed before, but well …
The idea would be to go through all the basic steps of an install, when it comes across what would normally cause an error, it reports back what is missing or incorrectly set.
I believe the “Health Check” feature in CP does something similar to this, but that’s after an initial successful install.
With a “pre-flight” or “simulated” install, errors that prevent a successful install could be caught before actually doing the real install. Basically checking for missing “modules” or incompatible software…
Ex.
Is a supported version of PHP installed
Are are the PHP modules available that are required