Backup to SD card: File too large, "Error: cannot load"

REPRODUCIBILITY: 100%
OS VERSION: 4.5.0.19
HARDWARE: Xperia10 II - Dual SIM
UI LANGUAGE: English
REGRESSION:

DESCRIPTION:

When trying to create a backup on a VFAT formatted SD card, this fails if the compressed size of the backup would be more than 4GB (the file size limit for VFAT).

This is not tied to a certain OS version.

PRECONDITIONS:

SD card, formatted to VFAT. VFAT seems to be the only option for access from Sailfish OS as well as Windows.

STEPS TO REPRODUCE:

  1. Start Backup to SD card
  2. Wait…
  3. Receive error message “Error: cannot load”

EXPECTED RESULT:

A working backup: tar.gz splitted over multiple files.

It would be even better to have the old backup program where the user could choose which parts to back up. (E.g. it seems pointless to me to save the same camera pictures to tar.gz again and again instead of just syncing them or doing an incremental backup.)

ACTUAL RESULT:

“Error: cannot load”

MODIFICATIONS:

none

ADDITIONAL INFORMATION:

The relevant parts of the logfile:

Back up to file: /run/media/defaultuser/1BE8-431E/sailfish_backup_2023-05-21T10-14-50Z.tar
Status = Preparing
Status: Preparing
Status text: Preparing
Preparing to backup units: Accounts, Browser, Calendar, Gallery, Media, Messages, Notes, People, Phone to /run/media/defaultuser/1BE8-431E/sailfish_backup_2023-05-21T10-14-50Z.tar
Running unit script Accounts (1 of 9)
Status = RunningUnitScripts
Status: RunningUnitScripts
Status text: Backing up: Accounts
Start: mkdir -p /home/defaultuser/.local/share/system/privileged/Backups-tmp/units/sailfish_backup_2023-05-21T10-14-50Z/Accounts/blobs
Done: mkdir [OK]
Start: mkdir -p /home/defaultuser/.local/share/system/privileged/Backups-tmp/units/sailfish_backup_2023-05-21T10-14-50Z/Accounts/data
Done: mkdir [OK]
Start: /usr/libexec/jolla-vault/units/vault-accounts --action export --name Accounts --bin-dir /home/defaultuser/.local/share/system/privileged/Backups-tmp/units/sailfish_backup_2023-05-21T10-14-50Z/Accounts/blobs --dir /home/defaultuser/.local/share/system/privileged/Backups-tmp/units/sailfish_backup_2023-05-21T10-14-50Z/Accounts/data --home-dir /home/defaultuser
Done: vault-accounts [OK]
Running unit script Browser (2 of 9)
Status text: Backing up: Browser
Start: mkdir -p /home/defaultuser/.local/share/system/privileged/Backups-tmp/units/sailfish_backup_2023-05-21T10-14-50Z/Browser/blobs
Done: mkdir [OK]
Start: mkdir -p /home/defaultuser/.local/share/system/privileged/Backups-tmp/units/sailfish_backup_2023-05-21T10-14-50Z/Browser/data
Done: mkdir [OK]
Start: /usr/libexec/jolla-vault/units/vault-browser --action export --name Browser --bin-dir /home/defaultuser/.local/share/system/privileged/Backups-tmp/units/sailfish_backup_2023-05-21T10-14-50Z/Browser/blobs --dir /home/defaultuser/.local/share/system/privileged/Backups-tmp/units/sailfish_backup_2023-05-21T10-14-50Z/Browser/data --home-dir /home/defaultuser
Done: vault-browser [OK]
Standard out was:
5982
5983
6037
6204

Running unit script Calendar (3 of 9)
Status text: Backing up: Calendar
Start: mkdir -p /home/defaultuser/.local/share/system/privileged/Backups-tmp/units/sailfish_backup_2023-05-21T10-14-50Z/Calendar/blobs
Done: mkdir [OK]
Start: mkdir -p /home/defaultuser/.local/share/system/privileged/Backups-tmp/units/sailfish_backup_2023-05-21T10-14-50Z/Calendar/data
Done: mkdir [OK]
Start: /usr/libexec/jolla-vault/units/vault-calendar --action export --name Calendar --bin-dir /home/defaultuser/.local/share/system/privileged/Backups-tmp/units/sailfish_backup_2023-05-21T10-14-50Z/Calendar/blobs --dir /home/defaultuser/.local/share/system/privileged/Backups-tmp/units/sailfish_backup_2023-05-21T10-14-50Z/Calendar/data --home-dir /home/defaultuser
Done: vault-calendar [OK]
Running unit script Gallery (4 of 9)
Status text: Backing up: Gallery
Start: mkdir -p /home/defaultuser/.local/share/system/privileged/Backups-tmp/units/sailfish_backup_2023-05-21T10-14-50Z/Gallery/blobs
Done: mkdir [OK]
Start: mkdir -p /home/defaultuser/.local/share/system/privileged/Backups-tmp/units/sailfish_backup_2023-05-21T10-14-50Z/Gallery/data
Done: mkdir [OK]
Start: /usr/libexec/jolla-vault/units/vault-gallery --action export --name Gallery --bin-dir /home/defaultuser/.local/share/system/privileged/Backups-tmp/units/sailfish_backup_2023-05-21T10-14-50Z/Gallery/blobs --dir /home/defaultuser/.local/share/system/privileged/Backups-tmp/units/sailfish_backup_2023-05-21T10-14-50Z/Gallery/data --home-dir /home/defaultuser
Done: vault-gallery [OK]
Running unit script Media (5 of 9)
Status text: Backing up: Playlists
Start: mkdir -p /home/defaultuser/.local/share/system/privileged/Backups-tmp/units/sailfish_backup_2023-05-21T10-14-50Z/Media/blobs
Done: mkdir [OK]
Start: mkdir -p /home/defaultuser/.local/share/system/privileged/Backups-tmp/units/sailfish_backup_2023-05-21T10-14-50Z/Media/data
Done: mkdir [OK]
Start: /usr/libexec/jolla-mediaplayer/vault-mediaplayer --action export --name Media --bin-dir /home/defaultuser/.local/share/system/privileged/Backups-tmp/units/sailfish_backup_2023-05-21T10-14-50Z/Media/blobs --dir /home/defaultuser/.local/share/system/privileged/Backups-tmp/units/sailfish_backup_2023-05-21T10-14-50Z/Media/data --home-dir /home/defaultuser
Done: vault-mediaplayer [OK]
Running unit script Messages (6 of 9)
Status text: Backing up: Messages
Start: mkdir -p /home/defaultuser/.local/share/system/privileged/Backups-tmp/units/sailfish_backup_2023-05-21T10-14-50Z/Messages/blobs
Done: mkdir [OK]
Start: mkdir -p /home/defaultuser/.local/share/system/privileged/Backups-tmp/units/sailfish_backup_2023-05-21T10-14-50Z/Messages/data
Done: mkdir [OK]
Start: /usr/libexec/jolla-vault/units/vault-messages --action export --name Messages --bin-dir /home/defaultuser/.local/share/system/privileged/Backups-tmp/units/sailfish_backup_2023-05-21T10-14-50Z/Messages/blobs --dir /home/defaultuser/.local/share/system/privileged/Backups-tmp/units/sailfish_backup_2023-05-21T10-14-50Z/Messages/data --home-dir /home/defaultuser
Done: vault-messages [OK]
Running unit script Notes (7 of 9)
Status text: Backing up: Notes
Start: mkdir -p /home/defaultuser/.local/share/system/privileged/Backups-tmp/units/sailfish_backup_2023-05-21T10-14-50Z/Notes/blobs
Done: mkdir [OK]
Start: mkdir -p /home/defaultuser/.local/share/system/privileged/Backups-tmp/units/sailfish_backup_2023-05-21T10-14-50Z/Notes/data
Done: mkdir [OK]
Start: /usr/libexec/jolla-notes/notes-vault --action export --name Notes --bin-dir /home/defaultuser/.local/share/system/privileged/Backups-tmp/units/sailfish_backup_2023-05-21T10-14-50Z/Notes/blobs --dir /home/defaultuser/.local/share/system/privileged/Backups-tmp/units/sailfish_backup_2023-05-21T10-14-50Z/Notes/data --home-dir /home/defaultuser
Done: notes-vault [OK]
Running unit script People (8 of 9)
Status text: Backing up: People
Start: mkdir -p /home/defaultuser/.local/share/system/privileged/Backups-tmp/units/sailfish_backup_2023-05-21T10-14-50Z/People/blobs
Done: mkdir [OK]
Start: mkdir -p /home/defaultuser/.local/share/system/privileged/Backups-tmp/units/sailfish_backup_2023-05-21T10-14-50Z/People/data
Done: mkdir [OK]
Start: /usr/libexec/jolla-vault/units/vault-contacts --action export --name People --bin-dir /home/defaultuser/.local/share/system/privileged/Backups-tmp/units/sailfish_backup_2023-05-21T10-14-50Z/People/blobs --dir /home/defaultuser/.local/share/system/privileged/Backups-tmp/units/sailfish_backup_2023-05-21T10-14-50Z/People/data --home-dir /home/defaultuser
Done: vault-contacts [OK]
Running unit script Phone (9 of 9)
Status text: Backing up: Phone
Start: mkdir -p /home/defaultuser/.local/share/system/privileged/Backups-tmp/units/sailfish_backup_2023-05-21T10-14-50Z/Phone/blobs
Done: mkdir [OK]
Start: mkdir -p /home/defaultuser/.local/share/system/privileged/Backups-tmp/units/sailfish_backup_2023-05-21T10-14-50Z/Phone/data
Done: mkdir [OK]
Start: /usr/libexec/jolla-vault/units/vault-calls --action export --name Phone --bin-dir /home/defaultuser/.local/share/system/privileged/Backups-tmp/units/sailfish_backup_2023-05-21T10-14-50Z/Phone/blobs --dir /home/defaultuser/.local/share/system/privileged/Backups-tmp/units/sailfish_backup_2023-05-21T10-14-50Z/Phone/data --home-dir /home/defaultuser
Done: vault-calls [OK]
Status text: Backing up: 
Status = Compressing
Status: Compressing
Status text: Compressing data
Checking disk space required for /home/defaultuser/.local/share/system/privileged/Backups-tmp/units/sailfish_backup_2023-05-21T10-14-50Z
Start: tar -cvf /run/media/defaultuser/1BE8-431E/sailfish_backup_2023-05-21T10-14-50Z.tar .from directory: /home/defaultuser/.local/share/system/privileged/Backups-tmp/units/sailfish_backup_2023-05-21T10-14-50Z
Done: tar [FAILED] Exit code: 1
Standard out was:
./
./Calendar/
./Calendar/blobs/
./Calendar/data/
./Calendar/data/all.ics
./Phone/
./Phone/blobs/

[...]

Standard error was:
tar: write error: File too large

[ERROR] 3 Process exited with non-zero exit code or status, quitting.
Deleting /run/media/defaultuser/1BE8-431E/sailfish_backup_2023-05-21T10-14-50Z.tar following failed/canceled backup/compress operation
Start: rm /run/media/defaultuser/1BE8-431E/sailfish_backup_2023-05-21T10-14-50Z.tar
Done: rm [OK]
Removing all working files in /home/defaultuser/.local/share/system/privileged/Backups-tmp
Start: rm -rf /home/defaultuser/.local/share/system/privileged/Backups-tmp
Done: rm [OK]
Status = Error
Status: Error
Status text: Error: cannot load 
Error! error=ProcessError errorString=Process exited with non-zero exit code or status, quitting.

Well you have only an option, format your card as ext4 which is a filesystem with no such limits

You can read it then, only on linux but this has nothing to do with jolla nor sailfish, it’s just how microsoft designed vfat (or fat64)

I think the “bug” part of this is that SFOS backup doesn’t provide a clear enough error message. “Error: cannot load” would make me first think the SD card was full or faulty until I remembered that “ya, vFat and FAT32 have a 4GB file size limit” which can take a while to dredge up in my brain that’s been filled with many other things since the last time I had the problem.

Your expected results, OTOH, actually sound like a potential feature request. Either doing a rar-like multi-file backup or implementing a differential system like you suggested. I dunno if those are a great requests or not, but I’m not here to judge that.

But lastly, at some point SFOS seems to have acquired exFat support. When I use a factory-fresh SD card > 32GB formatted that way, the OS mounts it ok, both in the card slot and via USB reader. I don’t think I’ve added any packages containing exfat support, but there it is. So that might be your solution/workaround.

3 Likes

Thanks. I’ve formatted to exFAT now and the backup did work. The TAR file size is 4.08GB.
Backing up, formatting, copying back took some hours for the 400G card.

Is there an easy way to reformat an SD card?
Backup seems to fail since i loaded 25GB of photos onto the phone.
All i really want backup up is the contacts.

It’s possible through the SFOS UI. Don’t remember exactly, try long-tapping some elements.

2 Likes

Settings → Storage, tap and hold your card Unmount, tap and hold again, Format

2 Likes

It’s a 32GB card, and the only option to reformat is vFAT.
Having done so, unsurprisingly, a backup request continues to fail.

Feels like a bit of a failure on Jolla’s part, in selling licences for phones with 128gb, but not accommodating users making use of that space in the backup process.

Tick to select the options you want to backup:

  • Contacts [y]
  • Calendar [y]
  • Messages [y]
  • Photos [n]

So I have no way to backup contacts and messages, because I have loaded some photos into a small portion of the space available in the phone.

It’s weird cause my jolla phone was only formatting in ext4, now they do vfat, surely for compatibility reasons

Anyway, as i’ve done, i guess the solution is to format your sd card to ext4 on the pc then put it on the phone

Problem solved (unless you have a windows pc)

I just had a look at my settings and found ext4 in settings:storage after unmounting my card. I had a long press to select another format for a test… :man_facepalming:

Well, you sometimes have to test your backups. :rofl:

My idea while copying about 4500 titles of music back is: To format your card in ext4 with your SF-phone try formatting it to ext4 on your computer first. And…be careful when testing options. :wink:

i don’t appear to get any options.

does it relate to it being a 32GB card, i.e. pre SDXC (or whatever the generation is that is beyond 32GB)?

And so did I.
Maybe formatting the card on your computer will help.
Then put it back into your phone and maybe format it again, just to make sure.

1 Like