bug 13989: correct the usage about the control IP in VMware resource, new command like GetDomRVersion command is not using the right control IP address under basic zone mode. Reviewed-By: Anthony

This commit is contained in:
Kelven Yang 2012-02-27 11:23:31 -08:00
parent d6271aab9b
commit dd5123b8ba
1 changed files with 6 additions and 3 deletions

View File

@ -1003,7 +1003,8 @@ public class VmwareResource implements StoragePoolResource, ServerResource, Vmwa
Pair<Boolean, String> result;
try {
VmwareManager mgr = getServiceContext().getStockObject(VmwareManager.CONTEXT_STOCK_NAME);
result = SshHelper.sshExecute(cmd.getAccessDetail(NetworkElementCommand.ROUTER_IP), DEFAULT_DOMR_SSHPORT, "root", mgr.getSystemVMKeyFile(), null,
String controlIp = getRouterSshControlIp(cmd);
result = SshHelper.sshExecute(controlIp, DEFAULT_DOMR_SSHPORT, "root", mgr.getSystemVMKeyFile(), null,
"/root/checkrouter.sh ");
if (!result.first()) {
@ -1032,7 +1033,8 @@ public class VmwareResource implements StoragePoolResource, ServerResource, Vmwa
Pair<Boolean, String> result;
try {
VmwareManager mgr = getServiceContext().getStockObject(VmwareManager.CONTEXT_STOCK_NAME);
result = SshHelper.sshExecute(cmd.getAccessDetail(NetworkElementCommand.ROUTER_IP), DEFAULT_DOMR_SSHPORT, "root", mgr.getSystemVMKeyFile(), null,
String controlIp = getRouterSshControlIp(cmd);
result = SshHelper.sshExecute(controlIp, DEFAULT_DOMR_SSHPORT, "root", mgr.getSystemVMKeyFile(), null,
"/opt/cloud/bin/get_template_version.sh ");
if (!result.first()) {
@ -1065,7 +1067,8 @@ public class VmwareResource implements StoragePoolResource, ServerResource, Vmwa
Pair<Boolean, String> result;
try {
VmwareManager mgr = getServiceContext().getStockObject(VmwareManager.CONTEXT_STOCK_NAME);
result = SshHelper.sshExecute(cmd.getAccessDetail(NetworkElementCommand.ROUTER_IP), DEFAULT_DOMR_SSHPORT, "root", mgr.getSystemVMKeyFile(), null,
String controlIp = getRouterSshControlIp(cmd);
result = SshHelper.sshExecute(controlIp, DEFAULT_DOMR_SSHPORT, "root", mgr.getSystemVMKeyFile(), null,
"/root/bumpup_priority.sh ");
if (!result.first()) {