0
votes

I got the error (AttributeError: 'Mininet' object has no attribute 'addBaseStation') when I tried running the "position-test.py" script in mininet-wifi' online Tutorial.

I went through possible solutions online and I later saw this:

[mininet-wifi error:'Mininet' object has no attribute 'addBaseStation'.

I tried what they proposed as solution but didn't work for me. It gave error thus:

Blockquote

*** Creating nodes

*** Enabling association control (AP)

*** Creating links and associations

Associating sta1-wlan0 to ap1

Associating sta2-wlan0 to ap2

*** Starting network

*** Configuring hosts

* defaultIntf: warning: sta1 has no interfaces

Traceback (most recent call last):

File "position-test.py", line 46, in topology()

File "position-test.py", line 33, in topology net.build()

File "/usr/local/lib/python2.7/dist-packages/mininet-2.0r2-py2.7.egg/mininet/net.py", line 1273, in build self.configHosts()

File "/usr/local/lib/python2.7/dist-packages/mininet-2.0r2-py2.7.egg/mininet/net.py", line 1126, in configHosts host.configDefault(ip=None, mac=None)

File "/usr/local/lib/python2.7/dist-packages/mininet-2.0r2-py2.7.egg/mininet/node.py", line 1064, in configDefault self.config(**self.params)

File "/usr/local/lib/python2.7/dist-packages/mininet-2.0r2-py2.7.egg/mininet/node.py", line 1050, in config if len(ip) > 1:

TypeError: object of type 'NoneType' has no len()

Blockquote

What could possibly be wrong, because, I've tried running other examples and all were running normally. Though, they do not contain the function "addBaseStation" in them. Is there any way around this or any possible solution please. Thank you.

1

1 Answers

0
votes

check out examples/2AccessPoints.py

addBaseStation(...) seems to be from an older version that is deprecated. Instead addAccessPoint(...) is used. Also if you are using net.associationControl( 'ssf' ) to configure the wifi nodes, instead use net.configureWifiNodes()