1. 20 Feb, 2002 1 commit
    • Robert Ricci's avatar
      Code for picking which VLANs are allowed to go across which trunks. · 11e0ea5f
      Robert Ricci authored
      As much of it as possible switch-independant, and put in snmpit_lib.
      Should work for arbitrarily complicated switch toplogies, as long as
      there are not multiple trunks between two switches. (Multiple ports
      combined into one trunk are fine, however.)
      
      As a result of this, VLAN creations and deletions now need to operate
      on all switches, not just on the ones that have ports in the VLAN.
      This is because the traffic may have to traverse switches that have no
      ports in the VLAN to reach other switches that do.
      
      Not called yet. I've done simple testing, but need to do more, as this
      could get us into major trouble if it has bugs.
      11e0ea5f
  2. 14 Feb, 2002 2 commits
  3. 12 Feb, 2002 5 commits
  4. 11 Feb, 2002 1 commit
    • Robert Ricci's avatar
      Two new functions: · 5db6c935
      Robert Ricci authored
      getTrunks: Build a structure representing all of the trunks in the switch
      	topolgy
      getTrunkPath: Find the shortest path between two switches, across the
      	trunks found by getTrunks
      
      Note that the getTrunkPath duplicates some work done in assign. However, we
      don't currently have a good way to pass this information from assign to
      snmpit, and we need to be able to figure this out anyway, in case snmpit
      isn't being called as part of experiment swapin.
      
      These functions should soon be used to pick which VLANs are allowed
      across which trunks.
      5db6c935
  5. 08 Feb, 2002 2 commits
    • Leigh B. Stoller's avatar
      Kill of savevlans since its simply a snapshot of DB state, and not · c8c2b569
      Leigh B. Stoller authored
      very useful by itself anyway.
      c8c2b569
    • Leigh B. Stoller's avatar
      Big round of image/osid changes. This is the first cut (final cut?) at · a73e627e
      Leigh B. Stoller authored
      supporting autocreating and autoloading images. The imageid form now
      sports a field to specify a nodeid to create the image from; If set,
      the backend create_image script is invoked. Thats the easy part.
      Slightly harder is autoloading images based on the osid specified in
      the NS file. To support this, I have added a new DB table called
      osidtoimageid, which holds the mapping from osid/pctype to imageid.
      When users create images, they must specify what node types that image
      is good for. Obviously, the mappings have to be unique or it would be
      impossible to figure it out! Anyway, once that image mapping is
      in place and the image created, the user can specify that ID in the NS
      file. I've changed os_setup to to look for IDs that are not loaded,
      and to try and find one in the osidtoimageid. If found, it invokes
      os_load. To keep things running in parallel as much as possible,
      os_setup issues all the loads/reboots (could be more than a single set
      of loads is multiple IDs are in the NS file) at once, and waits for
      all the children to exit. I've hacked up os_load a bit to try and be
      more robust in the face of PXE failures, which still happen and are
      rather troublsesome. Need an event system!
      
      Contained in this revision are unrelated changed to make the OS and
      Image IDs per-project unique instead of globally unique, since thats a
      pain for the users. This turns out to be very messy, since underneath
      we do not want to pass around pid/ID in all the various places its
      used. Rather, I create a globally unique name and extened the OS and
      Image tables to include pid/name/ID. The user selects pid/name, and I
      create the globally unique ID. For the most part this is invisible
      throughout the system, except where we interface with the user, say in
      the web pages; the user should see his chosen name where possible, and
      the should invoke scripts (os_load, create_image, etc) using his/her
      name not the internal ID. Also, in the front end the NS file should
      use the user name not the ID. All in all, this accounted for a number
      of annoying changes and some special cases that are unavoidable.
      a73e627e
  6. 07 Feb, 2002 1 commit
  7. 01 Feb, 2002 1 commit
    • Mike Hibler's avatar
      Yet another attempt to Get It Right based on our latest half-assed · 609c547e
      Mike Hibler authored
      understanding of how mountd operates.
      
      Things that should be fixed:
      
      1. It iterates over every node calculating what directories are exported,
         what FSes they are on, etc.  Most of that work only needs to happen
         per experiment.
      
      2. The algorithm to determine what FS a directory is on is a hack.  I just
         take the first component of the path provided.  As long as we mount all
         our FSes at the top level and configure with canonical pathes, this is
         ok.  Other solutions require calling out to the ops node to get actual
         mount info.
      
      3. Once shared experiments are revived, the code to determine exported
         directories will need to change.  The algorithm for computing the
         exports lines should still be correct.
      609c547e
  8. 31 Jan, 2002 1 commit
  9. 30 Jan, 2002 2 commits
  10. 28 Jan, 2002 2 commits
  11. 23 Jan, 2002 4 commits
    • Robert Ricci's avatar
      New option: -c . Clears all VLANs are re-creates them from the · cee6ab9c
      Robert Ricci authored
      database.  Intended to be used to recover switch state after a
      crash or power outage.
      
      This option is farily dangerous, as it temporarily disrupts all
      experimental traffic, and will remove all hand-created VLANs.
      So, it interactively asks for confirmation that the user (who
      must be an admin, of course) really wants to do this.
      cee6ab9c
    • Robert Ricci's avatar
    • Robert Ricci's avatar
      There should _NOT_ be die()s in the modules, as this prevents · ae79f02d
      Robert Ricci authored
      things from getting cleaned up on failure.
      ae79f02d
    • Robert Ricci's avatar
      Some minor API changes to increase effieciency for Intels. · 9bd1dded
      Robert Ricci authored
      First, the stack-level createVlan() function no longer takes as an
      argument a list of devices the VLAN exists on, since it looks like
      this will never be needed.
      
      In it's place, createVlan() now takes a list of ports, so that it can
      (if so desired) put the ports in the VLAN without a seperate lock and
      unlock.
      
      The snmpit_intel module now uses its 'nested locking' feature to avoid
      additional locking in these cases. Note though, that the way that this
      is done is not safe for multiple switches in a stack. If we ever have
      to support multiple Intels (looks doubtful), this will have to be
      removed, or locking will need to be moved a level up to
      snmpit_intel_stack . Yuck.
      
      For Intels, the removeVlan() function calls removePortsFromVlan()
      itself, again to save locking overhead. The Cisco behavior, however,
      is unchanged, as locking is not expensive, and this would be too
      messy.
      9bd1dded
  12. 22 Jan, 2002 5 commits
  13. 18 Jan, 2002 8 commits
  14. 17 Jan, 2002 4 commits
  15. 16 Jan, 2002 1 commit