[tahoe-lafs-trac-stream] [Tahoe-LAFS] #2918: `tahoe backup` crashes when an upload operation fails

Tahoe-LAFS trac at tahoe-lafs.org
Tue Apr 10 15:41:09 UTC 2018


#2918: `tahoe backup` crashes when an upload operation fails
-------------------------------+---------------------------
 Reporter:  exarkun            |          Owner:
     Type:  defect             |         Status:  new
 Priority:  normal             |      Milestone:  undecided
Component:  code-frontend-cli  |        Version:  1.12.1
 Keywords:  tahoe-backup       |  Launchpad Bug:
-------------------------------+---------------------------
 If `tahoe backup` attempts an upload and the client node it is using
 reports an error, the `tahoe backup` process crashes with an unhandled
 exception.

 For example:

 {{{
 Traceback (most recent call last):
   File "/usr/lib/python2.7/threading.py", line 801, in __bootstrap_inner
     self.run()
   File "/usr/lib/python2.7/threading.py", line 754, in run
     self.__target(*self.__args, **self.__kwargs)
   File "/usr/lib/python2.7/site-
 packages/twisted/_threads/_threadworker.py", line 46, in work
     task()
   File "/usr/lib/python2.7/site-packages/twisted/_threads/_team.py", line
 190, in doWork
     task()
 --- <exception caught here> ---
   File "/usr/lib/python2.7/site-packages/twisted/python/threadpool.py",
 line 250, in inContext
     result = inContext.theWork()
   File "/usr/lib/python2.7/site-packages/twisted/python/threadpool.py",
 line 266, in <lambda>
     inContext.theWork = lambda: context.call(ctx, func, *args, **kw)
   File "/usr/lib/python2.7/site-packages/twisted/python/context.py", line
 122, in callWithContext
     return self.currentContext().callWithContext(ctx, func, *args, **kw)
   File "/usr/lib/python2.7/site-packages/twisted/python/context.py", line
 85, in callWithContext
     return func(*args,**kw)
   File "/usr/lib/python2.7/site-packages/allmydata/scripts/cli.py", line
 543, in backup
     rc = tahoe_backup.backup(options)
   File "/usr/lib/python2.7/site-
 packages/allmydata/scripts/tahoe_backup.py", line 326, in backup
     return bu.run()
   File "/usr/lib/python2.7/site-
 packages/allmydata/scripts/tahoe_backup.py", line 118, in run
     new_backup_dircap = self.process(options.from_dir)
   File "/usr/lib/python2.7/site-
 packages/allmydata/scripts/tahoe_backup.py", line 189, in process
     childcap = self.process(childpath)
   File "/usr/lib/python2.7/site-
 packages/allmydata/scripts/tahoe_backup.py", line 195, in process
     childcap, metadata = self.upload(childpath)
   File "/usr/lib/python2.7/site-
 packages/allmydata/scripts/tahoe_backup.py", line 306, in upload
     raise HTTPError("Error during file PUT", resp)
 allmydata.scripts.common_http.HTTPError: Error during file PUT: 500
 Internal Server Error
 Traceback (most recent call last):
   File "/usr/lib/python2.7/site-packages/allmydata/immutable/upload.py",
 line 933, in start
     d = self.start_encrypted(eu)
   File "/usr/lib/python2.7/site-packages/allmydata/immutable/upload.py",
 line 960, in start_encrypted
     d.addCallback(self.locate_all_shareholders, started)
   File "/usr/lib/python2.7/site-packages/twisted/internet/defer.py", line
 321, in addCallback
     callbackKeywords=kw)
   File "/usr/lib/python2.7/site-packages/twisted/internet/defer.py", line
 310, in addCallbacks
     self._runCallbacks()
 --- <exception caught here> ---
   File "/usr/lib/python2.7/site-packages/twisted/internet/defer.py", line
 653, in _runCallbacks
     current.result = callback(current.result, *args, **kw)
   File "/usr/lib/python2.7/site-packages/allmydata/immutable/upload.py",
 line 988, in locate_all_shareholders
     num_segments, n, k, desired)
   File "/usr/lib/python2.7/site-packages/allmydata/immutable/upload.py",
 line 264, in get_shareholders
     raise NoServersError("client gave us zero servers")
 allmydata.interfaces.NoServersError: client gave us zero servers
 }}}

 The backup does not complete and the user is required to have a high level
 of technical expertise to understand what is happening.

 Many such errors may be due to transient network conditions.  In some
 cases, it may be worth trying again instead of crashing.  In others, if
 the backup is going to end prematurely, this should be reported in a way
 more easily understood by the user.

--
Ticket URL: <https://tahoe-lafs.org/trac/tahoe-lafs/ticket/2918>
Tahoe-LAFS <https://Tahoe-LAFS.org>
secure decentralized storage


More information about the tahoe-lafs-trac-stream mailing list