From cf6406695b59fe67b06a1c8415d8b187a4e98865 Mon Sep 17 00:00:00 2001 From: alena Date: Wed, 1 Jun 2011 17:01:35 -0700 Subject: [PATCH] bug 10080: update nic profile with DNS info for the nics with reservation_strategy=Create status 10080: resolved fixed --- server/src/com/cloud/network/NetworkManagerImpl.java | 1 + .../src/com/cloud/network/guru/DirectPodBasedNetworkGuru.java | 4 ++++ 2 files changed, 5 insertions(+) diff --git a/server/src/com/cloud/network/NetworkManagerImpl.java b/server/src/com/cloud/network/NetworkManagerImpl.java index 1e9b12c310d..cacefea68ca 100755 --- a/server/src/com/cloud/network/NetworkManagerImpl.java +++ b/server/src/com/cloud/network/NetworkManagerImpl.java @@ -1232,6 +1232,7 @@ public class NetworkManagerImpl implements NetworkManager, NetworkService, Manag updateNic(nic, network.getId(), 1); } else { profile = new NicProfile(nic, network, nic.getBroadcastUri(), nic.getIsolationUri(), networkRate); + guru.updateNicProfile(profile, network); nic.setState(Nic.State.Reserved); updateNic(nic, network.getId(), 1); } diff --git a/server/src/com/cloud/network/guru/DirectPodBasedNetworkGuru.java b/server/src/com/cloud/network/guru/DirectPodBasedNetworkGuru.java index 6284ce6f2c4..9cfb4585064 100644 --- a/server/src/com/cloud/network/guru/DirectPodBasedNetworkGuru.java +++ b/server/src/com/cloud/network/guru/DirectPodBasedNetworkGuru.java @@ -106,6 +106,10 @@ public class DirectPodBasedNetworkGuru extends DirectNetworkGuru { getIp(nic, dest.getPod(), vm, network); nic.setStrategy(ReservationStrategy.Create); } + + DataCenter dc = _dcDao.findById(network.getDataCenterId()); + nic.setDns1(dc.getDns1()); + nic.setDns2(dc.getDns2()); } protected void getIp(NicProfile nic, Pod pod, VirtualMachineProfile vm, Network network) throws InsufficientVirtualNetworkCapcityException,