diff --git a/mininet/conf_parser.py b/mininet/conf_parser.py
index 07eb8c9..ae514f3 100644
--- a/mininet/conf_parser.py
+++ b/mininet/conf_parser.py
@@ -30,18 +30,18 @@
 
     hosts = []
 
-    items = config.items('nodes')
+    items = config.items('hosts')
 	
-	#makes a first-pass read to nodes section to find empty nodes sections
+	#makes a first-pass read to hosts section to find empty host sections
     for item in items:
 	name = item[0]
 	rest = item[1].split()
 	if len(rest) == 0:
-		config.set('nodes', name, '_')
+		config.set('hosts', name, '_')
 	#updates 'items' list
-    items = config.items('nodes')
+    items = config.items('hosts')
 
-	#makes a second-pass read to nodes section to properly add hosts
+	#makes a second-pass read to hosts section to properly add hosts
     for item in items:
 
         name = item[0]
@@ -90,14 +90,22 @@
         uri_list=[]
         cpu = None
         cores = None
+	cache = None
 
-        for uri in uris:
-            if re.match("cpu",uri):
-                cpu = float(uri.split('=')[1])
-            elif re.match("cores",uri):
-                cores = uri.split('=')[1]
-            else:
-                uri_list.append((uri.split(',')[0],uri.split(',')[1]))
+	if '_' in uris:
+		pass
+	else:
+		for uri in uris:
+		    if re.match("cpu",uri):
+			cpu = float(uri.split('=')[1])
+		    elif re.match("cores",uri):
+			cores = uri.split('=')[1]
+		    elif re.match("cache",uri):
+			cache = uri.split('=')[1]
+		    elif re.match("mem",uri):
+			mem = uri.split('=')[1]
+		    else:
+			uri_list.append((uri.split(',')[0],uri.split(',')[1]))
 
         routers.append(confCCNHost(name=name , uri_tuples=uri_list, cpu=cpu, cores=cores))
 
@@ -143,6 +151,3 @@
 
 
     return links
-
-
-
diff --git a/mininet/net.py b/mininet/net.py
index 1255e12..2d6bca6 100644
--- a/mininet/net.py
+++ b/mininet/net.py
@@ -99,6 +99,7 @@
 from mininet.util import quietRun, fixLimits, numCores, ensureRoot
 from mininet.util import macColonHex, ipStr, ipParse, netParse, ipAdd, nextCCNnet
 from mininet.term import cleanUpScreens, makeTerms
+import pdb
 
 # Mininet version: should be consistent with README and LICENSE
 VERSION = "2.0.0"
@@ -176,18 +177,20 @@
            params: parameters for host
            returns: added host"""
         # Default IP and MAC addresses
-
-        defaults = { 'ip': ipAdd( self.nextIP,
-                                  ipBaseNum=self.ipBaseNum,
-                                  prefixLen=self.prefixLen ) +
-                                  '/%s' % self.prefixLen }
-        if self.autoSetMacs:
-            defaults[ 'mac'] = macColonHex( self.nextIP )
-        if self.autoPinCpus:
-            defaults[ 'cores' ] = self.nextCore
-            self.nextCore = ( self.nextCore + 1 ) % self.numCores        
-        self.nextIP += 1
+	#pdb.set_trace()
+        #defaults = { 'ip': ipAdd( self.nextIP,
+                                  #ipBaseNum=self.ipBaseNum,
+                                  #prefixLen=self.prefixLen ) +
+                                  #'/%s' % self.prefixLen }
+        #if self.autoSetMacs:
+            #defaults[ 'mac'] = macColonHex( self.nextIP )
+        #if self.autoPinCpus:
+            #defaults[ 'cores' ] = self.nextCore
+            #self.nextCore = ( self.nextCore + 1 ) % self.numCores        
+        #self.nextIP += 1
+	defaults = {}
         defaults.update( params )
+
         if not cls:
             cls = self.host
         h = cls( name, **defaults )
@@ -286,17 +289,18 @@
 
         info( '*** Creating network\n' )
 
-        if not self.controllers:
+        #if not self.controllers:
             # Add a default controller
-            info( '*** Adding controller\n' )
-            classes = self.controller
-            if type( classes ) is not list:
-                classes = [ classes ]
-            for i, cls in enumerate( classes ):
-                self.addController( 'c%d' % i, cls )
+            #info( '*** Adding controller\n' )
+            #classes = self.controller
+            #if type( classes ) is not list:
+            #    classes = [ classes ]
+            #for i, cls in enumerate( classes ):
+            #    self.addController( 'c%d' % i, cls )
 
         info( '*** Adding hosts:\n' )
         for hostName in topo.hosts():
+	    #pdb.set_trace()
             self.addHost( hostName, **topo.nodeInfo( hostName ) )
             info( hostName + ' ' )
 
@@ -328,6 +332,7 @@
 
     def build( self ):
         "Build mininet."
+
         if self.topo:
             self.buildFromTopo( self.topo )
         if ( self.inNamespace ):
diff --git a/mininet/node.py b/mininet/node.py
index 281839a..8749987 100644
--- a/mininet/node.py
+++ b/mininet/node.py
@@ -55,6 +55,7 @@
                            numCores, retry, mountCgroups, run )
 from mininet.moduledeps import moduleDeps, pathCheck, OVS_KMOD, OF_KMOD, TUN
 from mininet.link import Link, Intf, TCIntf
+import pdb
 
 class Node( object ):
     """A virtual network node is simply a shell in a network namespace.
@@ -728,6 +729,7 @@
 
         self.cmd("export CCND_DEBUG=6")
         self.cmd("export CCND_LOG=./log.{0}".format(self.name))
+	#pdb.set_trace()
 #	print self.params['cache']
 	if self.params['cache'] != None:
 		self.cmd("export CCND_CAP={0}".format(self.params['cache']))
diff --git a/mininet/topo.py b/mininet/topo.py
index fff9604..bd4afb5 100644
--- a/mininet/topo.py
+++ b/mininet/topo.py
@@ -17,11 +17,12 @@
 
 from networkx import Graph
 from mininet.util import irange, natural, naturalSeq
+import pdb
 
 class Topo(object):
     "Data center network representation for structured multi-trees."
 
-    def __init__(self, hopts=None, sopts=None, lopts=None):
+    def __init__(self, hopts=None, sopts=None, lopts=None, ropts=None):
         """Topo object:
            hinfo: default host options
            sopts: default switch options
@@ -30,6 +31,7 @@
         self.node_info = {}
         self.link_info = {}  # (src, dst) tuples hash to EdgeInfo objects
         self.hopts = {} if hopts is None else hopts
+	self.ropts = {} if ropts is None else ropts
         self.sopts = {} if sopts is None else sopts
         self.lopts = {} if lopts is None else lopts
         self.ports = {}  # ports[src][dst] is port on src that connects to dst
@@ -48,8 +50,12 @@
            name: host name
            opts: host options
            returns: host name"""
-        if not opts and self.hopts:
+	#pdb.set_trace()
+        if not opts:
+	 if self.hopts:
             opts = self.hopts
+	 elif self.ropts:
+	    opts = self.ropts
         return self.addNode(name, **opts)
 
     def addSwitch(self, name, **opts):
@@ -102,6 +108,7 @@
 
     def isSwitch(self, n):
         '''Returns true if node is a switch.'''
+	#pdb.set_trace()
         info = self.node_info[n]
         return info and info.get('isSwitch', False)
 
