|
|
|
connect(self,
**connectargs)
Here the main is the TestON instance after creating all the log
handles. |
source code
|
|
|
startNet(self,
topoFile='',
args='',
mnCmd='',
timeout=120)
Description:
Starts Mininet accepts a topology(.py) file and/or an optional
argument, to start the mininet, as a parameter. |
source code
|
|
|
numSwitchesNlinks(self,
topoType,
depth,
fanout) |
source code
|
|
|
calculateSwAndLinks(self)
Calculate the number of switches and links in a topo. |
source code
|
|
|
pingall(self,
timeout=300,
shortCircuit=False,
acceptableFailed=0)
Verifies the reachability of the hosts using pingall command. |
source code
|
|
|
|
|
|
|
|
|
pingHost(self,
**pingParams)
Ping from one mininet host to another Currently the only supported
Params: SRC and TARGET |
source code
|
|
|
checkIP(self,
host)
Verifies the host's ip configured or not. |
source code
|
|
|
|
|
moveHost(self,
host,
oldSw,
newSw)
Moves a host from one switch to another on the fly
Note: The intf between host and oldSw when detached
using detach(), will still show up in the 'net'
cmd, because switch.detach() doesn't affect switch.intfs[]
( which is correct behavior since the interfaces
haven't moved ). |
source code
|
|
|
changeIP(self,
host,
intf,
newIP,
newNetmask)
Changes the ip address of a host on the fly Ex: h2 ifconfig h2-eth0
10.0.1.2 netmask 255.255.255.0 |
source code
|
|
|
changeDefaultGateway(self,
host,
newGW)
Changes the default gateway of a host Ex: h1 route add default gw
10.0.1.2 |
source code
|
|
|
addStaticMACAddress(self,
host,
GW,
macaddr)
Changes the mac address of a gateway host |
source code
|
|
|
verifyStaticGWandMAC(self,
host)
Verify if the static gateway and mac address assignment |
source code
|
|
|
getMacAddress(self,
host)
Verifies the host's ip configured or not. |
source code
|
|
|
getInterfaceMACAddress(self,
host,
interface)
Return the IP address of the interface on the given host |
source code
|
|
|
getIPAddress(self,
host)
Verifies the host's ip configured or not. |
source code
|
|
|
getSwitchDPID(self,
switch)
return the datapath ID of the switch |
source code
|
|
|
|
|
getInterfaces(self,
node)
return information dict about interfaces connected to the node |
source code
|
|
|
|
|
|
|
|
|
|
|
iperftcpAll(self,
hosts,
timeout=6)
Runs the iperftcp function with a given set of hosts and specified timeout. |
source code
|
|
|
iperftcp(self,
host1="h1",
host2="h2",
timeout=6)
Creates an iperf TCP test between two hosts. |
source code
|
|
|
iperfudpAll(self,
hosts,
bandwidth="10M")
Runs the iperfudp function with a given set of hosts and specified
bandwidth |
source code
|
|
|
iperfudp(self,
bandwidth="10M",
host1="h1",
host2="h2")
Creates an iperf UDP test with a specific bandwidth. |
source code
|
|
|
|
|
|
|
link(self,
**linkargs)
Bring link( s ) between two nodes up or down |
source code
|
|
|
yank(self,
**yankargs)
yank a mininet switch interface to a host |
source code
|
|
|
plug(self,
**plugargs)
plug the yanked mininet switch interface to a switch |
source code
|
|
|
dpctl(self,
**dpctlargs)
Run dpctl command on all switches. |
source code
|
|
|
|
|
|
|
assignSwController(self,
sw,
ip,
port="6633",
ptcp="")
Description:
Assign switches to the controllers ( for ovs use only )
Required:
sw - Name of the switch. |
source code
|
|
|
deleteSwController(self,
sw)
Removes the controller target from sw |
source code
|
|
|
addSwitch(self,
sw,
**kwargs)
adds a switch to the mininet topology
NOTE: This uses a custom mn function. |
source code
|
|
|
delSwitch(self,
sw)
delete a switch from the mininet topology
NOTE: This uses a custom mn function. |
source code
|
|
|
addLink(self,
node1,
node2)
add a link to the mininet topology
NOTE: This uses a custom mn function. |
source code
|
|
|
delLink(self,
node1,
node2)
delete a link from the mininet topology
NOTE: This uses a custom mn function. |
source code
|
|
|
addHost(self,
hostname,
**kwargs)
Add a host to the mininet topology
NOTE: This uses a custom mn function. |
source code
|
|
|
delHost(self,
hostname)
delete a host from the mininet topology
NOTE: This uses a custom mn function. |
source code
|
|
|
disconnect(self)
Called at the end of the test to stop the mininet and disconnect the
handle. |
source code
|
|
|
|
|
arping(self,
host="",
ip="10.128.20.211",
ethDevice="")
Description:
Sends arp message from mininet host for hosts discovery
Required:
host - hosts name
Optional:
ip - ip address that does not exist in the network so there would
be no reply. |
source code
|
|
|
|
|
getSwitchFlowCount(self,
switch)
return the Flow Count of the switch |
source code
|
|
|
|
|
|
|
|
|
startTcpdump(self,
filename,
intf="eth0",
port="port 6633")
Runs tpdump on an interface and saves the file intf can be specified,
or the default eth0 is used |
source code
|
|
|
|
|
|
|
|
|
|
|
|
|
compareSwitches(self,
switches,
switchesJson,
portsJson)
Compare mn and onos switches
switchesJson: parsed json object from the onos devices api |
source code
|
|
|
compareLinks(self,
switches,
links,
linksJson)
Compare mn and onos links linksJson: parsed json object from the onos
links api |
source code
|
|
|
|
|
getHostsOld(self)
Returns a list of all hosts Don't ask questions just use it |
source code
|
|
|
getSwitch(self)
Returns a list of all switches Again, don't ask question just use
it... |
source code
|
|
|
update(self)
updates the port address and status information for each port in mn |
source code
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Inherited from component.Component :
__getattr__ ,
cleanup ,
close_log_handles ,
config ,
experimentRun ,
get_version ,
log
Inherited from object :
__delattr__ ,
__format__ ,
__getattribute__ ,
__hash__ ,
__new__ ,
__reduce__ ,
__reduce_ex__ ,
__repr__ ,
__setattr__ ,
__sizeof__ ,
__str__ ,
__subclasshook__
|