firewallMo.refreshFirewall();
}
}
public String getHostManagementIp(String managementPortGroup) throws Exception {
HostNetworkInfo netInfo = getHostNetworkInfo();
List<HostVirtualNic> nics = netInfo.getVnic();
for (HostVirtualNic nic : nics) {
if (nic.getPortgroup().equals(managementPortGroup)) {
HostIpConfig ipConfig = nic.getSpec().getIp();
return ipConfig.getIpAddress();