Mininet

Mininet实验 源码安装Mininet

大兔子大兔子 提交于 2019-12-22 06:27:35
参考: MiniNet实验1 安装命令: sudo apt-get update sudo apt-get upgrade sudo apt-get install git(安装过git就可以忽略此步) git clone git://github.com/mininet/mininet cd mininet cat INSTALL(此步执行之后,出现信息,最后是Good Luck!) //此时在/home/wasdns/mininet目录 util/install.sh -a(-a选项默认安装在home目录,其他选项请参考:http://www.sdnlab.com/15138.html) 测试:sudo mn --test pingall 版本信息:mn --version 2016/9/10 来源: https://www.cnblogs.com/qq952693358/p/5860101.html

2019 SDN上机第1次作业

情到浓时终转凉″ 提交于 2019-12-20 19:04:09
1.作业要求: 安装轻量级网络仿真工具Mininet 用字符命令搭建给定的拓扑结构,并写出命令 利用可视化工具搭建给定的拓扑结构,并要求支持OpenFlow 1.0 1.1 1.2 1.3,设置h1(10.0.0.10)、h2(10.0.0.11)、h3(10.0.0.12),拓扑搭建完成后使用命令验证主机ip,查看拓扑端口连接情况 利用Python脚本完成给定的一个Fat-tree型的拓扑(交换机和主机名需与图中一致,即s1~s6,h1~h8,并且链路正确,请给出Mininet相关截图) 作业博客链接: https://edu.cnblogs.com/campus/fzu/fzusdn2019/homework/9902 2.具体操作步骤与截图说明: 实验环境:VMware Workstation Pro14.1、ubuntu-16.04 (1)安装轻量级网络仿真工具Mininet(使用GitHub源码进行安装): a.先在Ubuntu上安装git,打开终端并输入: sudo apt-get install git 安装成功后终端上会显示如下界面: b.安装git成功后,在终端上输入: sudo git clone http://www.github.com/mininet/mininet git clone成功后终端上会显示如下界面: c.进入mininet目录下的util文件

writing the received data to a text file

允我心安 提交于 2019-12-20 05:26:11
问题 Here is an example of opening a UDP socket in a Mininet host and writing the received packets to a file. h1 acts as a server and h2 acts as a client which is supposed to send a message ( for example "Hello world") to h1. h1 is suppose to receive this message and store the message and address in foo.txt file. But after implementing this code, although foo.txt is created but it's empty and does not contain any data or information. What's wrong? mininetSocketTest.py: #!/usr/bin/python from

Assertion error on mininet-test experiment

笑着哭i 提交于 2019-12-13 05:44:33
问题 My friend and I tried to reproduce this mininet-test experiment: https://github.com/mininet/mininet-tests/tree/master/dctcp We self created a VM and installed Mininet 2.2 on ubuntu with kernel version 3.18.9, which included dctcp and tcp_probe function. Since author suggest kernel version 3.0.1 didn't support those function we needed in Mininetnet. We simply changed the some function name in dctcp.py, such as: add_host changed to addHost , add_switch changed to addSwitch , add_link changed to

Mininet Routing not working

回眸只為那壹抹淺笑 提交于 2019-12-13 01:55:18
问题 I have a problem with Mininet topology. I am trying to make a ping between h3 and h4 . They are connected to same switch s4 . But they can not ping, they are in different subnet, so i am trying to make a flow table for s4 but with no success. Here is image of my topology : after running Mininet I set up this: h3 route add default gw 30.0.0.254 h3-eth0 h3 arp -s 30.0.0.254 00:00:00:00:33:33 h4 route add default gw 40.0.0.254 h4-eth0 h4 arp -s 40.0.0.254 00:00:00:00:44:44 Then I populate s4

How to connect Opendaylight to Mininet?

自闭症网瘾萝莉.ら 提交于 2019-12-12 22:32:42
问题 I've been working in a simple Hello World project to learn the basics for Opendaylight (I was following this tutorial). Now I want to connect this build of the controller to a network topology defined by Mininet but this is not working. I read that this may be due to I haven't installed odl-l2switch but when I type feature:list --installed the bundle doesn't appear and when I type feature:install odl-l2switch it doesn't appear neither. Perhaps it is because the way I created the project: mvn

get_all_link(self) outputting all possible LINKs for a topo

一世执手 提交于 2019-12-12 04:38:06
问题 I have topo with 4 switches and 4 hosts. The switches construct a loop. My goal is to learn the topology of the network when switches are connected to the controller. The problem is that the function get_all_links() returns all of the possible links or at least something that doesn't make sense. I call that function when a port_modify event is fired. Here is the code I use to construct the topo: <Removed Imports to save space> class Simple3PktSwitch(Topo): """Simple topology example.""" def _

How to customize the page sent by SimpleHTTPServer?

五迷三道 提交于 2019-12-12 02:15:55
问题 I am using SimpleHTTPServer class in my code to respond to client requests (it is actually mininet python script for networking project). The client sends a request every 5 seconds to the server 10.0.0.1 : server.cmd('python -m SimpleHTTPServer 80 &') def tcp_thread(client_id): for i in range(180): client_id.cmd('wget -O - 10.0.0.1') time.sleep(5) When tracing using Wireshark, I noticed the server sends a junk page of size 390 bytes something like this: Hypertext Transfer Protocol HTTP/1.0

python socket programming for transferring a photo

本小妞迷上赌 提交于 2019-12-11 15:57:41
问题 I'm new to socket programming in python. Here is an example of opening a TCP socket in a Mininet host and sending a photo from one host to another. In fact I changed the code that I had used to send a simple message to another host (writing the received data to a text file) in order to meet my requirements. Although when I implement this revised code, there is no error and it seems to transfer correctly, I am not sure whether this is a correct way to do this transmission or not. Since I'm

Pox/Mininet: learning location of hosts

你说的曾经没有我的故事 提交于 2019-12-11 02:45:21
问题 My question might be a little vague as I clearly misunderstand a lot, but I'll give it a try anyway: Suppose I have 7 switches in a Fat Tree topology, and the bottom four are each connected to two hosts. When I start the controller I instructs the switches to send LLDP packets and this is how I learn the topology. Also I calculate a Spanning Tree to use when I flood packets like ARP requests. My problem: how do I learn which switch a certain host is connected to? If h1 sends a layer 3 packet