title: Using Mininet's Python API addHost() Method
body: <p>I am experiencing connectivity issues when adding hosts to a topology by calling Mininet's addHost() method. The hosts are unable to ping one another, or any outside ip address (by way of the NAT). A simple example of what I am trying to do would be the following:</p>
  
  <pre><code>from mininet.net import Mininet
  from mininet.cli import CLI
  
  net = Mininet()
  h1 = net.addHost('h1')
  h2 = net.addHost('h2')
  s1 = net.addSwitch('s1')
  
  net.addLink(s1,h1)
  net.addLink(s1,h2)
  net.addNAT().configDefault()
  net.build()
  
  CLI(net)  
  </code></pre>
  
  <p>I also don't experience this problem when supplying a topology to the Mininet class constructor, however for what I am doing I require the ability to add hosts after the Mininet instance has been instantiated (like in the above example). Am I doing something wrong?</p>
  
  <p>Edit: I should note that I am using Mininet 2.2.1 inside the supplied VM image.</p>