Backup over FTP fails with Generic error if file cannot be closed (gio backend)

Bug #1310517 reported by klinge
12
This bug affects 2 people
Affects Status Importance Assigned to Milestone
sbackup
Triaged
Medium
Unassigned

Bug Description

Hi

i get an error when sbackup tries to create a incremental backup.
The backup is suposed to be created on a external disk connected trough the local lan and accessed per ftp.

The output in the terminal is as followed:

INFO: Beendigung des GIO Dateizugriffs.
INFO: Die Bearbeitung des Sicherungsprofils ist fehlgeschlagen. Fehler: Error while closing stream: Vorgang fehlgeschlagen [ERROR_FAILED - Generic error condition for when any operation fails.]

Revision history for this message
Jean-Peer Lorenz (peer.loz) wrote :

Thank you for using sbackup and reporting this issue. Could you please give some more detailed information in order to track down this issue:
- sbackup version
- distribution used (Ubuntu?)
- you installed sbackup from repository or PPA?
- does this happen every time?
- do full backups work?

Could you please also add the logfile of this failed backup (remove private data before!). Thanks.

Revision history for this message
klinge (rosgnilk) wrote :

Yes:

- sbackup version: Simple Backup Suite 0.11.6

- distribution used: Ubuntu 14.04

- you installed sbackup from repository or PPA? Repository

- does this happen every time? Yes I updated to Ubuntu 14.04 about a week ago since then it happens all the time. Before with Ubuntu 12.04 it worked fine but I can't remember what sbackup version I used.

- do full backups work? Yes up to now they seem to work.

Revision history for this message
klinge (rosgnilk) wrote :
Revision history for this message
klinge (rosgnilk) wrote :

Today i tried to make a backup on a normal USB external harddrive, and the full as well as the incremental backup worked. So it seems to be related to the network drive.
As I had a look trough the log file as well I realized, that there is someting about not beeing able to rename the full backup.

Revision history for this message
Jean-Peer Lorenz (peer.loz) wrote :

Could you please post your logfile with the "rename" error? Does the issue still happens? Do you launch sbackup as superuser (scheduled backups)? Can you also set the loglevel to DEBUG and run again, to give as much information as possible. Thank you.

Changed in sbackup:
status: New → Incomplete
Revision history for this message
klinge (rosgnilk) wrote :

> Could you please post your logfile with the "rename" error?
Excuse me I expressed myself unprecise I meant that bit:

WARNING in _gio_utils.chmod_no_rwx_grp_oth(606): Unable to set permissions: Vorgang wird nicht unterstützt [ERROR_NOT_SUPPORTED - Operation not supported for the current backend.]

> Does the issue still happens?
Yes

Do you launch sbackup as superuser (scheduled backups)?
I tried all options as normal, as superuser, scheduled and manually.

Revision history for this message
Jean-Peer Lorenz (peer.loz) wrote :

Thanks for the information. The problematic error is:

Error while closing stream: Vorgang fehlgeschlagen [ERROR_FAILED - Generic error condition for when any operation fails.]
Traceback (most recent call last):
[...]
  File "/usr/share/sbackup/sbackup/ar_backend/tar.py", line 1058, in getHeader
    _FOP.close_stream(fd)
  File "/usr/share/sbackup/sbackup/fs_backend/_gio_utils.py", line 866, in close_stream
    raise exceptions.FileAccessException(get_gio_errmsg(error, _("Error while closing stream")))
FileAccessException: Error while closing stream: Vorgang fehlgeschlagen [ERROR_FAILED - Generic error condition for when any operation fails.]

For whatever reason, it is not possible to close TAR's SNAR-file (used for incremental snapshots) from the parent snapshot after reading it. In your case this fails with a "Generic error". Could you please post an old logfile taken from any incremental snapshot that worked under 12.04. I want to check whether this kind of error also was reported under 12.04. Sorry for any inconvinience!

Revision history for this message
klinge (rosgnilk) wrote :

I'm afraid I don't have a logfile from 12.04. I did a new install with ubuntu 14.04 and formated the disk.

Revision history for this message
Jean-Peer Lorenz (peer.loz) wrote :

Hi, do you still have backups made with 12.04? In these snapshots you should also find logfiles. Would be really helpful. Did you tried to use sftp or ssh instead of ftp?

Revision history for this message
klinge (rosgnilk) wrote :

Hi

no unfortunately I don't have any backups from 12,04.

I did try sftp and ssh both don't connect to the server it delivers a error message that says that the autentification dialog is closed down.

but I also tried smb and that works, I attach the logfile.

Revision history for this message
Jean-Peer Lorenz (peer.loz) wrote :

Ok, thanks for checking.

Please note, that you need to connect to your remote destination from commandline when using ssh/sftp in order to add the remote machine to your list of known and trusted hosts. You can do so in terminal:

ssh user@host
sudo ssh@host (if you want to connect as root, e.g. from scheduled backups).

Then confirm identity of the remote machine. After that, ssh and sftp should work.

Revision history for this message
klinge (rosgnilk) wrote :

perfect, after connecting with the terminal sftp and ssh work.

So I don't get an error message even if running an incremental backup. (Of course ftp still looks the same.)

Thanks very much!

Revision history for this message
Jean-Peer Lorenz (peer.loz) wrote :

Set this to Triaged to keep an eye on this issue. Goal should be to soften error handling when closing streams after read-only access to avoid such errors.

Changed in sbackup:
status: Incomplete → Triaged
importance: Undecided → Medium
Revision history for this message
Jean-Peer Lorenz (peer.loz) wrote :

Could you please open a new bug with above information for Ubuntu Trusty 14.04 under https://bugs.launchpad.net/ubuntu/+source/sbackup So I can start to push a fix as SRU into the default repository! Thank you.

summary: - Generic error condition for when any operation fails
+ Backup over FTP fails with Generic error if file cannot be closed (gio
+ backend)
Revision history for this message
Jean-Peer Lorenz (peer.loz) wrote :

@klinge: thank you for your effort! Your help is highly appreciated.

tags: added: ftp incremental
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.