duplicity-talk
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Duplicity-talk] Error using launchd with duplicity


From: Kenneth Loafman
Subject: Re: [Duplicity-talk] Error using launchd with duplicity
Date: Fri, 17 Aug 2007 06:35:15 -0500
User-agent: Thunderbird 1.5.0.12 (X11/20070604)

There is a fix for this in the upcoming release.  For now, in
backends.py, change line 432 from:
        child.sendeof()
to:
        child.sendline('quit')
and make sure that the passwords are supplied in the environment.

...Thanks,
...Ken


Paul Morris wrote:
> Hi
> 
> I just came across your great software when looking for an S3 compatible 
> backup. It's been working great in script form, however, I have a problem 
> when using launchd to run it.
> 
> Looking at the stderr it seems there is a problem using pexpect in a 
> non-terminal mode. A quick Google for the 'termios' error and it looks as 
> though this condition needs to be handled within the app?
> 
> I'm trying to use launchd because it's new and has some neat features. I 
> guess this isn't occurring under Cron? I can fall back to that if necessary 
> so no major problem if this is a 'bug'.
> 
> Cheers
> Paul
> 
> Stack trace is:
> 
> Traceback (most recent call last):
> File "/usr/local/bin/duplicity", line 378, in ?
> if __name__ == "__main__": main()
> File "/usr/local/bin/duplicity", line 367, in main
> check_last_manifest(col_stats)
> File "/usr/local/bin/duplicity", line 347, in check_last_manifest
> last_backup_set.check_manifests()
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/collections.py",
>  line 118, in check_manifests
> remote_manifest = self.get_remote_manifest()
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/collections.py",
>  line 141, in get_remote_manifest
> try: manifest_buffer = self.backend.get_data(self.remote_manifest_name)
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/backends.py",
>  line 239, in get_data
> fin = self.get_fileobj_read(filename, parseresults)
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/backends.py",
>  line 206, in get_fileobj_read
> return tdp.filtered_open_with_delete("rb")
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/dup_temp.py",
>  line 97, in filtered_open_with_delete
> fh = FileobjHooked(path.DupPath.filtered_open(self, mode))
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/path.py",
>  line 635, in filtered_open
> if mode == "rb": return gpg.GPGFile(None, self, gpg_profile)
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/gpg.py",
>  line 101, in __init__
> attach_fhs={'stdin': encrypt_path.open("rb"),
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/GnuPGInterface.py",
>  line 357, in run
> create_fhs, attach_fhs)
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/GnuPGInterface.py",
>  line 401, in _attach_fork_exec
> if process.pid == 0: self._as_child(process, gnupg_commands, args)
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/GnuPGInterface.py",
>  line 442, in _as_child
> os.execvp( command[0], command )
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/os.py",
>  line 336, in execvp
> _execvpe(file, args)
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/os.py",
>  line 374, in _execvpe
> func(fullname, *argrest)
> OSError: [Errno 2] No such file or directory
> Traceback (most recent call last):
> File "/usr/local/bin/duplicity", line 378, in ?
> if __name__ == "__main__": main()
> File "/usr/local/bin/duplicity", line 367, in main
> check_last_manifest(col_stats)
> File "/usr/local/bin/duplicity", line 347, in check_last_manifest
> last_backup_set.check_manifests()
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/collections.py",
>  line 118, in check_manifests
> remote_manifest = self.get_remote_manifest()
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/collections.py",
>  line 141, in get_remote_manifest
> try: manifest_buffer = self.backend.get_data(self.remote_manifest_name)
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/backends.py",
>  line 241, in get_data
> assert not fin.close()
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/dup_temp.py",
>  line 126, in close
> assert not self.fileobj.close()
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/gpg.py",
>  line 123, in close
> self.gpg_process.wait()
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/GnuPGInterface.py",
>  line 639, in wait
> raise IOError, "GnuPG exited non-zero, with code %d" % (e << 8)
> IOError: GnuPG exited non-zero, with code 65536
> Traceback (most recent call last):
> File "/usr/local/bin/duplicity", line 378, in ?
> if __name__ == "__main__": main()
> File "/usr/local/bin/duplicity", line 360, in main
> elif action == "verify": verify(col_stats)
> File "/usr/local/bin/duplicity", line 270, in verify
> for backup_ropath, current_path in collated:
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/diffdir.py",
>  line 170, in collate2iters
> try: relem1 = riter1.next()
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/patchdir.py",
>  line 431, in integrate_patch_iters
> for patch_seq in collated:
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/patchdir.py",
>  line 332, in yield_tuples
> setrorps(overflow, elems)
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/patchdir.py",
>  line 321, in setrorps
> try: elems[i] = iter_list[i].next()
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/patchdir.py",
>  line 92, in difftar2path_iter
> tarinfo_list = [tar_iter.next()]
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/patchdir.py",
>  line 284, in next
> if not self.tarfile: self.set_tarfile()
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/patchdir.py",
>  line 279, in set_tarfile
> self.current_fp = self.fileobj_iter.next()
> File "/usr/local/bin/duplicity", line 212, in get_fileobj_iter
> manifest = backup_set.get_manifest()
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/collections.py",
>  line 151, in get_manifest
> else: return self.get_remote_manifest()
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/collections.py",
>  line 141, in get_remote_manifest
> try: manifest_buffer = self.backend.get_data(self.remote_manifest_name)
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/backends.py",
>  line 239, in get_data
> fin = self.get_fileobj_read(filename, parseresults)
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/backends.py",
>  line 206, in get_fileobj_read
> return tdp.filtered_open_with_delete("rb")
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/dup_temp.py",
>  line 97, in filtered_open_with_delete
> fh = FileobjHooked(path.DupPath.filtered_open(self, mode))
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/path.py",
>  line 635, in filtered_open
> if mode == "rb": return gpg.GPGFile(None, self, gpg_profile)
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/gpg.py",
>  line 101, in __init__
> attach_fhs={'stdin': encrypt_path.open("rb"),
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/GnuPGInterface.py",
>  line 357, in run
> create_fhs, attach_fhs)
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/GnuPGInterface.py",
>  line 401, in _attach_fork_exec
> if process.pid == 0: self._as_child(process, gnupg_commands, args)
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/GnuPGInterface.py",
>  line 442, in _as_child
> os.execvp( command[0], command )
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/os.py",
>  line 336, in execvp
> _execvpe(file, args)
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/os.py",
>  line 374, in _execvpe
> func(fullname, *argrest)
> OSError: [Errno 2] No such file or directory
> Traceback (most recent call last):
> File "/usr/local/bin/duplicity", line 378, in ?
> if __name__ == "__main__": main()
> File "/usr/local/bin/duplicity", line 360, in main
> elif action == "verify": verify(col_stats)
> File "/usr/local/bin/duplicity", line 270, in verify
> for backup_ropath, current_path in collated:
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/diffdir.py",
>  line 170, in collate2iters
> try: relem1 = riter1.next()
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/patchdir.py",
>  line 431, in integrate_patch_iters
> for patch_seq in collated:
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/patchdir.py",
>  line 332, in yield_tuples
> setrorps(overflow, elems)
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/patchdir.py",
>  line 321, in setrorps
> try: elems[i] = iter_list[i].next()
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/patchdir.py",
>  line 92, in difftar2path_iter
> tarinfo_list = [tar_iter.next()]
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/patchdir.py",
>  line 284, in next
> if not self.tarfile: self.set_tarfile()
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/patchdir.py",
>  line 279, in set_tarfile
> self.current_fp = self.fileobj_iter.next()
> File "/usr/local/bin/duplicity", line 212, in get_fileobj_iter
> manifest = backup_set.get_manifest()
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/collections.py",
>  line 151, in get_manifest
> else: return self.get_remote_manifest()
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/collections.py",
>  line 141, in get_remote_manifest
> try: manifest_buffer = self.backend.get_data(self.remote_manifest_name)
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/backends.py",
>  line 241, in get_data
> assert not fin.close()
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/dup_temp.py",
>  line 126, in close
> assert not self.fileobj.close()
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/gpg.py",
>  line 123, in close
> self.gpg_process.wait()
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/GnuPGInterface.py",
>  line 639, in wait
> raise IOError, "GnuPG exited non-zero, with code %d" % (e << 8)
> IOError: GnuPG exited non-zero, with code 65536
> Traceback (most recent call last):
> File "/usr/local/bin/duplicity", line 378, in ?
> if __name__ == "__main__": main()
> File "/usr/local/bin/duplicity", line 354, in main
> globals.archive_dir).set_values()
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/collections.py",
>  line 416, in set_values
> backend_filename_list = self.backend.list()
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/backends.py",
>  line 483, in list
> l = self.run_sftp_command(commandline, commands).split('\n')[1:]
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/backends.py",
>  line 436, in run_sftp_command
> child.sendeof()
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/pexpect.py",
>  line 818, in sendeof
> old = termios.tcgetattr(fd) # remember current state
> termios.error: (19, 'Operation not supported by device')
> Traceback (most recent call last):
> File "/usr/local/bin/duplicity", line 378, in ?
> if __name__ == "__main__": main()
> File "/usr/local/bin/duplicity", line 354, in main
> globals.archive_dir).set_values()
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/collections.py",
>  line 416, in set_values
> backend_filename_list = self.backend.list()
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/backends.py",
>  line 483, in list
> l = self.run_sftp_command(commandline, commands).split('\n')[1:]
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/duplicity/backends.py",
>  line 436, in run_sftp_command
> child.sendeof()
> File 
> "/System/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-packages/pexpect.py",
>  line 818, in sendeof
> old = termios.tcgetattr(fd) # remember current state
> termios.error: (19, 'Operation not supported by device')
> _________________________________________________________________
> Feel like a local wherever you go with BackOfMyHand.com
> http://www.backofmyhand.com
> 
> _______________________________________________
> Duplicity-talk mailing list
> address@hidden
> http://lists.nongnu.org/mailman/listinfo/duplicity-talk
> 


Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]