paramiko fails when used as cronjob

Bug #1864054 reported by dcg
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
paramiko (Ubuntu)
New
Undecided
Unassigned

Bug Description

cront-tab :
SHELL=/usr/bin/bash
PATH=/home/user1/.local/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin
HOME=/home/user1

52 * * * * bash -c "/home/user1/C++/scripts/BackUps.sh &> /home/user1/delete"

BackUps.sh :
#!/bin/bash
duplicity --no-encryption "/home/user1/Music" sftp://backU@192.168.1.151/Music

delete :
/usr/lib/python3/dist-packages/duplicity/backends/ssh_paramiko_backend.py:409: ResourceWarning: unclosed file <_io.TextIOWrapper name='/etc/ssh/ssh_config' mode='r' encoding='UTF-8'>
  sshconfig.parse(open(file))
ResourceWarning: Enable tracemalloc to get the object allocation traceback
BackendException: ssh connection to backU@192.168.1.151:22 failed: not a valid RSA private key file

BackUps.sh (using pexpect instead) :
#!/bin/bash
duplicity --no-encryption "/home/user1/Music" pexpect+sftp://backU@192.168.1.151/Music

delete (using pexpect) :
Local and Remote metadata are synchronized, no sync needed.
Last full backup date: Thu Feb 20 13:09:02 2020
--------------[ Backup Statistics ]--------------
StartTime 1582208643.30 (Thu Feb 20 16:24:03 2020)
EndTime 1582208643.31 (Thu Feb 20 16:24:03 2020)
ElapsedTime 0.00 (0.00 seconds)
SourceFiles 2
SourceFileSize 4029085 (3.84 MB)
NewFiles 0
NewFileSize 0 (0 bytes)
DeletedFiles 0
ChangedFiles 0
ChangedFileSize 0 (0 bytes)
ChangedDeltaSize 0 (0 bytes)
DeltaEntries 0
RawDeltaSize 0 (0 bytes)
TotalDestinationSizeChange 20 (20 bytes)
Errors 0
-------------------------------------------------

Description: Ubuntu 19.10
Release: 19.10
python3-paramiko:
  Installed: 2.6.0-1
  Candidate: 2.6.0-1
  Version table:
 *** 2.6.0-1 500
        500 http://gr.archive.ubuntu.com/ubuntu eoan/main amd64 Packages
        500 http://gr.archive.ubuntu.com/ubuntu eoan/main i386 Packages
        100 /var/lib/dpkg/status

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.