• ryu --Caught exception. Cleaning up... KeyError: 3


    ryu启动总是报这样的

    [root@kunpeng82 demo1]# mn --custom group.py  --topo group
    --------------------------------------------------------------------------------
    Caught exception. Cleaning up...
    
    KeyError: 3
    --------------------------------------------------------------------------------
    *** Removing excess controllers/ofprotocols/ofdatapaths/pings/noxes
    killall controller ofprotocol ofdatapath ping nox_corelt-nox_core ovs-openflowd ovs-controllerovs-testcontroller udpbwtest mnexec ivs ryu-manager 2> /dev/null
    killall -9 controller ofprotocol ofdatapath ping nox_corelt-nox_core ovs-openflowd ovs-controllerovs-testcontroller udpbwtest mnexec ivs ryu-manager 2> /dev/null
    pkill -9 -f "sudo mnexec"
    *** Removing junk from /tmp
    rm -f /tmp/vconn* /tmp/vlogs* /tmp/*.out /tmp/*.log
    *** Removing old X11 tunnels
    *** Removing excess kernel datapaths
    ps ax | egrep -o 'dp[0-9]+' | sed 's/dp/nl:/'
    ***  Removing OVS datapaths
    ovs-vsctl --timeout=1 list-br
    ovs-vsctl --timeout=1 list-br
    *** Removing all links of the pattern foo-ethX
    ip link show | egrep -o '([-_.[:alnum:]]+-eth[[:digit:]]+)'
    ip link show
    *** Killing stale mininet node processes
    pkill -9 -f mininet:
    *** Shutting down stale tunnels
    pkill -9 -f Tunnel=Ethernet
    pkill -9 -f .ssh/mn
    rm -f ~/.ssh/mn/*
    *** Cleanup complete.
    killall controller & mn -c /mn --clean之后还是一样  
    [root@kunpeng82 demo1]#  killall controller
    controller: no process found
    [root@kunpeng82 demo1]# mn -c
    *** Removing excess controllers/ofprotocols/ofdatapaths/pings/noxes
    killall controller ofprotocol ofdatapath ping nox_corelt-nox_core ovs-openflowd ovs-controllerovs-testcontroller udpbwtest mnexec ivs ryu-manager 2> /dev/null
    killall -9 controller ofprotocol ofdatapath ping nox_corelt-nox_core ovs-openflowd ovs-controllerovs-testcontroller udpbwtest mnexec ivs ryu-manager 2> /dev/null
    pkill -9 -f "sudo mnexec"
    *** Removing junk from /tmp
    rm -f /tmp/vconn* /tmp/vlogs* /tmp/*.out /tmp/*.log
    *** Removing old X11 tunnels
    *** Removing excess kernel datapaths
    ps ax | egrep -o 'dp[0-9]+' | sed 's/dp/nl:/'
    ***  Removing OVS datapaths
    ovs-vsctl --timeout=1 list-br
    ovs-vsctl --timeout=1 list-br
    *** Removing all links of the pattern foo-ethX
    ip link show | egrep -o '([-_.[:alnum:]]+-eth[[:digit:]]+)'
    ip link show
    *** Killing stale mininet node processes
    pkill -9 -f mininet:
    *** Shutting down stale tunnels
    pkill -9 -f Tunnel=Ethernet
    pkill -9 -f .ssh/mn
    rm -f ~/.ssh/mn/*
    *** Cleanup complete.
    [root@kunpeng82 demo1]# vi group.py 
                self.switch[s-1] = self.addSwitch('s%s' %(s))
    
    from mininet.topo import Topo
    class MininetTopo(Topo):
        def __init__(self,**opts):
            Topo.__init__(self, **opts)
            host1 = self.addHost('h1')
            host2 = self.addHost('h2')
            host3 = self.addHost('h3')
            host4 = self.addHost('h4')
    
            self.switch = {}
    //原来是这里有问题,改成range(1,5)
    for s in range(1,4): print(s) self.switch[s-1] = self.addSwitch('s%s' %(s)) self.addLink(self.switch[0], self.switch[1]) self.addLink(self.switch[0], self.switch[2]) self.addLink(self.switch[0], self.switch[3]) #Adding host self.addLink(self.switch[0], host1) self.addLink(self.switch[1], host2) self.addLink(self.switch[2], host3) self.addLink(self.switch[3], host4) topos = {'group':(lambda:MininetTopo())}
    [root@kunpeng82 demo1]# mn --custom group.py  --topo group
    *** Creating network
    *** Adding controller
    *** Adding hosts:
    h1 h2 h3 h4 
    *** Adding switches:
    s1 s2 s3 s4 
    *** Adding links:
    (s1, h1) (s1, s2) (s1, s3) (s1, s4) (s2, h2) (s3, h3) (s4, h4) 
    *** Configuring hosts
    h1 h2 h3 h4 
    *** Starting controller
    c0 
    *** Starting 4 switches
    s1 s2 s3 s4 ...
    *** Starting CLI:
    mininet> h1 ping h2
    PING 10.0.0.2 (10.0.0.2) 56(84) bytes of data.
    64 bytes from 10.0.0.2: icmp_seq=1 ttl=64 time=134 ms
    64 bytes from 10.0.0.2: icmp_seq=2 ttl=64 time=0.434 ms
    64 bytes from 10.0.0.2: icmp_seq=3 ttl=64 time=0.053 ms
    ^C
    --- 10.0.0.2 ping statistics ---
    3 packets transmitted, 3 received, 0% packet loss, time 2026ms
    rtt min/avg/max/mdev = 0.053/45.037/134.626/63.349 ms
    
    mininet> h1 ping -c 3  h3
    PING 10.0.0.3 (10.0.0.3) 56(84) bytes of data.
    64 bytes from 10.0.0.3: icmp_seq=1 ttl=64 time=137 ms
    64 bytes from 10.0.0.3: icmp_seq=2 ttl=64 time=0.371 ms
    64 bytes from 10.0.0.3: icmp_seq=3 ttl=64 time=0.032 ms
    
    --- 10.0.0.3 ping statistics ---
    3 packets transmitted, 3 received, 0% packet loss, time 2034ms
    rtt min/avg/max/mdev = 0.032/45.905/137.312/64.634 ms
    mininet> 
    Interrupt
    mininet> h1 ping -c 3  h4
    PING 10.0.0.4 (10.0.0.4) 56(84) bytes of data.
    64 bytes from 10.0.0.4: icmp_seq=1 ttl=64 time=133 ms
    64 bytes from 10.0.0.4: icmp_seq=2 ttl=64 time=0.458 ms
    64 bytes from 10.0.0.4: icmp_seq=3 ttl=64 time=0.040 ms
    
    --- 10.0.0.4 ping statistics ---
    3 packets transmitted, 3 received, 0% packet loss, time 2070ms
    rtt min/avg/max/mdev = 0.040/44.570/133.212/62.679 ms
    mininet> 
  • 相关阅读:
    Qt 字符串QString arg()用法总结
    Qt子窗口QMidSubwindow全屏出现的问题总结
    QString介绍
    Qt控制台输出QString
    汽车辐射监测系统-Qt开发[转]发
    Eclipse Qt开发环境的建立
    串口调节工具
    QT 多线程程序设计 -互斥
    ArcGIS Spatial Query
    IQueryFielter接口
  • 原文地址:https://www.cnblogs.com/dream397/p/12986014.html
Copyright © 2020-2023  润新知