2019 SDN上机第4次作业
1. 解压安装OpenDayLight控制器(本次实验统一使用Beryllium版本)
2. 启动并安装插件
3. 用Python脚本搭建如下拓扑,连接OpenDayLight控制器
代码
from mininet.topo import Topo class 4topo(Topo): def __init__(self): Topo.__init__(self) sw=self.addSwitch('s1') count=1 for i in range(3): host = self.addHost('h{}'.format(count)) self.addLink(host,sw,1,count) count = count + 1 topos = {'mytopo': (lambda:4topo())}