[libvirt] [PATCH RFCv2 5/5] virsh: Reconnect to daemon if remote netcat crashes while using libssh
Michal Privoznik
mprivozn at redhat.com
Wed Jan 18 16:29:09 UTC 2012
On 04.01.2012 00:47, Peter Krempa wrote:
> This patch enables reconnection if for some reason remote netcat, that
> is connecting libvirt daemon to the ssh transport layer crashes.
>
> * tools/virsh.c: Add support for Libssh's error code
> ---
> tools/virsh.c | 3 ++-
> 1 files changed, 2 insertions(+), 1 deletions(-)
>
> diff --git a/tools/virsh.c b/tools/virsh.c
> index 0bc0519..682251c 100644
> --- a/tools/virsh.c
> +++ b/tools/virsh.c
> @@ -17048,7 +17048,8 @@ vshCommandRun(vshControl *ctl, const vshCmd *cmd)
> (last_error->domain == VIR_FROM_REMOTE)) ||
> (last_error->code == VIR_ERR_RPC) ||
> (last_error->code == VIR_ERR_NO_CONNECT) ||
> - (last_error->code == VIR_ERR_INVALID_CONN))))
> + (last_error->code == VIR_ERR_INVALID_CONN) ||
> + (last_error->code == VIR_ERR_LIBSSH_REMOTE_COMMAND))))
> disconnected++;
>
> if (!ret)
ACK
More information about the libvir-list
mailing list