From 27eb30a329a86e3fe7ec8baf1ec1ab5d165e5fb0 Mon Sep 17 00:00:00 2001 From: Santiago Zarate Date: Wed, 13 Feb 2019 18:30:25 +0100 Subject: [PATCH] Wait if the ssh authentication didnt work --- backend/baseclass.pm | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/backend/baseclass.pm b/backend/baseclass.pm index ddddcae2e27..0ba3dbcff20 100644 --- a/backend/baseclass.pm +++ b/backend/baseclass.pm @@ -1174,7 +1174,6 @@ sub new_ssh_connection { my $counter = 5; while ($counter > 0) { if ($ssh->connect($args{hostname})) { - if ($args{password}) { $ssh->auth(username => $args{username}, password => $args{password}); } @@ -1183,7 +1182,7 @@ sub new_ssh_connection { $ssh->auth_agent($args{username}); } bmwqemu::diag "Connection to $args{username}\@$args{hostname} established" if $ssh->auth_ok; - last; + sleep(10); } else { bmwqemu::diag "Could not connect to $args{username}\@$args{hostname}, Retry";