Unfortunately, I can't test this at the moment since nox seems not to be able to find the routing module. Added/renamed examples: grid.py, tree1024.py Added -v flag to nox arguments, so we have some chance of figuring out why nox is dying, as it generally is.
34 lines
997 B
Bash
Executable File
34 lines
997 B
Bash
Executable File
#!/bin/bash
|
|
|
|
# Unfortunately, Mininet and OpenFlow don't always clean up
|
|
# properly after themselves. Until they do (or until cleanup
|
|
# functionality is integrated into the python code), this
|
|
# script may be used to get rid of unwanted garbage. It may
|
|
# also get rid of "false positives", but hopefully nothing
|
|
# irreplaceable!
|
|
|
|
echo "Removing all links of the pattern foo-ethX"
|
|
|
|
for f in `ip link show | egrep -o '(\w+-eth\w+)' ` ; do
|
|
cmd="ip link del $f"
|
|
echo $smd
|
|
$cmd
|
|
done
|
|
|
|
echo "Removing excess controllers/ofprotocols/ofdatapaths/pings"
|
|
killall -9 controller ofprotocol ofdatapath ping 2> /dev/null
|
|
|
|
echo "Removing excess kernel datapath processes"
|
|
ps ax | egrep -o 'dp[0-9]+' | sed 's/dp/nl:/' | xargs -l1 echo dpctl deldp
|
|
|
|
echo "Removing junk in /tmp"
|
|
rm -f /tmp/vconn* /tmp/vlogs* /tmp/*.out /tmp/*.log
|
|
|
|
echo "Killing nox"
|
|
killall lt-nox_core
|
|
killall nox_core
|
|
|
|
echo "Removing old screen sessions"
|
|
screen -ls | egrep -o '[0-9]+\.[hsc][0-9]+' | sed 's/\.[hsc][0-9]*//g' | kill -9
|
|
|