1. 11 Feb, 2002 2 commits
    • Leigh B. Stoller's avatar
      Add boottime init script to clear various DB tables at boot time, or · 31bf08b9
      Leigh B. Stoller authored
      whatever other maintenance is required.
      31bf08b9
    • Leigh B. Stoller's avatar
      Changes to how the backup files are named and saved. The existing · b31fdcdc
      Leigh B. Stoller authored
      naming scheme was not very intuitive and the names sucked. Also, I
      want to increase the frequency with which we run the backups, and I
      want to implement an automated roll so that we only keep about a
      months worth of history around.
      
      Anyway, the new approach is to open up the index file and see what the
      name of the current update file is. It has a numeric extension. Rename
      the base log to base.XXX, and then snapshot the DB into backup.XXX So,
      the combination of update.XXX and base.XXX is the DB history since the
      last time the script was run. The file backup.XXX corresponds to the
      DB at this point in time.
      
      To restore (or track the changes of) a DB, simply take backup.XXX and
      apply the changes that are stored in update.XXX+1 (which are the changes
      made since backup.XXX was made). This should give you a DB that is the
      same as backup.XXX+1. You can go back further, and just apply all the
      subsequent update.XXX files.
      b31fdcdc
  2. 08 Feb, 2002 12 commits
    • Leigh B. Stoller's avatar
      Font changes to for Jay! · 9635df85
      Leigh B. Stoller authored
      9635df85
    • 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
    • Leigh B. Stoller's avatar
      d3410f30
    • Leigh B. Stoller's avatar
      Trivial syntax change. · d177592f
      Leigh B. Stoller authored
      d177592f
    • Leigh B. Stoller's avatar
    • Leigh B. Stoller's avatar
      Another Opera revelation. This is actually incorrect, even though · 3389881e
      Leigh B. Stoller authored
      Netscape and IE both recognize it:
      
      	<input type=readonly ... >
      
      The correct way is:
      
      	<input readonly type=text ...>
      
      Hmm.
      3389881e
    • Leigh B. Stoller's avatar
      Add $TBMAINSITE=0 default. · d720a46b
      Leigh B. Stoller authored
      Fix up SUEXEC and TBERROR error handling so that <XMP> tags are not
      included in the email message!
      Add CHECKURL() function (which will eventually replace VERIFYURL())
      which returns error strings instead of calling USERERROR. This is
      in support of new forms code.
      Add CHECKPASSWORD() function; same code was in three different places.
      This version returns the error string from checkpass.
      d720a46b
    • Leigh B. Stoller's avatar
      bbeaddcf
    • Leigh B. Stoller's avatar
      Add $TBMAINSITE variable, defaults to 0 but is 1 in the main defs · be6c1b54
      Leigh B. Stoller authored
      file. Controls whether we spit out the keywords and the emu page,
      since we do not want anyone but else getting the links.
      be6c1b54
    • Leigh B. Stoller's avatar
      New front page picture. Taken by Dave, edited by Rob, reduced by me! · 69db4fcd
      Leigh B. Stoller authored
      Also moved the picture to make the text look better.
      69db4fcd
    • Leigh B. Stoller's avatar
      Add web crawler page with nice words. Linked in from the menu, so it · a221a011
      Leigh B. Stoller authored
      gets spit out a lot in all of the pages (http or https).
      Refine fonts and little bits in the banner.
      a221a011
  3. 07 Feb, 2002 4 commits
  4. 04 Feb, 2002 1 commit
    • Robert Ricci's avatar
      Improved output (include column name in the output for violations.) · a9532a33
      Robert Ricci authored
      Also implemented a simple cache for previously-queried keys. Now
      stores the keys found in, say, nodes.node_id, so when another
      table references this key, we don't need to do another database
      query. This improves performance significantly, and is nicer to
      the databse server.
      a9532a33
  5. 01 Feb, 2002 6 commits
    • Robert Ricci's avatar
      Added some checks for key types, etc. that are currently not used in · 6d6d755b
      Robert Ricci authored
      the testbed database anywhere. Otherwise, they could accidentally be
      mistaken for columns.
      
      Now, all table options (the 'create_definition' rule in the MySQL
      documentation for 'CREATE TABLE') are recognized.
      6d6d755b
    • Leigh B. Stoller's avatar
      Fix up mounts command to make sure that groups are respected; we were · 35e306cc
      Leigh B. Stoller authored
      return mount specs for people in the project instead of the group.
      Harmless, since the mounts would fail as long as exports_setup was
      doing the right thing.
      35e306cc
    • 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
    • Robert Ricci's avatar
    • Robert Ricci's avatar
      New script: schemadiff - a script to sync up the schemas of two · 83341399
      Robert Ricci authored
      databases. This script is not quite ready for usage - I've done some
      testing, but more testing shuld be done before it's widely used.
      
      From the usage message:
      Prints on stdout a set of SQL commands to change the database
      from file1 so that it has the same schema as the database from
      file2 (same argument order as diff)
      
      The files given are the output of mysqldump for the two databases -
      the dump ouput can contain oly column definitions, or it can contain
      row information (which is ignored.)
      
      This script can find and fix: created/dropped tables, created/dropped
      columns, columns that have had type chages, renamed columns, changes
      in primary and other (non-primary) keys. It keeps columns in order
      when creating new tables and adding columns.
      
      There a few things that I still want to do with this script:
      
      Make a framework for populating columns. For example, if column 'foo'
      is added, it would look in some location for a script that would
      populate this column.
      
      Create a wrapper that connects to the database to be updated, backs it
      up, locks all tables, applies the changes, and can recover if
      something goes wrong.
      
      Add a 'safe mode' (which would be the default), which won't remove
      columns or tables.
      
      There are a few caveats:
      
      Columns that have been _both_ renamed and had their type changed will
      be dropped and re-created, since it's impossible to detect this case.
      
      There may be some ordering issues. For example, the primary key for a
      table may need to be dropped before you can allow a column that used
      to be in the primary key in the primary key to contain NULLs.
      
      Will only work in one direction - a master-slave type relationship. If
      used between databases that have _both_ been changed, changes in the
      database being updated first will be lost.
      83341399
    • Leigh B. Stoller's avatar
      Fix up the hostnames command after much bitrot and frobification. · f670883d
      Leigh B. Stoller authored
      Started from scratch! Much simpler now that most of the information
      is stored in the virt_nodes and virt_lans table.
      f670883d
  6. 31 Jan, 2002 4 commits
  7. 30 Jan, 2002 4 commits
  8. 29 Jan, 2002 7 commits