Front page

decryption failed: secret key not available

b7b1b098ee9646f1b5b18afcd42a4f6e
SEABIRD PHOTOGRAPH RUFFLED

From: obnamsupport <obnamsupport@infopower.nl>
Date: Tue, 5 Apr 2016 13:33:45 +0000

   Tried to set up gpg-agent for obnam in Fedora 18.
   I don't know what I'm doing wrong, but it won't work.
   Below are the configurations, versions used, and what happens.
   
   Thanks for any pointer that makes this work.
   
   joe
   
   
   
   /home/user/.bashrc contains:
   
   GPG_TTY=$(tty)
   export GPG_TTY
   
   if [ -f "${HOME}/.gpg-agent-info" ]; then
     . "${HOME}/.gpg-agent-info"
     export GPG_AGENT_INFO
     export SSH_AUTH_SOCK
     export SSH_AGENT_PID
   fi
   
   
   
   /home/user/.bash_profile contains:
   
   eval $(gpg-agent --daemon --enable-ssh-support --write-env-file "${HOME}/.gpg-agent-info")
   
   
   
   All according to gpg-agent's man file, and I can see that 'it works' as
   the .gpg-agent-info file actually exists, the variables are set, and
   they are exported.
   
   
   /home/user/obnam.conf contains:
   
   repository = sftp://<user>@<IP address>/home/<user>/backups/obnam-repository/
   encrypt-with = <Key-ID>
   
   
   The versions in use are:
   
   gpg-agent (GnuPG) 2.0.22
   libgcrypt 1.5.3
   gpg (GnuPG) 1.4.16
   obnam --version: 1.5
   OpenSSH_6.1p1, OpenSSL 1.0.1e-fips 11 Feb 2013
   
   
   Then I do and get the following things (redacted for privacy reasons):
   1) First obnam's failing attempt to add a client:
   
   [local user@<local machine> ~]$ obnam backup ~/.obnam.conf
   00h00m00s 1 files; 0 B (0 B/s) connecting to
   repository<remote_user>@<IP Address>'s password: 00h00m10s
   1 files; 0 B (0 B/s) adding clientERROR: gpg: can't query passphrase in
   batch mode gpg: decryption failed: secret key not available
   
   2) Then failing removal of the lock file:
   [local user@<local machine> ~]$ obnam force-lock
   <remote_user>@<IP Address>'s password: 
   Warning: Client does not exist in repository.
   
   3) Then the manual removal of the lock file:
   [local user@<local machine> ~]$ ssh <remote_user>@<IP Address>
   <remote_user>@<IP Address>'s password: 
   [some legal stuff]
   Last login: Tue Apr  5 13:16:23 2016 from <local IP Address>
   <remote_user>@<remote machine>:~ $ sudo updatedb
   <remote_user>@<remote machine>:~ $ locate lock|grep
   home /home/<remote_user>/backups/obnam-repository/lock
   <remote_user>@<remote machine>:~ $ rm /home/<remote_user>/backups/obnam-repository/lock 
   <remote_user>@<remote machine>:~ $
   
   4) And exit:
   exit logout
   Connection to <IP Address> closed.
   [local user@<local machine> ~]$ 
   
   
   
   
   _______________________________________________
   obnam-support mailing list
   obnam-support@obnam.org
   http://listmaster.pepperfish.net/cgi-bin/mailman/listinfo/obnam-support-obnam.org
From: obnamsupport <obnamsupport@infopower.nl>
Date: Wed, 6 Apr 2016 03:34:31 +0000

   Ok, good you didn't answer to this problem because the origin is
   totally embarrassing. All that was needed is to uncomment 'use-agent' in
   ~/.gnupg/gpg.conf
   
   I haven't encountered this instruction in any guide on how to use
   gpg-agent with obnam and/or ssh or I have totally missed it, so maybe it's valuable posting it
   here. (Motto: Always re-invent the wheel all by yourself. :)
   
   So, it seems to work... not. This is what I get this time:
   
   [user@vm ~]$ obnam backup ~/obnam.log
   00h00m00s 1 files; 0 B (0 B/s) connecting to repositoryremote_user@remote_IP's password: 
   00h00m13s 1 files; 0 B (0 B/s) adding client 
   00h02m05s 1 files; 0 B (0 B/s) locking client
   00h02m22s 1 files; 0 B (0 B/s) initialising encryption for shared directories 
   00h02m43s 1 files; 0 B (0 B/s) starting new generation 
   00h02m49s 1 files; 0 B (0 B/s) connecting to to repositoryERROR: /home/user/obnam.log: No such file or directory
   
   Now I'm absolutely sure this file exists.
   What now?
   
   
   Cheers,
   joe
   
   
   
   On Tue, 5 Apr 2016 13:33:45 +0000
   obnamsupport <obnamsupport@infopower.nl> wrote:
   
   > Tried to set up gpg-agent for obnam in Fedora 18.
   > I don't know what I'm doing wrong, but it won't work.
   > Below are the configurations, versions used, and what happens.
   > 
   > Thanks for any pointer that makes this work.
   > 
   > joe
   > 
   > 
   > 
   > /home/user/.bashrc contains:
   > 
   > GPG_TTY=$(tty)
   > export GPG_TTY
   > 
   > if [ -f "${HOME}/.gpg-agent-info" ]; then
   >   . "${HOME}/.gpg-agent-info"
   >   export GPG_AGENT_INFO
   >   export SSH_AUTH_SOCK
   >   export SSH_AGENT_PID
   > fi
   > 
   > 
   > 
   > /home/user/.bash_profile contains:
   > 
   > eval $(gpg-agent --daemon --enable-ssh-support --write-env-file
   > "${HOME}/.gpg-agent-info")
   > 
   > 
   > 
   > All according to gpg-agent's man file, and I can see that 'it works'
   > as the .gpg-agent-info file actually exists, the variables are set,
   > and they are exported.
   > 
   > 
   > /home/user/obnam.conf contains:
   > 
   > repository = sftp://<user>@<IP
   > address>/home/<user>/backups/obnam-repository/ encrypt-with = <Key-ID>
   > 
   > 
   > The versions in use are:
   > 
   > gpg-agent (GnuPG) 2.0.22
   > libgcrypt 1.5.3
   > gpg (GnuPG) 1.4.16
   > obnam --version: 1.5
   > OpenSSH_6.1p1, OpenSSL 1.0.1e-fips 11 Feb 2013
   > 
   > 
   > Then I do and get the following things (redacted for privacy reasons):
   > 1) First obnam's failing attempt to add a client:
   > 
   > [local user@<local machine> ~]$ obnam backup ~/.obnam.conf
   > 00h00m00s 1 files; 0 B (0 B/s) connecting to
   > repository<remote_user>@<IP Address>'s password: 00h00m10s
   > 1 files; 0 B (0 B/s) adding clientERROR: gpg: can't query passphrase
   > in batch mode gpg: decryption failed: secret key not available
   > 
   > 2) Then failing removal of the lock file:
   > [local user@<local machine> ~]$ obnam force-lock
   > <remote_user>@<IP Address>'s password: 
   > Warning: Client does not exist in repository.
   > 
   > 3) Then the manual removal of the lock file:
   > [local user@<local machine> ~]$ ssh <remote_user>@<IP Address>
   > <remote_user>@<IP Address>'s password: 
   > [some legal stuff]
   > Last login: Tue Apr  5 13:16:23 2016 from <local IP Address>
   > <remote_user>@<remote machine>:~ $ sudo updatedb
   > <remote_user>@<remote machine>:~ $ locate lock|grep
   > home /home/<remote_user>/backups/obnam-repository/lock
   > <remote_user>@<remote machine>:~ $
   > rm /home/<remote_user>/backups/obnam-repository/lock
   > <remote_user>@<remote machine>:~ $
   > 
   > 4) And exit:
   > exit logout
   > Connection to <IP Address> closed.
   > [local user@<local machine> ~]$ 
   > 
   > 
   > 
   > 
   > _______________________________________________
   > obnam-support mailing list
   > obnam-support@obnam.org
   > http://listmaster.pepperfish.net/cgi-bin/mailman/listinfo/obnam-support-obnam.org
   
   
   _______________________________________________
   obnam-support mailing list
   obnam-support@obnam.org
   http://listmaster.pepperfish.net/cgi-bin/mailman/listinfo/obnam-support-obnam.org