1. 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
  2. 07 Jul, 2004 1 commit
  3. 27 Jun, 2004 1 commit
  4. 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
  5. 07 Apr, 2004 1 commit
  6. 10 Feb, 2004 1 commit
  7. 03 Feb, 2004 1 commit
  8. 28 Jan, 2004 1 commit
  9. 18 Oct, 2003 1 commit
  10. 17 Sep, 2003 1 commit
  11. 11 Sep, 2003 1 commit
  12. 05 Aug, 2003 1 commit
    • Leigh Stoller's avatar
      The rest of the sync server additions: · 212cc781
      Leigh Stoller authored
      * Parser: Added new tb command to set the name of the sync server:
      
      	tb-set-sync-server <node>
      
        This initializes the sync_server slot of the experiment entry to the
        *vname* of the node that should run the sync server for that
        experiment. In other words, the sync server is per-experiment, runs
        on a node in the experiment, and the user gets to chose which node
        it runs on.
      
      * tmcd and client side setup. Added new syncserver command which
        returns the name of the syncserver and whether the requesting node
        is the lucky one to run the daemon:
      
          SYNCSERVER SERVER='nodeG.syncserver.testbed.emulab.net' ISSERVER=1
      
        The name of the syncserver is written to /var/emulab/boot/syncserver
        on the nodes so that clients can easily figure out where the server
        is.
      
        Aside: The ready bits are now ignored (no DB accesses are made) for
        virtual nodes; they are forced to use the new sync server.
      
      * New os/syncd directory containing the daemon and the client. The
        daemon is pretty simple. It waits for TCP (and UDP, although that
        path is not complete yet) connections, and reads in a little
        structure that gives the name of the "barrier" to wait for, and an
        optional count of clients in the group (this would be used by the
        "master" who initializes barriers for clients). The socket is saved
        (no reply is made, so the client is blocked) until the count reaches
        zero. Then all clients are released by writting back to the
        sockets, and the sockets are closed. Obviously, the number of
        clients is limited by the numbed of FDs (open sockets), hence the
        need for a UDP variant, but that will take more work.
      
        The client has a simple command line interface:
      
          usage: emulab-sync [options]
          -n <name>         Optional barrier name; must be less than 64 bytes long
          -d                Turn on debugging
          -s server         Specify a sync server to connect to
          -p portnum        Specify a port number to connect to
          -i count          Initialize named barrier to count waiters
          -u                Use UDP instead of TCP
      
          The client figures out the server by looking for the file created
          above by libsetup (/var/emulab/boot/syncserver). If you do not
          specify a barrier "name", it uses an internal default. Yes, the
          server can handle multiple barriers (differently named of course)
          at once (non-overlapping clients obviously).
      
          Clients can wait before a barrier in "initialized." The count on
          the barrier just goes negative until someone initializes the
          barrier using the -i option, which increments the count by the
          count. Therefore, the master does not have to arrange to get there
          "first." As an example, consider a master and one client:
      
      	nodeA> /usr/local/etc/emulab/emulab-sync -n mybarrier
      	nodeB> /usr/local/etc/emulab/emulab-sync -n mybarrier -i 1
      
          Node A waits until Node B initializes the barrier (gives it a
          count).  The count is the number of *waiters*, not including the
          master. The master is also blocked until all of the waiters have
          checked in.
      
          I have not made an provision for timeouts or crashed clients. Lets
          see how it goes.
      212cc781
  13. 10 Jul, 2003 1 commit
    • Leigh Stoller's avatar
      Two sets of minor changes. · 7d0f59e6
      Leigh Stoller authored
      * In the parser, make -n (impotent) and -a (anonymous) more
        independent. Used to be that -n required -a, but that makes the
        preparse less useful, since it cannot catch project related errors
        (like bad osids, or node type permissions), and so the user does not
        get that until the email message later. Thats so annoying, even Mike
        whined about it.
      
        Note that impotent mode is sorta misnamed now, since the parse never
        operates on the DB. Rather, impotent mode now skips doing the XML
        output phase (still aptly named updateDB!).
      
      * Add -p (pass) option. I added this for my script that was parsing
        all the old NS files to get renderings. In this case, I do not want
        -n or -a; I want to upload the results into the DB, but the project
        related checks are obviously going to fail since I was doing it
        inside the testbed project. So, -p turns on some of the anon checks,
        and later might be used to turn certain features that are no longer
        supported, since all we really care about is the toplology (some NS
        files failed on old features and syntax).
      
      Upon reflection I think these three options could probably be rolled
      into just two, by cleaning up the current impotent and anonymous
      flags.
      7d0f59e6
  14. 03 Jul, 2003 1 commit
  15. 30 Jun, 2003 1 commit
    • Leigh Stoller's avatar
      Make the new parser live on mini. New parser ssh'es over to ops to · 2202fc5a
      Leigh Stoller authored
      do the actual parse. The parser now spits out XML instead of DB
      queries, and the wrapper on boss converts that to DB insertions after
      verification. There are some makefile changes as well to install the
      new parser on ops via NFS, since otherwise the parser could
      intolerably out of date on ops!
      2202fc5a
  16. 05 Jun, 2003 1 commit
  17. 29 Apr, 2003 1 commit
  18. 18 Mar, 2003 1 commit
  19. 25 Feb, 2003 1 commit
    • Leigh Stoller's avatar
      Add tb-set-uselinkdelays to switch between normal delay nodes and · 46155476
      Leigh Stoller authored
      link delays setup on the nodes.
      
      Add tb-set-forcelinkdelays to force a linkdelay (when uselinkdelays is
      on of course) to be inserted, even if the link was unshaped. This
      allows it to be controlled later, say via the event system. This is
      nice, cause in the current system an unshaped link cannot be later
      shaped.
      
      Note that these are currently require FBSD-47.
      46155476
  20. 15 Jan, 2003 1 commit
  21. 18 Dec, 2002 1 commit
    • Leigh Stoller's avatar
      Allow slightly altered tb-fix-node syntax for creating jails on local · d564e0fb
      Leigh Stoller authored
      nodes. The second argument can now be an NS node instead of the name
      of a real testbed node. For example:
      
      	tb-set-hardware $node3  pc600
      	tb-set-hardware $nodev1 pcvm600
      	tb-fix-node $nodev1 $node3
      
      So, "fix" $nodev1 to $node3. The intent is that once $node3 is
      allocated by assign to a real testbed node, we can then allocate a
      virtual node on pcXX to $nodev1. I did this primarily to allow for
      easy testing of jails via my NS file, without having to hack assign
      wrapper to deeply. Note there are still hacks in assign_wrapper to
      support this, but they are not extensive.
      
      Also my old usewatunnels stuff I never checked in:
      
      	tb-set-usewatunnels 0/1
      d564e0fb
  22. 06 Nov, 2002 1 commit
    • Shashi Guruprasad's avatar
      NSE related changes: · 05bc3bd4
      Shashi Guruprasad authored
        - Fixes the routing problem
        - A new type "sim" has been created but not in the DB. node_types and
          nodes remain unchanged. This will change after we figure out how
          to represent in the DB the local multiple virtnodes in one phynode case
          The frontend tb_compat.tcl adds the sim type and ptopgen associates
          a huge number of sim nodes to all local PCs.
        - All simulated nodes go into one pc untill I finish coding the distributed
          nse case. Also, sim nodes go through assign but with an explicit
          "fix-node" directive in the top file. A random free pc is chosen using
          the avail script in assign_wrapper. If we don't fix node it, assign
          maps sim nodes to multiple phy nodes even when a valid all to one
          mapping is possible.
        - Syntax for nse:
      
         $ns make-simulated {
      
             set simnode1 [$ns node]
             set simnode2 [$ns node]
      
         }
         ...
      
         The old syntax
      
         set nsenode [$ns nsenode]
         $nsenode make-simulated {
         }
      
         is deprecated
      
        - All 38 frontend tests in the testsuite pass
      
        - A new table v2pmap has been added to handle multiple virt nodes to
          one phy node mapping. This is used in "tmcc hostnames" currently.
      
        - The phy node that is picked to run nse is loaded with a custom image
          FBSD45-NSE . This can use the default FBSD kernel if there is a mechanism
          to run at 1000HZ, have options IPFIREWALL_FORWARD and PERFMON turned on.
          The image is in the 'testbed' group. Do not delete this image.
      
        - Static routes now adds routes for the case dst == nexthop. The routing
          graph would be disconnected otherwise and I need to traverse this in
          assign_wrapper for nse. On the client side, such a route is filtered out in
          libsetup.pm
      
        - sim nodes are also correctly visualized
      05bc3bd4
  23. 04 Nov, 2002 1 commit
  24. 07 Jul, 2002 1 commit
  25. 03 Jul, 2002 1 commit
  26. 17 Jun, 2002 1 commit
  27. 31 May, 2002 1 commit
  28. 22 May, 2002 1 commit
  29. 14 May, 2002 2 commits
  30. 25 Apr, 2002 1 commit
    • Leigh Stoller's avatar
      Fix contributed by Brian. The general idea is to allow global · 0f774f51
      Leigh Stoller authored
      variables to be renamed from within a subroutine:
      
      	proc create_testnet {} {
      		set s1 [$ns node]
       	}
      
      Chris' redefined set did not allow this. This is further complicated
      by the fact that its difficult to tell whats a global variable. You
      can declare a variable global, but until its set for the first time,
      the TCL info function will not tell you its a global. We do not want
      to rename locals of course, since that would make no sense to do.
      Anyway, Brian contributed the code to fix the new set function, and I
      looked at it and did my best to understand it (I kinda do), but no way
      I can be sure! I ran it through the test suite and spot checked the DB
      state. Seems to work okay.
      0f774f51
  31. 22 Apr, 2002 1 commit
  32. 26 Mar, 2002 1 commit
  33. 25 Mar, 2002 1 commit
  34. 22 Mar, 2002 1 commit
    • Leigh Stoller's avatar
      Add new NS program object. This syntax is different than I had · b9ba3398
      Leigh Stoller authored
      originally anticipated, but I was worried about confusion with the
      Agent/Application API that NS provides, and which is substantially
      different than this. Anyway, I added support for this syntax:
      
      	set prog0 [$ns program]
      	$prog0 set node $nodeA
      	$prog0 set command "/bin/ls -lt >& /users/stoller/logs/foo"
      
      Kinda obvious, although whats not obvious is that without events to
      start and stop them, these will never run. So, I added support for
      this:
      
      	$ns at 10 "$prog0 start"
      	$ns at 20 "$prog0 stop"
      
      You can start and stop programs as much as you like, but you cannot
      start a program that is already running; you have to stop it first.
      You can also issue these dynamically using the same api:
      
      	tevc -e testbed/Tevents now prog0 start \
      		"command=/bin/ls -lt / >& /users/stoller/logs/foo"
      	tevc -e testbed/Tevents now prog0 stop
      
      Note the quotes when using a multiword command. I also had intened to
      support a KILL command so that you could send arbitrary signals to a
      process. I added that, but I will not bother to document it yet; since
      I invoke /bin/csh to process the command line, the issue of signals is
      a little fuzzy. Sending a signal like -HUP to the parent process (the
      csh) is not really what we want to do. I think we can support this,
      but I need to poke around and see what the right way is.
      b9ba3398
  35. 16 Mar, 2002 1 commit
  36. 25 Feb, 2002 1 commit
  37. 08 Jan, 2002 1 commit
  38. 20 Dec, 2001 1 commit
  39. 27 Nov, 2001 1 commit