Skip to content

Commit 1970b6e

Browse files
ospf: WIP Marvin
1 parent 4f9c371 commit 1970b6e

File tree

3 files changed

+254
-47
lines changed

3 files changed

+254
-47
lines changed

core/src/com/cloud/agent/resource/virtualnetwork/facade/QuaggaConfigItem.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,6 @@ public List<ConfigItem> generateConfig(final NetworkElementCommand cmd) {
4242

4343
StringBuilder zebra = new StringBuilder();
4444
zebra.append("hostname " + vrName).append(",");
45-
zebra.append("password zebra").append(",");
46-
zebra.append("enable password zebra").append(",");
4745
zebra.append("interface eth1").append(",");
4846
zebra.append(" description link to area 0").append(",");
4947
zebra.append(" ip address " + vrIp + "/24").append(",");
@@ -52,7 +50,6 @@ public List<ConfigItem> generateConfig(final NetworkElementCommand cmd) {
5250

5351
StringBuilder ospfd = new StringBuilder();
5452
ospfd.append("hostname " + vrName).append(",");
55-
ospfd.append("password zebra").append(",");
5653
ospfd.append("interface eth1").append(",");
5754
ospfd.append(" ip ospf hello-interval ").append(qzc.getHelloInterval()).append(",");
5855
ospfd.append(" ip ospf dead-interval ").append(qzc.getDeadInterval()).append(",");

server/src/com/cloud/network/vpc/VpcManagerImpl.java

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -743,8 +743,7 @@ public Map<String, String> quaggaConfigUpdate(final Long zoneId, final String pr
743743
_dcDao.loadDetails(dc);
744744
Map<String, String> details = dc.getDetails();
745745
qzc.setDefaultValues(details);
746-
qzc.setValues(protocol, ospfArea, helloInterval, deadInterval, retransmitInterval, transitDelay, authentication, quaggaPassword, superCIDR,
747-
enabled);
746+
qzc.setValues(protocol, ospfArea, helloInterval, deadInterval, retransmitInterval, transitDelay, authentication, quaggaPassword, superCIDR, enabled);
748747
details = qzc.getValues();
749748
dc.setDetails(details);
750749
_dcDao.saveDetails(dc);
@@ -825,18 +824,15 @@ private List<String> getAllVpcCidrs() {
825824
List<String> usedSubnets = new ArrayList<String>();
826825
for (Vpc vpc : _vpcDao.listAll()) {
827826
if (_vpcSrvcDao.areServicesSupportedInVpc(vpc.getId(), Service.VPCDynamicRouting)) {
828-
List<NetworkVO> vpcntwkv = _ntwkDao.listByVpc(vpc.getId());
829-
for (NetworkVO vpcntwk : vpcntwkv) {
830-
usedSubnets.add(vpcntwk.getCidr());
831-
}
827+
usedSubnets.add(vpc.getCidr());
832828
}
833829
}
834830
return usedSubnets;
835831
}
836832

837833
@Override
838834
@ActionEvent(eventType = EventTypes.EVENT_VPC_CREATE, eventDescription = "creating vpc", create = true)
839-
public Vpc createDynamicVpc(final long zoneId, final long vpcOffId, final long vpcOwnerId, final String vpcName, final String displayText, final String netmask,
835+
public synchronized Vpc createDynamicVpc(final long zoneId, final long vpcOffId, final long vpcOwnerId, final String vpcName, final String displayText, final String netmask,
840836
String networkDomain, final Boolean displayVpc) throws ResourceAllocationException {
841837
if (netmask != null) {
842838
if (!NetUtils.isValidNetmask(netmask)) {

0 commit comments

Comments
 (0)