When user runs vbr.py --task backup command, got error Permission denied publickey gssapi-with-mic password

Document ID : KB000020099
Last Modified Date : 14/02/2018
Show Technical Document Details

Description:

Problem:

When user runs vertica database backup first time, got this error:

[dradmin@IM4RHDR ~]$ /opt/vertica/bin/vbr.py --task backup --config-file /export/dradmin/backup-cfg.ini
Preparing...
Found Database port: 5433
The authenticity of host '10.0.0.74 (10.0.0.74)' can't be established.
RSA key fingerprint is 5f:94:45:8a:f0:09:ac:b7:2f:c0:b9:63:5e:96:00:00.
Are you sure you want to continue connecting (yes/no)? yes
Warning: Permanently added '10.0.0.74' (RSA) to the list of known hosts.
Permission denied (publickey,gssapi-with-mic,password).
Unable to ssh to host: 10.0.0.74
backup failed!

Solution:

Workarond:

This is because user has not setup the passwordless ssh key yet.

Without it, user can not backup the Data Repository.

  1. Create a backup config file first, see example below:
    [dradmin@IM4RHDR ~]$ /opt/vertica/bin/vbr.py --setupconfig
    Snapshot name (backup_snapshot): backup-cfg
    Backup vertica configurations? (n) [y/n]: y
    Number of restore points (1):
    Specify objects (no default):
    Vertica user name (dradmin):
    Save password to avoid runtime prompt? (n) [y/n]: y
    Password to save in vbr config file (no default):
    Node v_da_dr_node0001
    Backup host name (no default): IM4RHDR
    Backup directory (no default): /export/dradmin/dbbackup
    Config file name (backup-cfg.ini):
    Change advanced settings? (n) [y/n]: n
    Saved vbr configuration to backup-cfg.ini.
    [dradmin@IM4RHDR ~]$ ls -l
    total 78180
    -rw-rw-r-- 1 dradmin dradmin 260 Jun 17 15:27 backup-cfg.ini

  2. Type the following commands to set up the Linux user account for the database administrator user with a passwordless ssh key:

    Login as the vertica db admin user, run command:

    1. ssh-keygen -N "" -t rsa -f ~/.ssh/id_rsa

    2. cp ~/.ssh/id_rsa.pub ~/.ssh/authorized_keys2

    3. chmod 644 ~/.ssh/authorized_keys2

      Log out the database administrator user account and then log in as root user to run this command:

    4. /etc/init.d/sshd restart

      log out root user and relogin as the vertica database administrator user
      After above steps, user should be able to continue back up the database.

      See below as example:

      [dradmin@IM4RHDR ~]$ /opt/vertica/bin/vbr.py --task backup --config-file /export/dradmin/backup-cfg.ini
      Preparing...
      Found Database port: 5433
      Copying...
      322270290 out of 322270290, 100%
      All child processes terminated successfully.
      Committing changes on all backup sites...
      backup done!