Hi, I'm using wireshark to verify traffic on a mininet topology. It works for small topologies, but fails on larger ones. The topology I am trying it on is attached. Specifically, I am trying to ping h8 (attached to s37) from h1. Any pointers on how to fix this will be appreciated.
"""
Refer to docs in directory for pictorial representation of topology. """
from mininet.topo import Topo
class ThirtyNineBus( Topo ): '''The canonical 39-Bus topology'''
def __init__( self ):
# Initialize topology
Topo.__init__( self )
# Add switches
s1 = self.addSwitch( 's1' )
s2 = self.addSwitch( 's2' )
s3 = self.addSwitch( 's3' )
s4 = self.addSwitch( 's4' )
s5 = self.addSwitch( 's5' )
s6 = self.addSwitch( 's6' )
s7 = self.addSwitch( 's7' )
s8 = self.addSwitch( 's8' )
s9 = self.addSwitch( 's9' )
s10 = self.addSwitch( 's10' )
s11 = self.addSwitch( 's11' )
s12 = self.addSwitch( 's12' )
s13 = self.addSwitch( 's13' )
s14 = self.addSwitch( 's14' )
s15 = self.addSwitch( 's15' )
s16 = self.addSwitch( 's16' )
s17 = self.addSwitch( 's17' )
s18 = self.addSwitch( 's18' )
s19 = self.addSwitch( 's19' )
s20 = self.addSwitch( 's20' )
s21 = self.addSwitch( 's21' )
s22 = self.addSwitch( 's22' )
s23 = self.addSwitch( 's23' )
s24 = self.addSwitch( 's24' )
s25 = self.addSwitch( 's25' )
s26 = self.addSwitch( 's26' )
s27 = self.addSwitch( 's27' )
s28 = self.addSwitch( 's28' )
s29 = self.addSwitch( 's29' )
s30 = self.addSwitch( 's30' )
s31 = self.addSwitch( 's31' )
s32 = self.addSwitch( 's32' )
s33 = self.addSwitch( 's33' )
s34 = self.addSwitch( 's34' )
s35 = self.addSwitch( 's35' )
s36 = self.addSwitch( 's36' )
s37 = self.addSwitch( 's37' )
s38 = self.addSwitch( 's38' )
s39 = self.addSwitch( 's39' )
# add hosts
# note: ignoring arrows
h1 = self.addSwitch( 'h1' )
h2 = self.addSwitch( 'h2' )
h3 = self.addSwitch( 'h3' )
h4 = self.addSwitch( 'h4' )
h5 = self.addSwitch( 'h5' )
h6 = self.addSwitch( 'h6' )
h7 = self.addSwitch( 'h7' )
h8 = self.addSwitch( 'h8' )
h9 = self.addSwitch( 'h9' )
h10 = self.addSwitch( 'h10' )
# Add links
# note: links are bidirectional
# => no need to add the same link from both sides
# 1. switch-switch links
self.addLink( s1, s2 )
self.addLink( s1, s39 )
self.addLink( s2, s30 )
self.addLink( s2, s25 )
self.addLink( s2, s3 )
self.addLink( s3, s4 )
self.addLink( s3, s18 )
self.addLink( s4, s5 )
self.addLink( s4, s14 )
self.addLink( s5, s6 )
self.addLink( s5, s8 )
self.addLink( s6, s7 )
self.addLink( s6, s11 )
self.addLink( s6, s31 )
self.addLink( s7, s8 )
self.addLink( s8, s9 )
self.addLink( s9, s39 )
self.addLink( s10, s11 )
self.addLink( s10, s13 )
self.addLink( s10, s32 )
self.addLink( s11, s12 )
self.addLink( s12, s13 )
self.addLink( s13, s14 )
self.addLink( s14, s15 )
self.addLink( s15, s16 )
self.addLink( s16, s17 )
self.addLink( s16, s19 )
self.addLink( s16, s21 )
self.addLink( s16, s24 )
self.addLink( s17, s18 )
self.addLink( s17, s27 )
#self.addLink( s18, <none> )
self.addLink( s19, s20 )
self.addLink( s19, s33 )
self.addLink( s20, s34 )
self.addLink( s21, s22 )
self.addLink( s22, s23 )
self.addLink( s22, s35 )
self.addLink( s23, s24 )
self.addLink( s23, s36 )
#self.addLink( s24, <none> )
self.addLink( s25, s37 )
self.addLink( s26, s27 )
self.addLink( s26, s28 )
self.addLink( s26, s29 )
#self.addLink( s27, <none> )
self.addLink( s28, s29 )
self.addLink( s29, s38 )
#self.addLink( s30, <none> )
#self.addLink( s31, <none> )
#self.addLink( s32, <none> )
#self.addLink( s33, <none> )
#self.addLink( s34, <none> )
#self.addLink( s35, <none> )
#self.addLink( s36, <none> )
#self.addLink( s37, <none> )
#self.addLink( s38, <none> )
#self.addLink( s39, <none> )
# 2. switch-host links
self.addLink( s30, h1 )
self.addLink( s31, h2 )
self.addLink( s32, h3 )
self.addLink( s33, h4 )
self.addLink( s34, h5 )
self.addLink( s35, h6 )
self.addLink( s36, h7 )
self.addLink( s37, h8 )
self.addLink( s38, h9 )
self.addLink( s39, h10 )</code></pre><p>topos = { 'ThirtyNineBus': ( lambda: ThirtyNineBus() ) }</p></div><div id="question-tags" class="tags-container tags"><span class="post-tag tag-link-ping" rel="tag" title="see questions tagged 'ping'">ping</span></div><div id="question-controls" class="post-controls"></div><div class="post-update-info-container"><div class="post-update-info post-update-info-user"><p>asked <strong>03 Jun '15, 13:58</strong></p><img src="https://secure.gravatar.com/avatar/039152feebd25423ee3733437ddf2566?s=32&d=identicon&r=g" class="gravatar" width="32" height="32" alt="Taki%20Chowdhury's gravatar image" /><p><span>Taki Chowdhury</span><br />
6●1●1●1
accept rate: 0%
Never mind! The error was in my code-it should be h1 = self.addHost(‘h1’) and not addSwitch()!