Merge pull request #379 from cdburkard/devel/show_ports
adding 'ports' command to cli
Cluster edition prototype: remote nodes and links.
We add a new experimental feature to allow Mininet to run acrossa cluster of machines. This is currently implemented via a setmix-in classes that provide remote nodes that are implementedvia a connection to a remote shell, and remote links which are...
adding comments and removing random access spaces
fixed syntax error
stop using ONLAB OUI for generated mac addressses
added some documentation
few small fixes to syntax errors
removed comments and cleaned up code.
removed many of the commands being run to maximize startup performance
testing link stuff
Merge pull request #316 from cdburkard:patches/fix_remote_ip
fixed netParse bug that caused mininet crash when no ip prefix was specified
Don't look through all interfaces if you don't need to.
print error messages when making interfaces
without this, thereis no indication in Mininet that creating aninterface has failed. for example, this may happen when the interfacename is too long (longer than IFNAMSIZ, which is 16 chars).
removing assert from util.py
Updated mininet/util.py to support better resource setting semantics and protected with try block
Some cleanup and style fixes for fixlimits
Cleaned up sysctl and rlimit test and setUse files instead of sysctl to set limits
add sysctl test and setfixes #184
Fix issue with mountCgroups not recognizing mounted cgroup
Changed mountCgroups to use the file /proc/mounts (instead of thecurrent case where it uses the less reliable(http://email@example.com/msg00455.html)/etc/mtab thorugh the mount program
Change to only split once so that cargs='--foo=1 --bar=2' works.fixes #144
Add source node option to moveIntf() (note: low-level API!!)In the future we may wish to enable moving interfaces acrossnodes which are not in the root NS, and this would providethe low-level mechanism to do so.closes #122
fix --ipbase: fix ipAdd() and remove unused default from ipStr()
Fix pmonitor() to not return blank lines on EOFfixes #109 (hopefully)
Merge branch '2.0dev' into 2.0merge
Conflicts: .gitignore .pylint examples/miniedit.py mininet/node.py mininet/util.py util/install.sh util/vm/install-mininet-vm.sh
small refactor: put function to ensure root in util
Two benefits:- One place to change if in the future, a more granular method of root access is used (like the BigSwitch patch).- Makes this reusable by stuff like examples/baresshd.py that use the low-level Mininet API.
Fix 'cgroups not mounted' error in U12.10
'mount' shows something slightly different in Ubuntu 12.10:
cgroup on /sys/fs/cgroup type tmpfs (rw,uid=0,gid=0,mode=0755)
Note the lack of a plural on first word cgroup, which has changed.
Still mounted at /sys/fs/cgroup, so check for both possibilities...
pep8: fix E128 continuation line under-indented errors
I wasn't sure this was worth fixing at first, but it does look more readablenow.
pep8: Fix E711, comparisons to None should use 'is' or 'is not'
Lengthy discussion of why this is a good thing (I didn't know) at SO:
pep8: Fix E271/E272, spaces before/after keyword
Avoid modifying keyword parameter dictionary in customized()
Add custom name to customized functions.
Note: we could probably use functools.partial.
Workaround for openvswitch_mod rename and pass code check.
Move code from mn into mininet/util to enable reuse
Any code in mn is not usable by other Python code.
Hence, move this code into util, so other scripts can use it.
Pass code check.
Fix errRun to not exit until all of stdout and stderr have been read.
Add pmonitor() to make it easy to monitor popen objects.
Apparently errRun isn't as flexible as I thought...
Add mountCgroups() and tweak/correct fixLimits()
Move dumpNetConnections to util() because it's useful!
Have errFail report cmd and stderr as well as exit code.
Attempt at revised/simplified topo class:
- keys are strings- metadata is simply a dict- buildFromTopo greatly simplified
Fix codecheck and MininetWithControlNet.
Add support for specifying host IP range with --ipbase.
Fix examples to work with new API (and vice-versa.)
Add custom() function for customizing constructors.
Tweak errRun; add errFail and numCores.
Fix pylint complaint and add natural sort key function.
Add errRun to run a command with stderr, stdout, return code and monitoring.
Fixed link check and updated quietRun interface.
Link check wasn't quite right - e.g. 'eth1' could be found in'eth10' previously.
Updated quietRun to allow passing in args directly rather thanas a list.
Support for control-C. Finally.
I've changed the way things work a bit:
1. netns is replaced by mnexec, a general-purpose mininet helper.
2. For interactive commands, we now use mnexec -p, which prints out the pid, so we can kill it when someone hits control-C!...
Added newline at EOF.
Reinstantiated inNamespace and routed control network.
We need to figure out how to specify the IP addresses for therouted control network. For now I'm going back to 192.168.12x.y
Also changed controller params to use IP strings rather thannumbers. However, we still need to clarify what ControllerParams...
Removed underscores for public Node methods. Minor cleanup & comments.
Add flexible topology input parsing
Now you can pass a topology name followed by params. For example, tocreate a switch with 3 hosts:
sudo mn --topo single,3
Moved link creation into Node.addIntf() and fixed util:CreateLink().
Also tweaked cmd/cmdPrint to make them more beautiful and functional,and a few other minor changes, such as using a new idiom for verbose.
These changes support reinstating the examples.
Removed hash-bang in module files which aren't executed directly,with the exception of topo.py, which I haven't touched.
Comment tweaks and additions.
Minor changes to get 'make test' to pass.
- some namespace conflicts due to unpep8- fixed infinite recursion caused by removing redundant makeIntfPair
First crack at restoring mininet python style, assisted by handy'unpep8' script, which does most of the work.
- topo.py is still in pep8- not all examples work, but this is due to other issues
Renamed logging_mod.py -> log.py
Updated other files accordingly.
Add static code checking for style and errors
This required a change to logging, which now uses a singleton pattern.
For all future checkins, 'make codecheck' should pass.
Add options for auto MAC and ARP setup.
Auto MAC setup sets each host MAC equal to its DPID, which simplifiesdebugging.
Auto ARP setup removes the need for broadcast support for ARP, whichenables a smaller NOX controller.
Increase createLink retry count
Was seeing occasional errors with tests run back-to-back.
Add MAC auto set for switches
Also use indexing for DPIDs to avoid zeroed MAC
Move fixLimits function to util
Move utility functions out of mininet.py
Having a file with the same name as its package creates hard-to-diagnoseimport error, so rename mininet.py to net.py. This commit moves utilityfunctions, generally those dealing with network namespaces and interface...