1. 19 Jul, 2004 1 commit
  2. 15 Jul, 2004 1 commit
    • Leigh Stoller's avatar
      Overview: Add Event Groups: · ed964507
      Leigh Stoller authored
      	set g1 [new EventGroup $ns]
      	$g1 add  $link0 $link1
      	$ns at 60.0 "$g1 down"
      
      See the new advanced tutorial section on event groups for a better
      example.
      
      Changed tbreport to dump the event groups table when in summary mode.
      At the same time, I changed tbreport to use the recently added
      virt_lans:vnode and ip slots, decprecating virt_nodes:ips in one more
      place. I also changed the web interface to always dump the event and
      event group summaries.
      
      The parser gets a new file (event.tcl), and the "at" method deals with
      event group events by expanding them inline into individual events
      sent to each member. For some agents, this is unavoidable; traffic
      generators get the initial params in the event, so it is not possible
      to send a single event to all members of the group. Same goes for
      program objects, although program objects do default to the initial
      command now, at least on new images.
      
      Changed the event scheduler to load the event groups table. The
      current operation is that the scheduler expands events sent to a
      group, into a set of distinct events sent to each member of the
      group. At some point we proably want to optimize this by telling the
      agents (running on the nodes) what groups they are members of.
      
      Other News: Added a "mustdelay" slot to the virt_lans table so the
      parser can tell assign_wrapper that a link needs to be delayed, say if
      there are events or if the link is red/gred. Previously,
      assign_wrapper tried to figure this out by looking at the event list,
      etc. I have removed that code; see database-migrate for instructions
      on how to initialize this slot in existing experiments. assign_wrapper
      is free to ignore or insert delays anyway, but having the parser do
      this makes more sense.
      
      I also made some "rename" changes to the parser wrt queues and lans
      and links. Not really necessary, but I got sidetracked (for several
      hours!) trying to understand that rename stuff a little better, and
      now I do.
      ed964507
  3. 12 Jul, 2004 2 commits
  4. 07 Jul, 2004 1 commit
  5. 27 Jun, 2004 1 commit
  6. 08 Jun, 2004 1 commit
    • Leigh Stoller's avatar
      Add slots to virt_lans to rationalize the relationship between · 43a804e9
      Leigh Stoller authored
      virt_lans and virt_nodes. The intent is to migrate away from
      the convention we use in virt_nodes:ips and virt_lans:member
      to a more acceptable representation (one that does not rely
      on textual conventions like space separated lists of colon
      seperated entities. Instead:
      
      	virt_nodes
      		vname:	nodeA
              virt_lans
      		vname:  link0
      		vport:  0
      		ip:     1.1.1.2
      
      		vname:  link1
      		vport:  1
      		ip:     1.1.2.2
      
      	alter table virt_lans add vnode varchar(32) NOT NULL default '' \
      		after vname;
      	alter table virt_lans add vport tinyint(3) NOT NULL default '0' \
      		after vnode;
              alter table virt_lans add ip varchar(15) NOT NULL default '' \
      		after vport;
      
      Then run this script to update these new fields from the
      existing ips,member slots. This must be run after installing
      the parser changes, or you can just run it again.
      
      	./ipmember.pl
      
      This is a transitional phase; the old slots will be left in place
      until they are no longer used, at which time we will also add a
      unique key to the table (pid,eid,vname,vnode,vport). assign_wrapper
      will be the hardest to change, but other scripts should be easy.
      
      Whats vport about? Rather then rely on IP addresses to form a
      unique key, we use vport (a small integer) so that we can delay the
      IP assignment until later (after initial DB insertion).
      43a804e9
  7. 26 May, 2004 1 commit
  8. 25 May, 2004 1 commit
  9. 10 May, 2004 1 commit
    • Robert Ricci's avatar
      Allow the user to give an estimated bandwidth for links and/or LANs. · 923063cc
      Robert Ricci authored
      This is in addition to the normal bandwidth, and the difference is
      that the estimated bandwidth is not enforced. It's just fed to assign
      for mapping decisions. The idea is to allow for more efficient
      packings by doing non-conservative bandwidth allocation.
      
      Not documented yet, because it might change a little after I made it
      work properly with asymmetric links.
      923063cc
  10. 30 Apr, 2004 1 commit
    • Leigh Stoller's avatar
      Small hack requested by Jay to aid in creating wireless nodes; added · 45e5e3c7
      Leigh Stoller authored
      new directive for your NS file: tb-use-physnaming(1) which means that
      if you have a line like this:
      
      	set pc6 [$ns node]
      
      and pc6 is an actual name of a physical node, then do an implicit
      "fixnode" to pc6. In other words, pc6 is the name of the node in your
      NS file (virtual topo) *and* will be fixed to the real pc6. Needless
      to say, if pc6 is allocated when you go to swapin, you lose.
      45e5e3c7
  11. 26 Apr, 2004 1 commit
  12. 21 Apr, 2004 1 commit
  13. 20 Apr, 2004 1 commit
    • Leigh Stoller's avatar
      Brutal hackery to ensure that the startcmd (a program object) has a · cb735156
      Leigh Stoller authored
      well known name so you can control it via the usual event mechanisms
      (ns "at" and tevc). Previously, its name came from an internal
      counter, and because the routine that creates the program object is
      not at "toplevel", the parser would not rename the object. I'm sure
      someone who understands this cruft could do better!
      
      Anyway, now they are named as ${vname}_startcmd.
      cb735156
  14. 12 Apr, 2004 1 commit
    • Leigh Stoller's avatar
      The core of the wireless support code. · 86155d03
      Leigh Stoller authored
      * ptopgen:
      
         1. Change to using interface_capabilities table to get the default
            speed for an interface type.
      
         2. The wrinkle is that an interface can have multiple speeds,
            depending on the protocol that is requested. In the wireless case the
            table looks like:
      
      	| type             | capkey            | capval               |
      	+------------------+-------------------+----------------------+
      	| ath              | protocols         | 80211a,80211b,80211g |
      	| ath              | 80211a_defspeed   | 54000                |
      	| ath              | 80211b_defspeed   | 11000                |
      	| ath              | 80211g_defspeed   | 54000                |
      
         3. We use the above info to tell us the default speed for links, based
            on the particular protocol.
      
         4. And lastly, create "air" switches for each of 80211a, 80211b, 80211g,
            and specify links from the switches to the nodes that have interfaces
            that support those protocols. At the moment, there is a hardwired
            list of 80211a, 80211b, 80211g in ptopgen, so create 3 new air
            switches and links from each of the nodes to each of the switches.
            Rob says that assign can handle this just fine (using the same
            interface on a node to connect to three different air switches, at
            different speeds).
      
      * assign_wrapper:
      
         1. First off, I had to increase the bogousity factor of how we determine
            that a delay node is required (requires_delay() routine) on a link or
            lan. Using the interface_capabilities table, I determine the default
            speed for each protocol on each interface type.
      
         2. When calling requires_delay() I now the pass the lan so that we can
            get the "protocol" of the link/lan and use that to find the default
            speed. The main reason for all this crud is that if a user specifies
            a bandwidth of 54Mb on a wired ethernet, we want to make sure we
            insert a delay node, but not if the user is using 80211g. As it was,
            delay nodes would be skipped cause there are now nodes with
            interfaces that support those speeds. This change also allows to know
            that a delay node should be inserted on a wireless link, if we ever
            wanted to do something as silly as that!
      
         3. Okay, so now onto the actual wireless support!  Whenever the protocol
            for a lan is not "ethernet" spit out links to fake lan nodes, sorta
            like we used to do with ethernet lans before Rob made all those great
            changes to assign. So, a lan with protocol 80211a will get fake links
            to the 80211a air switch that ptopgen spits out (see above).  We
            currently bypass all delay node processing on wireless lans, and in
            fact we avoid most post-processing (after assign) of wireless lans
            (no vlans, veths, etc). At some point we can bring certain things
            back in (like emulated links) but that will be some time! See
            comments above about ptopgen.
      
         4. Added a section to copy over the virt_lan_settings and
            virt_lan_member_settings to the interface_settings table, for each
            node's interfaces in the mapped experiment. I also make up the ssid
            for the lan, and add the protocol to the settings so that the client
            side knows what it is supposed to do. I also set the acesspoint since
            that requires MAC addresses, and this is easiest place to get and set
            the MAC (all of the nodes in a lan need to know the MAC of the node
            acting as the access point). In the virtual topology, the accesspoint
            is specified as a node name.
      
      * tbsetup/ns2ir:
      
         1. Add tb-set-lan-protocol(lan, protocol) to set the protocol to one of
            ethernet, 80211a, 80211b, 80211g. Defaults to ethernet.
      
         2. Add tb-set-lan-accesspoint(lan, accesspoint) to set the name of the
            access point for a lan. Obviously this makes sense for only wireless
            links; ignored for wired links.
      
         3. Add tb-set-lan-setting(lan, setting, value) to specify a setting that
            applies to the entire lan. At present, these are ignored for wired
            lans. Both setting and value are strings.
      
         4. Add tb-set-node-lan-setting(lan, node, setting, value) to specify a
            setting that applies to a particular node in a lan. At present, these
            are ignored for wired lans. Both setting and value are strings.
      86155d03
  15. 08 Apr, 2004 1 commit
  16. 07 Apr, 2004 2 commits
  17. 25 Feb, 2004 1 commit
  18. 13 Feb, 2004 2 commits
  19. 10 Feb, 2004 1 commit
  20. 03 Feb, 2004 1 commit
  21. 02 Feb, 2004 1 commit
  22. 29 Jan, 2004 1 commit
  23. 28 Jan, 2004 1 commit
  24. 26 Jan, 2004 1 commit
  25. 20 Jan, 2004 1 commit
  26. 09 Jan, 2004 1 commit
    • Shashi Guruprasad's avatar
      Changes to do auto re-swap of expts with simnodes when an nse on a simhost · 375f87c1
      Shashi Guruprasad authored
      (or more than one simhost) is unable to keep up with real-time. It includes
      changes to assign_wrapper to handle swap modify for simnodes, the simple
      algorithm in nseswap that bumps up the nodeweight of simnodes being hosted
      on a simhost that reports "can't keep up with real-time" (aka nse violation),
      ptopgen and sim.tcl to prefer nodes that already have the FBSD-NSE image.
      Also, changes to other files to send out NSESWAP event.
      
      One unrelated change: We now have per-swapin .top files and assign.log
      files along with .ptop files. This helps in debugging across multiple
      swapins since files remain in the form of
      <pid>-<eid>-<process_id>.{top,ptop} and assign-<pid>-<eid>-<process_id>.log
      Also useful for archiving.
      375f87c1
  27. 03 Jan, 2004 1 commit
  28. 16 Dec, 2003 1 commit
  29. 15 Dec, 2003 1 commit
    • Shashi Guruprasad's avatar
      Distributed NSE changes. In other words, simulation resources are · d266bd71
      Shashi Guruprasad authored
      now mapped to more than one PC if required. The simnode_capacity
      column in the node_types table determines how many sim nodes can
      be packed on one PC. The packing factor can also be controlled via
      tb-set-colocate-factor to be smaller than simnode_capacity.
      
      - No frontend code changes. To summarize:
        $ns make-simulated {
          ...
        }
        is still the easy way to put a whole bunch of Tcl code to be
        in simulation.
        One unrelated fix in the frontend code is to fix the
        xmlencode() function which prior to this would knock off
        newlines from columns in the XML output. This affected
        nseconfigs since it is one of the few columns with embedded
        newlines. Also changed the event type and event object type
        in traffic.tcl from TRAFGEN/MODIFY to NSE/NSEEVENT.
      
      - More Tcl code in a new directory tbsetup/nseparse
        -> Runs on ops similar to the main parser. This is invoked
           from assign_wrapper in the end if there are simnodes
        -> Partitions the Tcl code into multiple Tcl specifications
           and updates the nseconfigs table via xmlconvert
        -> Comes with a lot of caveats. Arbitrary Tcl code such as user
           specified objects or procedures will not be re-generated. For
           example, if a user wanted a procedure to be included in Tcl
           code for all partitions, there is no way for code in nseparse
           to do that. Besides that, it needs to be tested more thoroughly.
      
      - xmlconvert has a new option -s. When invoked with this option,
        the experiments table is not allowed to be modified. Also,
        virtual tables are just updated (as opposed to deleting
        all rows in the first invocation before inserting new rows)
      
      - nse.patch has all the IP address related changes committed in
        iversion 1.11 + 2 other changes. 1) MTU discovery support in
        the ICMP agent 2) "$ns rlink" mechanism for sim node to real
        node links
      
      - nseinput.tcl includes several client side changes to add IP
        routes in NSE and the kernel routing table for packets crossing
        pnodes. Also made the parsing of tmcc command output more robust
        to new changes. Other client side changes in libsetup.pm and other
        scripts to run nse, are also in this commit
      
      - Besides the expected changes in assign_wrapper for simulated nodes,
        the interfaces and veth_interfaces tables are updated with
        routing table identifiers (rtabid). The tmcd changes are already
        committed. This field is used only by sim hosts on the client side.
        Of course, they can be used by jails as well if desired.
      d266bd71
  30. 10 Dec, 2003 3 commits
  31. 03 Dec, 2003 1 commit
  32. 01 Dec, 2003 2 commits
    • Leigh Stoller's avatar
      If the user does not specify a sync server, do it for them by picking · 581c0389
      Leigh Stoller authored
      the first node in the list. Useful for the linktest stuff, and the
      sync server is harmless.
      581c0389
    • Robert Ricci's avatar
      New scripts: tarfiles_setup, fetchtar.proxy, and webtarfiles_setup . · c0c6547c
      Robert Ricci authored
      The idea is to give us hooks for grabbing experimenters' tarballs (and
      RPMs) from locations other than files on ops. Mainly, to remove
      another dependance on users having shells on ops.
      
      tarfiles_setup supports fetching files from http and ftp URLs right
      now, through wget. It places them into the experiment directory, so
      that they'll go away when the experiment is terminated, and the rest
      of the chain (ie. downloading to clients and os_setup's checks)
      remains unchaged.  It is now tarfiles_setup's job to copy tarballs and
      RPMs from the virt_nodes table to the nodes table for allocated nodes.
      This way, it can translate URLs into the local filenames it
      constructs. It get invoked from tbswap.
      
      Does the actual fetching over on ops, running as the user, with
      fetchtar.proxy.
      
      Should be idempotent, so we should be able to give the user a button
      to run webtarfiles_setup (none exists yet) yet to 'freshen' their
      tarballs. (We'd also have to somehow let the experiment's nodes know
      they need to re-fetch their tarballs.)
      
      One funny side effect of this is that the separator in
      virt_nodes.tarfiles is now ';' instead of ':' like nodes.tarballs,
      since we can now put URLs in the former. Making these consistent is a
      project for another day.
      c0c6547c
  33. 20 Nov, 2003 1 commit
  34. 16 Nov, 2003 1 commit