Minor fix for CoreOS VNET cases
This commit is contained in:
Родитель
eea32198cb
Коммит
d5fb818e30
|
@ -4453,13 +4453,12 @@ Function DoSSHTestFromLocalVM($intermediateVM, $LocalVM, $toVM,[switch]$hostname
|
|||
if($hostnameMode)
|
||||
{
|
||||
LogMsg "Executing - date - command on $($toVM.Hostname) .."
|
||||
$sshOutput = RunLinuxCmd -username $intermediateVM.user -password $intermediateVM.password -ip $intermediateVM.ip -port $intermediateVM.sshport -runAsSudo -command "/home/$user/RunSSHCmd.py -s `'$($LocalVM.ip)`' -u $($LocalVM.user) -p`'$($LocalVM.password)`' -P $($LocalVM.sshPort) -c `'/home/$user/RunSSHCmd.py -s `"$($toVM.hostname)`" -u test -p `"$($toVM.password)`"`" -P 22 -c `"date`" -o yes`'"
|
||||
|
||||
$sshOutput = RunLinuxCmd -username $intermediateVM.user -password $intermediateVM.password -ip $intermediateVM.ip -port $intermediateVM.sshport -runAsSudo -command "python /home/$user/RunSSHCmd.py -s `'$($LocalVM.ip)`' -u $($LocalVM.user) -p`'$($LocalVM.password)`' -P $($LocalVM.sshPort) -c `'python /home/$user/RunSSHCmd.py -s `"$($toVM.hostname)`" -u test -p `"$($toVM.password)`"`" -P 22 -c `"date`" -o yes`'"
|
||||
}
|
||||
else
|
||||
{
|
||||
LogMsg "Executing - date - command on $($toVM.DIP) .."
|
||||
$sshOutput = RunLinuxCmd -username $intermediateVM.user -password $intermediateVM.password -ip $intermediateVM.ip -port $intermediateVM.sshport -runAsSudo -command "/home/$user/RunSSHCmd.py -s `'$($LocalVM.ip)`' -u $($LocalVM.user) -p`'$($LocalVM.password)`' -P $($LocalVM.sshPort) -c `'/home/$user/RunSSHCmd.py -s `"$($toVM.dip)`" -u test -p `"$($toVM.password)`"`" -P 22 -c `"date`" -o yes`'"
|
||||
$sshOutput = RunLinuxCmd -username $intermediateVM.user -password $intermediateVM.password -ip $intermediateVM.ip -port $intermediateVM.sshport -runAsSudo -command "python /home/$user/RunSSHCmd.py -s `'$($LocalVM.ip)`' -u $($LocalVM.user) -p`'$($LocalVM.password)`' -P $($LocalVM.sshPort) -c `'python /home/$user/RunSSHCmd.py -s `"$($toVM.dip)`" -u test -p `"$($toVM.password)`"`" -P 22 -c `"date`" -o yes`'"
|
||||
}
|
||||
LogMsg "Verifying output.."
|
||||
$logfilepath = $toVM.logDir + "\sshOutput.log"
|
||||
|
@ -4487,12 +4486,12 @@ Function DoSCPTestFromLocalVM( $intermediateVM, $LocalVM, $toVM, [switch]$hostna
|
|||
if($hostnameMode)
|
||||
{
|
||||
LogMsg "File Created. Now copying it to $($toVM.Hostname) ..."
|
||||
$scpOutput = RunLinuxCmd -username $intermediateVM.user -password $intermediateVM.password -ip $intermediateVM.ip -port $intermediateVM.sshport -runAsSudo -command "/home/$user/RunSSHCmd.py -s `'$($LocalVM.ip)`' -u $($LocalVM.user) -p`'$($LocalVM.password)`' -P $($LocalVM.sshPort) -c `'/home/$user/RemoteCopy.py -c `"$($toVM.Hostname)`" -m upload -u `"$($toVM.user)`" -p `"$($toVM.password)`"`" -P 22 -r `"/home/$user`" -f `"/home/$user/testfile`"`'"
|
||||
$scpOutput = RunLinuxCmd -username $intermediateVM.user -password $intermediateVM.password -ip $intermediateVM.ip -port $intermediateVM.sshport -runAsSudo -command "python /home/$user/RunSSHCmd.py -s `'$($LocalVM.ip)`' -u $($LocalVM.user) -p`'$($LocalVM.password)`' -P $($LocalVM.sshPort) -c `'python /home/$user/RemoteCopy.py -c `"$($toVM.Hostname)`" -m upload -u `"$($toVM.user)`" -p `"$($toVM.password)`"`" -P 22 -r `"/home/$user`" -f `"/home/$user/testfile`"`'"
|
||||
}
|
||||
else
|
||||
{
|
||||
LogMsg "File Created. Now copying it to $($toVM.DIP) ..."
|
||||
$scpOutput = RunLinuxCmd -username $intermediateVM.user -password $intermediateVM.password -ip $intermediateVM.ip -port $intermediateVM.sshport -runAsSudo -command "/home/$user/RunSSHCmd.py -s `'$($LocalVM.ip)`' -u $($LocalVM.user) -p`'$($LocalVM.password)`' -P $($LocalVM.sshPort) -c `'/home/$user/RemoteCopy.py -c `"$($toVM.DIP)`" -m upload -u `"$($toVM.user)`" -p `"$($toVM.password)`"`" -P 22 -r `"/home/$user`" -f `"/home/$user/testfile`"`'"
|
||||
$scpOutput = RunLinuxCmd -username $intermediateVM.user -password $intermediateVM.password -ip $intermediateVM.ip -port $intermediateVM.sshport -runAsSudo -command "python /home/$user/RunSSHCmd.py -s `'$($LocalVM.ip)`' -u $($LocalVM.user) -p`'$($LocalVM.password)`' -P $($LocalVM.sshPort) -c `'python /home/$user/RemoteCopy.py -c `"$($toVM.DIP)`" -m upload -u `"$($toVM.user)`" -p `"$($toVM.password)`"`" -P 22 -r `"/home/$user`" -f `"/home/$user/testfile`"`'"
|
||||
}
|
||||
LogMsg "Writing output to $logfilepath ..."
|
||||
Set-Content -Path $logFilepath -Value $scpOutput
|
||||
|
|
|
@ -75,11 +75,11 @@ if ($isDeployed)
|
|||
$cmd3="python start-client.py -c $hs1ServiceUrl -p $hs1vm1tcpport -t$iperfTimeoutSeconds -P$Value"
|
||||
}
|
||||
$client.cmd = $cmd3
|
||||
mkdir $LogDir\$mode\Server1 -ErrorAction SilentlyContinue | out-null
|
||||
mkdir $LogDir\$mode\Server2 -ErrorAction SilentlyContinue | out-null
|
||||
$server1.logDir = "$LogDir\$mode\Server1"
|
||||
$server2.logDir = "$LogDir\$mode\Server2"
|
||||
$client.logDir = $LogDir + "\$mode"
|
||||
mkdir $LogDir\$Value\$mode\Server1 -ErrorAction SilentlyContinue | out-null
|
||||
mkdir $LogDir\$Value\$mode\Server2 -ErrorAction SilentlyContinue | out-null
|
||||
$server1.logDir = "$LogDir\$Value\$mode\Server1"
|
||||
$server2.logDir = "$LogDir\$Value\$mode\Server2"
|
||||
$client.logDir = "$LogDir\$Value\$mode"
|
||||
$client.cmd = $cmd3
|
||||
|
||||
RemoteCopy -uploadTo $server1.ip -port $server1.sshPort -files $server1.files -username $server1.user -password $server1.password -upload
|
||||
|
|
|
@ -149,16 +149,16 @@ if($isDeployed)
|
|||
{
|
||||
try
|
||||
{
|
||||
$udpServer.cmd = "/home/$user/start-server.py -u yes -m yes -p 990 && mv Runtime.log start-server.py.log"
|
||||
$udpServer.cmd = "python /home/$user/start-server.py -u yes -m yes -p 990 && mv Runtime.log start-server.py.log"
|
||||
|
||||
if(($mode -eq "IP") -or ($mode -eq "VIP") -or ($mode -eq "DIP"))
|
||||
{
|
||||
$udpClient.cmd = "/home/$user/start-client.py -c $($udpServer.Dip) -p 990 -t10 -u yes -l 1420"
|
||||
$udpClient.cmd = "python /home/$user/start-client.py -c $($udpServer.Dip) -p 990 -t10 -u yes -l 1420"
|
||||
}
|
||||
|
||||
if(($mode -eq "URL") -or ($mode -eq "Hostname"))
|
||||
{
|
||||
$udpClient.cmd = "/home/$user/start-client.py -c $($udpServer.hostname) -p 990 -t10 -u yes -l 1420"
|
||||
$udpClient.cmd = "python /home/$user/start-client.py -c $($udpServer.hostname) -p 990 -t10 -u yes -l 1420"
|
||||
}
|
||||
LogMsg "UDP Test Started for $Value in $mode mode.."
|
||||
|
||||
|
|
|
@ -153,13 +153,13 @@ if($isDeployed)
|
|||
if(($mode -eq "IP") -or ($mode -eq "VIP") -or ($mode -eq "DIP"))
|
||||
{
|
||||
Write-Host $VnetTestIP
|
||||
$pingFrom.cmd = "/home/$user/ping.py -x $TestVMIP -c 10"
|
||||
$pingFrom.cmd = "python /home/$user/ping.py -x $TestVMIP -c 10"
|
||||
}
|
||||
|
||||
if(($mode -eq "URL") -or ($mode -eq "Hostname"))
|
||||
{
|
||||
Write-Host $VnetTestHostName
|
||||
$pingFrom.cmd = "/home/$user/ping.py -x $TestVMHostname -c 10"
|
||||
$pingFrom.cmd = "python /home/$user/ping.py -x $TestVMHostname -c 10"
|
||||
}
|
||||
LogMsg "Test Started for $Value in $mode mode.."
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче