syncloud / platform

Run popular services on your device with one click
https://syncloud.org
GNU General Public License v3.0
400 stars 40 forks source link

Nextcloud update failed #584

Closed DarkCoocky closed 3 years ago

DarkCoocky commented 3 years ago

Running syncloud OS 21 on raspberry pi3 b+ based on iso file for pi4 (installer version 190627).

Bug description I just restarted my server yesterday after 6 months off. I updated all the Gogs app(after performing backup), then the mail app (already backed up) and then i updated the system to version 210321656. All went good.

I finally decided to update my nextcloud app from version 201110192 to 210214199. But I've had an error on Web UI (like the update button didn't disappear so i knew that something went wrong). So I runned the update process again but through ssh and I've got an error about access permissions for the nextcloud's "data" directory.

To Reproduce Steps to reproduce the behaviour:

  1. Login through ssh as root user.
  2. Install nextcloud version 201110192.
  3. sudo snap refresh nextcloud
  4. See error

Screenshots image

Here's what i got when i try to reach the homepage of my nextcloud instance : image

Logs have been sent at 6:37pm (Paris tz).

cyberb commented 3 years ago

interesting, something must have happened to the disk. can you run this:

ls -la /opt/disk/internal

and also this:

df -h 
cyberb commented 3 years ago

I think the main problem is that external disk is not activated, probably because there was some issue activating it during the startup. Try activating it?

cyberb commented 3 years ago

Was external drive actually ever used?

DarkCoocky commented 3 years ago

The external was inactive and I don't know why because I activated it like a year ago.

I'm trying to reactivate it.

DarkCoocky commented 3 years ago

External drive reactivated. Retrying update through ssh.

DarkCoocky commented 3 years ago

Update process went good. Trying to reconnect to the nextcloud instance.

DarkCoocky commented 3 years ago

Nextcloud is working. But I lost my users and I assume their data.

DarkCoocky commented 3 years ago

Nextcloud is working. I didn't lost a thing. Thank you for your help again. Closing

simoneburalli commented 3 years ago

Hi, I'm running:

Syncloud 210321656; hardware: HC4; **Nextcloud 210108194

and cannot update to Nextcloud 210528234**. Through web installer nothing happens. If I run sudo snap refresh nextcloud here's what I get:

login as: root
root@192.168.1.14's password:
Linux syncloud 4.9.236-63 #1 SMP PREEMPT Wed Dec 9 22:25:50 UTC 2020 aarch64

The programs included with the Debian GNU/Linux system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.

Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent
permitted by applicable law.
Last login: Thu May 27 15:22:57 2021 from 192.168.1.11
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-05-31 13:37:18,742 - database - INFO - executing: snap run nextcloud.pgdump                     all -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 1                     996) 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, i                     n check_output
    raise CalledProcessError(retcode, cmd, output=output)
subprocess.CalledProcessError: Command 'snap run nextcloud.pgdumpall -f /var/sna                     p/nextcloud/current/database.dump' returned non-zero exit status 1
-----)
root@syncloud:~# 

Any suggestions? Thanks in advance.

Simone

cyberb commented 3 years ago

unexpected chunk size

Something wrong with disk or database and it cannot make a backup during the upgrade.

Can you try to create a backup from app page?

cyberb commented 3 years ago

Also can you create another issue as this is not related.