Hi, I cannot upgrade Nextcloud to version v210624280 .
System:2110141091
Installer:210929152
Hardware: HC4
Here follows what happens. Ideas or suggestions are welcome, thanks.
Steps to reproduce the error
through web interface: nothing happens but I can create backups of the app ;
through Putty (console):
root@syncloud:~# sudo snap refresh nextcloud
error: cannot perform the following tasks:
- Run pre-refresh hook of "nextcloud" snap if present (run hook "pre-refresh":
-----
2021-10-17 20:28:37,518 - database - INFO - executing: snap run nextcloud.pgdumpall -f /var/snap/nextcloud/current/database.dump
pg_dump: Dumping the contents of table "oc_cards" failed: PQgetResult() failed.
pg_dump: Error message from server: ERROR: unexpected chunk size 31 (expected 1996) in chunk 36 of 137 for toast value 18072 in pg_toast_17326
pg_dump: The command was: COPY public.oc_cards (id, addressbookid, carddata, uri, lastmodified, etag, size, uid) TO stdout;
pg_dumpall.bin: pg_dump failed on database "nextcloud", exiting
Traceback (most recent call last):
File "/snap/nextcloud/210108194/meta/hooks/pre-refresh", line 7, in <module>
Installer().pre_refresh()
File "/snap/nextcloud/210108194/hooks/installer.py", line 90, in pre_refresh
self.db.backup()
File "/snap/nextcloud/210108194/hooks/postgres.py", line 59, in backup
self.log.info(check_output(cmd, shell=True))
File "/snap/nextcloud/current/python/lib/python2.7/subprocess.py", line 573, in check_output
raise CalledProcessError(retcode, cmd, output=output)
subprocess.CalledProcessError: Command 'snap run nextcloud.pgdumpall -f /var/snap/nextcloud/current/database.dump' returned non-zero exit status 1
-----)
root@syncloud:~#
I see, looks like nextcloud database is corrupted or not enough disk space.
What kind of boot disk are you using (where syncloud image was written)?
If you have a backup (Settings - Backup) you could restore that backup into a fresh install of Nextcloud (of the same version as backup) and then continue the upgrade.
If you have no backup you can remove Nextcloud and install again from the store but you will lose settings like contacts/calendar. Files are stored separately on disk and can be rescanned back into Nextcloud if you have the same username using this command:
Hi Boris,
thanks a lot. I have solved with a fresh install of Nextcloud. I wasn’t aware that the archive is not impacted by it! I seized the opportunity to perform a complete reset and now I am much happier of its configuration than before. Thanks a lot. Ciao
Simone