Search Mailing List Archives
[mininet-discuss] Mininet Ping Command Modification
johanes.lim8 at gmail.com
Fri Jul 8 17:02:36 PDT 2016
currently I'm developing multi-tenant app, where hosts on different tenant
can have same IP address, I want to modify how the pingall command works in
mininet, I already added some changes in ~/mininet/mininet/net.py, which
check the ip address of the hosts rather than only name when do the ping,
but when I run mininet, there's no changes shown even it didn't print the
words I'm added, am I modifying the right file?
def ping( self, hosts=None, timeout=1000 ):
"""Ping between all specified hosts.
hosts: list of hosts
timeout: time to wait for a response, as string
returns: ploss packet loss percentage"""
# should we check if running?
packets = 0
lost = 0
ploss = None
if not hosts:
hosts = self.hosts
output( '*** Ping: testing ping reachability TEST\n' )
for node in hosts:
output( '%s -> ' % node.name )
for dest in hosts:
print "Source IP: ",node.IP()
print "DIP : ",dest.IP()
if node.IP() != dest.IP():
Thanks & Best Regards,
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the mininet-discuss