fix for rcons problem with kvm on SLES 12 and on PowerKVM

This commit is contained in:
ligc 2013-10-30 14:55:32 +08:00
parent b94dcb02e4
commit cd4c886ba1

View File

@ -75,6 +75,13 @@ until ($dsthost and $speed and $dstty) {
exec "sleep $sleepint";
}
release_lock();
# The screen command needs the TERM env var,
# TERM might be empty for some unknown reasons,
# for example, on SLES 12 and on PowerKVM
if (!$ENV{'TERM'}) {
$ENV{'TERM'}="vt100";
}
exec "ssh -t $dsthost screen -U -a -O -e ^]a -d -R -S serial-".$ARGV[0]."-cons -A $dstty $speed";
#my $pathtochild= dirname($scriptname). "/";