I need to break the network into parts and emulate each part on my Linux machine. For example, on machine No. 1 the following topology is launched:
class MyTopology(Topo):
def __init__(self):
super().__init__()
s1 = self.addSwitch(name='s1', protocols='OpenFlow13', dpid='0000000000000001')
h1 = self.addHost(name='h1', ip='1.2.3.1/24')
s2 = self.addSwitch(name='s2', protocols='OpenFlow13', dpid='0000000000000002')
self.addLink(s1, h1, delay='5ms')
self.addLink(s1, s2, delay='5ms')
On machine No. 2 the following topology is launched:
class MyTopology(Topo):
def __init__(self):
super().__init__()
s3 = self.addSwitch(name='s3', protocols='OpenFlow13', dpid='0000000000000003')
s4 = self.addSwitch(name='s4', protocols='OpenFlow13', dpid='0000000000000004')
self.addLink(s3, s4, delay='5ms')
I want to link the switches s1, s3 and s2, s3. To get the topology:
+-----+
| h1 |
+-----+
|
|
|
+----+-----+
| s1 |
+-----------+
/ \
/ \
+----+----+ +----+----+
| s2 |----------| s3 |
+----+----+ +----+----+
/
/
+-----------+
| s4 |
+----+------+
I tried to do
Intf('enp0s9', node=s1)
Intf('enp0s9', node=s2)
by car No. 1.
Intf('enp0s9', node=s3)
by car No. 2 machines are connected to a local network by the "enp0s9" interface, but when you try to attach one interface to two switches, they stop connecting to the controller.