@david.blythe apologies - forum hadnt refreshed and didn’t see your notes.
The fix process (and I will document steps but you will need to make changes yourself).
** I redownloaded and executed the original curl setup:
Note that we are only downloading this once as we need to edit a script to fix the hashes so we will re-run this locally until we are done.
curl -s https://mailinabox.email/setup.sh | sudo bash
** The script will fail at some point and give an error about hashes. This will be our iteration point as we need to keep looping through the script and fixing the hashes as reported.
I am not posting my entire file as this may change in the future and its only a few steps to actually determine and fix.
The error will look similar to the following: (the versions, hashes and app will change as we iterate)
Upgrading to Nextcloud version 22.2.6
sha1sum: WARNING: 1 computed checksum did NOT match
------------------------------------------------------------
Download of https://github.com/nextcloud-releases/contacts/releases/download/v4.1.0/contacts-v4.1.0.tar.gz did not match expected checksum.
Found:
38653b507bd7d953816bbc5e8bea7855867eb1cd /tmp/contacts.tgz
Expected:
697f6b4a664e928d72414ea2731cb2c9d1dc3077 /tmp/contacts.tgz
Change to the mail in a box directory: (only done once)
cd mailinabox/
Steps to fix: (this is what we will be iterating through)
- Make a copy of the entire error message in a local txt editor that you can copy and paste from your terminal session.
- Edit the file to sort the hashes
sudo nano ./setup/nextcloud.sh
Search (CTRL-W) for the “Expected hash” in this case it would be the 697f6b4a664e928d72414ea2731cb2c9d1dc3077
Carefully delete existing hash then paste in the “Found” hash eg 38653b507bd7d953816bbc5e8bea7855867eb1cd
(Do another search for the expected hash as it may be used multiple times)
-
Recommended but not essential (Delete old backups). Personally I nuked everything from 2026 as I had had many failed attempts and it was taking a lot of space. The install will tell you the specific backup used so you may choose to just delete that one.
I deleted all from 2026 as that was easy/lazy.
sudo rm -r /home/user-data/owncloud-backup/2026*
-
Re-run the local version of the script:
sudo ./setup/start.sh
I then had to walk it through each version to upgrade and fix the hashes that were mismatched. This will be both for calendar and contacts.
Once you reach version 25 at which point they worked correctly and while you may need to re-run the script eventually you will get upgraded to latest version 27 with all being well.