I am a newbie to Linux as well as to Nextcloud. As a start I bought a Nextcloudpi and did a successful installation of Nextcloud on an 127 GB SD card. Everything is running fine, but now I would like to backup my Nextcloud data to an external device.
For this reason I have connected an 256 GB SSD via USB to the Raspberry Pi. Then I was following How to configure an external USB drive with NextCloudPi to enable automount, and to format the SSD as btrfs.This was done using the Web-access via nextcloudpi:4443.
I did not configure Nextcloud data, Nextcloud database, or the swap file to be on the SSD, since I wanted to have a media for backup purposes only.
Unfortunately, I cannot get the ncp-backup to run. Everytime, I try to run it - via web-access or via SSH - I get the following status:
[ nc-backup ]
check free space…
Maintenance mode enabled
backup database…
backup base files…
tar: /media/NcpBackup/ncp-backups/nextcloud-bkp_20181010_1539191061.tar: Cannot write: Input/output error
tar: Error is not recoverable: exiting now
error generating backup
Maintenance mode disabled
At the same time I get the following error messages at the console output:
[ 615.681115] BTRFS: error (device sda1) in btrfs_commit_transaction:2253: errno=-5 IO failure (Error while writing out transaction)
[ 615.689728] BTRFS: error (device sda1) in cleanup_transaction:1873: errno=-5 IO failure
In most cases afterwards the device sda1 is gone, and a new sdb1 device exists pointing to the SSD but in read only mode. I then disable automount and enable it again via Web-access. Then I have my SSD again available as sda1 with read-write access.
I can access the SSD via the console or via SSH just fine, and write to it. But the backup via the ncp panel fails everytime.
Any help is highly appreciated.
Best regards
LittleAlf
System
- NextCloudPi version: v0.62.6
- automount: yes
- USB devices: sda
- datadir: /var/www/nextcloud/data
- data in SD: yes
- Nextcloud version: 14.0.1.1