Commit 5acdd9ce authored by Leigh Stoller's avatar Leigh Stoller

Checkpoint image provenance/versioning.

parent 5aff2d89
......@@ -1308,36 +1308,49 @@ emulab_get_host_authinfo(struct in_addr *req, struct in_addr *host,
if (imageid != NULL) {
/* Interested in a specific image */
if (can_access(imageidx, ei, 1)) {
res = mydb_query("SELECT pid,gid,imagename,"
" path,imageid"
" FROM images WHERE"
" pid='%s'"
" AND imagename='%s'",
res = mydb_query("SELECT i.pid,i.gid,"
" i.imagename,v.path,i.imageid"
" FROM images as i "
" LEFT JOIN image_versions "
" as v on "
" v.imageid=i.imageid and "
" v.version=i.version "
" WHERE i.pid='%s'"
" AND i.imagename='%s'",
5, wantpid, wantname);
} else {
/*
* Pid of expt must be same as pid of image
* and gid the same or image "shared".
*/
res = mydb_query("SELECT pid,gid,imagename,"
"path,imageid"
" FROM images WHERE"
" pid='%s' AND imagename='%s'"
" AND pid='%s'"
" AND (gid='%s' OR"
" (gid=pid AND shared=1))",
res = mydb_query("SELECT i.pid,i.gid,"
" i.imagename,v.path,i.imageid"
" FROM images as i "
" LEFT JOIN image_versions "
" as v on "
" v.imageid=i.imageid and "
" v.version=i.version "
" WHERE i.pid='%s' "
" AND i.imagename='%s'"
" AND i.pid='%s'"
" AND (i.gid='%s' OR"
" (i.gid=i.pid AND "
" v.shared=1))",
5, wantpid, wantname,
ei->pid, ei->gid);
}
} else {
/* Find all images that this pid/gid can PUT */
res = mydb_query("SELECT pid,gid,imagename,"
"path,imageid"
" FROM images"
" WHERE pid='%s'"
" AND (gid='%s' OR"
" (gid=pid AND shared=1))"
" ORDER BY pid,gid,imagename",
res = mydb_query("SELECT i.pid,i.gid,i.imagename,"
"v.path,i.imageid"
" FROM images as i"
" LEFT JOIN image_versions as v on "
" v.imageid=i.imageid and "
" v.version=i.version "
" WHERE i.pid='%s'"
" AND (i.gid='%s' OR"
" (i.gid=i.pid AND v.shared=1))"
" ORDER BY i.pid,i.gid,i.imagename",
5, ei->pid, ei->gid);
}
assert(res != NULL);
......@@ -1436,34 +1449,48 @@ emulab_get_host_authinfo(struct in_addr *req, struct in_addr *host,
if (imageid != NULL) {
/* Interested in a specific image */
if (can_access(imageidx, ei, 0)) {
res = mydb_query("SELECT pid,gid,imagename,"
"path,imageid"
" FROM images WHERE"
" pid='%s'"
" AND imagename='%s'",
res = mydb_query("SELECT i.pid,i.gid,"
"i.imagename,v.path,i.imageid"
" FROM images as i "
" LEFT JOIN image_versions "
" as v on "
" v.imageid=i.imageid and "
" v.version=i.version "
"WHERE i.pid='%s'"
" AND i.imagename='%s'",
5, wantpid, wantname);
} else {
res = mydb_query("SELECT pid,gid,imagename,"
"path,imageid"
" FROM images WHERE"
" pid='%s' AND imagename='%s'"
" AND (global=1"
" OR (pid='%s'"
" AND (gid='%s'"
" OR shared=1)))"
res = mydb_query("SELECT i.pid,i.gid,"
"i.imagename,v.path,i.imageid"
" FROM images as i"
" LEFT JOIN image_versions "
" as v on "
" v.imageid=i.imageid and "
" v.version=i.version "
" WHERE i.pid='%s' "
" AND i.imagename='%s'"
" AND (v.global=1"
" OR (i.pid='%s'"
" AND (i.gid='%s'"
" OR v.shared=1)))"
" ORDER BY pid,gid,imagename",
5, wantpid, wantname,
ei->pid, ei->gid);
}
} else {
/* Find all images that this pid/gid can GET */
res = mydb_query("SELECT pid,gid,imagename,"
"path,imageid"
" FROM images WHERE"
" (global=1"
" OR (pid='%s'"
" AND (gid='%s' OR shared=1)))"
" ORDER BY pid,gid,imagename",
res = mydb_query("SELECT i.pid,i.gid,i.imagename,"
"v.path,i.imageid"
" FROM images as i"
" LEFT JOIN image_versions "
" as v on "
" v.imageid=i.imageid and "
" v.version=i.version "
" WHERE"
" (v.global=1"
" OR (i.pid='%s'"
" AND (i.gid='%s' OR v.shared=1)))"
" ORDER BY i.pid,i.gid,i.imagename",
5, ei->pid, ei->gid);
}
assert(res != NULL);
......@@ -1610,10 +1637,14 @@ dump_image_aliases(FILE *fd)
char *lastpid;
/* First the global image alias */
res = mydb_query("SELECT pid,imagename"
" FROM images"
" WHERE global=1"
" ORDER BY pid,imagename", 2);
res = mydb_query("SELECT i.pid,i.imagename"
" FROM images as i"
" LEFT JOIN image_versions "
" as v on "
" v.imageid=i.imageid and "
" v.version=i.version "
" WHERE v.global=1"
" ORDER BY i.pid,i.imagename", 2);
assert(res != NULL);
nrows = mysql_num_rows(res);
......@@ -1662,10 +1693,14 @@ dump_image_aliases(FILE *fd)
free(lastpid);
lastpid = mystrdup(row[0]);
res2 = mydb_query("SELECT imagename"
" FROM images"
" WHERE pid='%s' AND shared=1"
" ORDER BY imagename",
res2 = mydb_query("SELECT i.imagename"
" FROM images as i"
" LEFT JOIN image_versions "
" as v on "
" v.imageid=i.imageid and "
" v.version=i.version "
" WHERE i.pid='%s' AND v.shared=1"
" ORDER BY i.imagename",
1, lastpid);
assert(res2 != NULL);
......
......@@ -659,6 +659,7 @@ TBOPSEMAIL
IPV6_SUBNET_PREFIX
IPV6_ENABLED
NFSMAPTOUSER
IMAGEPROVENANCE
BROWSER_CONSOLE_ENABLE
EC2META_ENABLE
NOSITECHECKIN
......@@ -5091,6 +5092,7 @@ MANAGEMENT_NETWORK="10.249.249.0"
MANAGEMENT_NETMASK="255.255.255.0"
MANAGEMENT_ROUTER="10.249.249.253"
NFSMAPTOUSER="root"
IMAGEPROVENANCE=0
#
# XXX You really don't want to change these!
......
......@@ -291,6 +291,7 @@ AC_SUBST(BROWSER_CONSOLE_ENABLE)
AC_SUBST(IPV6_ENABLED)
AC_SUBST(IPV6_SUBNET_PREFIX)
AC_SUBST(NFSMAPTOUSER)
AC_SUBST(IMAGEPROVENANCE)
#
# Offer both versions of the email addresses that have the @ escaped
......@@ -433,6 +434,7 @@ MANAGEMENT_NETWORK="10.249.249.0"
MANAGEMENT_NETMASK="255.255.255.0"
MANAGEMENT_ROUTER="10.249.249.253"
NFSMAPTOUSER="root"
IMAGEPROVENANCE=0
#
# XXX You really don't want to change these!
......
......@@ -193,10 +193,13 @@ $EXPT_RESOURCESHOSED = 0;
# These are slots in the node table that need to be restored.
@nodetable_fields = ("def_boot_osid",
"def_boot_osid_vers",
"def_boot_path",
"def_boot_cmd_line",
"temp_boot_osid",
"temp_boot_osid_vers",
"next_boot_osid",
"next_boot_osid_vers",
"next_boot_path",
"next_boot_cmd_line",
"pxe_boot_path",
......@@ -4506,12 +4509,14 @@ sub LinkTestCapable($$)
my $idx = $self->idx();
my $query_result =
DBQueryWarn("select v.vname, FIND_IN_SET('linktest',osfeatures) ".
DBQueryWarn("select v.vname, FIND_IN_SET('linktest',ov.osfeatures) ".
" from virt_nodes as v ".
"left join reserved as r on r.pid=v.pid and ".
" r.eid=v.eid and r.vname=v.vname ".
"left join nodes as n on n.node_id=r.node_id ".
"left join os_info as o on o.osid=n.def_boot_osid ".
"left join os_info_versions as ov on ".
" ov.osid=n.def_boot_osid and ".
" ov.vers=n.def_boot_osid_vers ".
"where v.exptidx='$idx' and v.role!='bridge'");
return -1
if (!defined($query_result));
......
This diff is collapsed.
......@@ -360,7 +360,7 @@ sub Create($$$$)
{
my ($class, $node_id, $experiment, $argref) = @_;
my ($control_iface,$virtnode_capacity,$adminmfs,$adminmfs_osid);
my ($priority, $osid, $opmode, $state);
my ($priority, $osid, $osid_vers, $opmode, $state);
require OSinfo;
require NodeType;
......@@ -392,6 +392,7 @@ sub Create($$$$)
if (!defined($typeinfo));
my $isremote = $typeinfo->isremotenode();
$osid_vers = 0;
if ($role eq "testnode") {
if ($typeinfo->virtnode_capacity(\$virtnode_capacity)) {
......@@ -416,6 +417,7 @@ sub Create($$$$)
return undef;
}
$osid = $osinfo->osid();
$osid_vers = $adminmfs->vers();
$opmode = $osinfo->op_mode();
}
}
......@@ -437,6 +439,7 @@ sub Create($$$$)
return undef;
}
$osid = $adminmfs->osid();
$osid_vers = $adminmfs->vers();
$opmode = $adminmfs->op_mode();
}
}
......@@ -486,7 +489,7 @@ sub Create($$$$)
" phys_nodeid='$node_id', role='$role', ".
" priority=$priority, " .
" eventstate='$state', op_mode='$opmode', " .
" def_boot_osid=$osid, " .
" def_boot_osid=$osid, def_boot_osid_vers='$osid_vers'" .
" inception=now(), uuid=$uuid, ".
" state_timestamp=unix_timestamp(NOW()), " .
" op_mode_timestamp=unix_timestamp(NOW())")) {
......@@ -1687,6 +1690,7 @@ sub ClearBootAttributes($)
"tarballs='',failureaction='fatal', routertype='none', ".
"def_boot_cmd_line='',next_boot_cmd_line='', ".
"temp_boot_osid=NULL,next_boot_osid=NULL, ".
"temp_boot_osid_vers=0,next_boot_osid_vers=0, ".
"update_accounts=0,ipport_next=ipport_low,rtabid=0, ".
"sfshostid=NULL,allocstate='$allocFreeState',boot_errno=0, ".
"destination_x=NULL,destination_y=NULL, ".
......@@ -2171,17 +2175,13 @@ sub CreateVnodes($$$)
# table.
#
my $osid = $nodetype->default_osid();
my $query_result =
DBQueryWarn("select op_mode from os_info where osid='$osid'");
return -1
if (! $query_result);
if (! $query_result->numrows) {
my $osinfo = OSinfo->Lookup($osid);
if (!defined($osinfo)) {
print STDERR "*** CreateVnodes: No such OSID '$osid'\n";
return -1;
}
my ($opmode) = $query_result->fetchrow_array();
my ($opmode) = $osinfo->op_mode();
my $osid_vers = $osinfo->vers();
#
# Need IP for jailed nodes.
......@@ -2426,6 +2426,7 @@ sub CreateVnodes($$$)
"eventstate" => $eventstate,
"allocstate" => $allocstate,
"def_boot_osid" => $osid,
"def_boot_osid_vers" => $osid_vers,
"update_accounts" => 1,
"jailflag" => $isjailed);
......@@ -2759,6 +2760,8 @@ sub SetNodeHistory($$$$)
# Set the scheduled_reloads for a node. Type is optional and defaults to
# testbed default load type. See above.
#
# No image version info; we always reload the most current image.
#
sub SetSchedReload($$;$)
{
my ($self, $imageid, $type) = @_;
......@@ -3136,13 +3139,18 @@ sub OSSelect($$$$)
if (!defined($field)) {
# Clear all osids.
DBQueryWarn("update nodes set ".
"def_boot_osid=NULL,next_boot_osid=NULL,temp_boot_osid=NULL ".
"def_boot_osid=NULL,next_boot_osid=NULL,".
"temp_boot_osid=NULL, ".
"def_boot_osid_vers=0,next_boot_osid_vers=0,".
"temp_boot_osid_vers=0 ".
"where node_id='$nodeid'")
or return -1;
} else {
# Set/Clear the osid.
DBQueryWarn("update nodes set ${field}=".
(defined($osinfo) ? "'" . $osinfo->osid() . "' " : "NULL ") .
my $osid = (defined($osinfo) ? "'" . $osinfo->osid() . "'" : "NULL");
my $vers = (defined($osinfo) ? "'" . $osinfo->vers() . "'" : "'0'");
DBQueryWarn("update nodes set ${field}=$osid,${field}_vers=$vers ".
"where node_id='$nodeid'")
or return -1;
......@@ -3353,13 +3361,19 @@ sub ClearOsids($) {
DBQueryWarn("update nodes set ".
" def_boot_osid=NULL,".
" next_boot_osid=NULL,".
" temp_boot_osid=NULL ".
" temp_boot_osid=NULL, ".
" def_boot_osid_vers=0,".
" next_boot_osid_vers=0,".
" temp_boot_osid_vers=0 ".
"where node_id='$node_id'")
or return -1;
$self->{"DBROW"}{"def_boot_osid"} = undef;
$self->{"DBROW"}{"temp_boot_osid"} = undef;
$self->{"DBROW"}{"next_boot_osid"} = undef;
$self->{"DBROW"}{"def_boot_osid_vers"} = 0;
$self->{"DBROW"}{"temp_boot_osid_vers"} = 0;
$self->{"DBROW"}{"next_boot_osid_vers"} = 0;
return 0;
}
......@@ -3401,11 +3415,13 @@ sub IsOSLoaded($$)
$osinfo = $tmp;
}
my $osid = $osinfo->osid();
my $vers = $osinfo->vers();
my $nodeid = $self->node_id();
my $query_result =
DBQueryWarn("select osid from partitions as p ".
"where p.node_id='$nodeid' and p.osid='$osid'");
"where p.node_id='$nodeid' and p.osid='$osid' and ".
" p.osid_vers='$vers'");
return -1
if (!$query_result);
......@@ -3683,9 +3699,10 @@ sub RunningOsImage($)
my ($self) = @_;
my $nodeid = $self->node_id();
my $osid = $self->def_boot_osid();
my $imageid;
my $vers = $self->def_boot_osid_vers();
my $image;
my $osinfo = OSinfo->Lookup($osid);
my $osinfo = OSinfo->Lookup($osid, $vers);
return ()
if (!defined($osinfo));
......@@ -3693,19 +3710,19 @@ sub RunningOsImage($)
# No partition entries for virtnodes, they are plain EZ images.
#
if ($self->isvirtnode()) {
$imageid = $osid;
# XXX No version info, need that.
$image = Image->Lookup($osid, $vers);
}
else {
my $query_result =
DBQueryWarn("select imageid from partitions as p ".
DBQueryWarn("select imageid,imageid_version from partitions as p ".
"where p.node_id='$nodeid' and p.osid='$osid'");
return ()
if (!$query_result || !$query_result->numrows);
($imageid) = $query_result->fetchrow_array();
my ($imageid,$version) = $query_result->fetchrow_array();
$image = Image->Lookup($imageid, $version);
}
# This might not exist for a virtnode; caller has to deal with it.
my $image = Image->Lookup($imageid);
return ($osinfo, $image);
}
......@@ -3836,14 +3853,14 @@ sub SyncTaintStates($)
my $node_id = $self->node_id();
my $query_result =
DBQueryWarn("select osid from partitions ".
DBQueryWarn("select osid,osid_vers from partitions ".
"where node_id='$node_id' and osid is not null");
return -1
if (!$query_result);
my @taint_states = ();
while (my ($osid) = $query_result->fetchrow_array()) {
my $osinfo = OSinfo->Lookup($osid);
while (my ($osid, $vers) = $query_result->fetchrow_array()) {
my $osinfo = OSinfo->Lookup($osid, $vers);
if (defined($osinfo) && $osinfo->IsTainted()) {
push @taint_states, $osinfo->GetTaintStates();
}
......
This diff is collapsed.
#!/usr/bin/perl -w
#
# Copyright (c) 2000-2012 University of Utah and the Flux Group.
# Copyright (c) 2000-2014 University of Utah and the Flux Group.
#
# {{{EMULAB-LICENSE
#
......@@ -464,13 +464,19 @@ sub TBBootWhat($;$)
# ALWAYS find exactly the same resulting OSID given the same inputs.
#
my $query_result =
DBQueryWarn("select def_boot_osid, odef.op_mode, ".
" temp_boot_osid, otemp.op_mode, ".
" next_boot_osid, onext.op_mode ".
DBQueryWarn("select def_boot_osid, vdef.op_mode, ".
" temp_boot_osid, vtemp.op_mode, ".
" next_boot_osid, vnext.op_mode ".
"from nodes as n ".
"left join os_info as odef on odef.osid=def_boot_osid ".
"left join os_info_versions as vdef on ".
" vdef.osid=odef.osid and vdef.vers=odef.version ".
"left join os_info as otemp on otemp.osid=temp_boot_osid ".
"left join os_info_versions as vtemp on ".
" vtemp.osid=otemp.osid and vtemp.vers=otemp.version ".
"left join os_info as onext on onext.osid=next_boot_osid ".
"left join os_info_versions as vnext on ".
" vnext.osid=onext.osid and vnext.vers=onext.version ".
"where node_id='$node'");
if (!$query_result || !$query_result->numrows) {
......@@ -583,28 +589,6 @@ sub DefaultImageID ($$) {
return 1;
}
#
# Convert user pid/name to internal imageid.
#
# usage: TBImageID(char *pid, char *imagename)
# returns imageid if its valid.
# returns 0 if not valid.
#
sub TBImageID ($$) {
my($pid, $imagename) = @_;
my $query_result =
DBQueryFatal("select imageid from images ".
"where pid='$pid' and imagename='$imagename'");
if (! $query_result->num_rows) {
return 0;
}
my @row = $query_result->fetchrow_array();
return $row[0];
}
#
# Convert user pid/name to internal osid.
#
......@@ -770,8 +754,12 @@ sub TBImageLoadMaxOkay($$;@)
my($imageid,$node_count,@nodes) = @_;
my $query_result = DBQueryFatal("select part1_osid, part2_osid, " .
"part3_osid, part4_osid from images where imageid='$imageid'");
my $query_result =
DBQueryFatal("select v.part1_osid, v.part2_osid, " .
" v.part3_osid, v.part4_osid from images as i ".
"left join image_versions as v on ".
" v.imageid=i.imageid and v.version=i.version ".
"where i.imageid='$imageid'");
if ($query_result->num_rows() != 1) {
#
......@@ -2408,17 +2396,17 @@ sub MapNumericUID($)
sub MapNodeOSID($$)
{
my ($node, $osid) = @_;
require OSinfo;
#
# See if this OSID is actually loaded on the machine.
#
my $p_result =
DBQueryWarn("select * from partitions ".
DBQueryWarn("select osid_vers from partitions ".
"where node_id='$node' and osid='$osid'");
if (!$p_result) {
return 0;
}
if ($p_result->numrows) {
return $osid;
}
......@@ -2426,39 +2414,35 @@ sub MapNodeOSID($$)
#
# Get OSID info.
#
my $osid_result =
DBQueryWarn("select * from os_info where osid='$osid'");
if (!$osid_result || $osid_result->numrows == 0) {
return 0;
}
my %osid_row = $osid_result->fetchhash();
my ($vers) = $p_result->fetchrow_array();
my $osinfo = OSinfo->Lookup($osid, $vers);
return 0
if (!defined($osinfo));
#
# If its a specific Version, and its not loaded on the machine,
# nothing to do.
#
if (defined($osid_row{'version'}) && $osid_row{'version'} ne "") {
return 0;
}
return 0
if (defined($osinfo->version()) && $osinfo->version() ne "");
#
# Try to map from a generic name to the specific name of the OS
# that *is* loaded.
#
my $o_result =
DBQueryWarn("select o1.* from partitions as p ".
"left join os_info as o1 on o1.osid=p.osid ".
"left join os_info as o2 on o2.OS=o1.OS ".
"where p.node_id='$node' and o2.osid='$osid'");
DBQueryWarn("select ov1.osid from partitions as p ".
"left join os_info_versions as ov1 on ".
" ov1.osid=p.osid and ov1.vers=p.osid_vers and ".
" ov1.deleted is null ".
"left join os_info_versions as ov2 on ".
" ov2.OS=ov1.OS and ov2.deleted is null ".
"where p.node_id='$node' and ov2.osid='$osid'");
if (!$o_result || $o_result->numrows == 0) {
return 0;
}
my %o_row = $o_result->fetchhash();
my $n_osid = $o_row{'osid'};
my ($n_osid) = $o_result->fetchrow_array();
return $n_osid;
}
......
......@@ -413,6 +413,7 @@ foreach my $node (@freed_nodes) {
my $isgeni = $node->isfednode();
my $isdynamic = $node->isdynamic();
my $def_boot_osid = $node->def_boot_osid();
my $def_boot_vers = $node->def_boot_osid_vers();
my $imageable = $node->imageable();
# Clean out all delays
......@@ -431,7 +432,7 @@ foreach my $node (@freed_nodes) {
# OSinfo lookup could fail if the OSID was removed at a bad time,
# so treat a failure as non-fatal and force a clean.
#
my $osinfo = OSinfo->Lookup($def_boot_osid);
my $osinfo = OSinfo->Lookup($def_boot_osid, $def_boot_vers);
if (defined($osinfo)) {
$clean = $osinfo->mustclean();
} else {
......
#!/usr/bin/perl -w
#
# Copyright (c) 2000-2013 University of Utah and the Flux Group.
# Copyright (c) 2000-2014 University of Utah and the Flux Group.
#
# {{{EMULAB-LICENSE
#
......@@ -58,6 +58,7 @@ $| = 1;
use event;
use libdb;
use Node;
use OSinfo;
use libtestbed;
use TimeoutQueue;
use Getopt::Std;
......@@ -1016,7 +1017,9 @@ sub stateTransition($$) {
};
/^RELOADOLDMFS$/ && do {
my $frisbee_osid = TBNodeDiskloadOSID($node);
my $frisbee_name = DBQuerySingleFatal("select osname from os_info where osid=$frisbee_osid");
my $osinfo = OSinfo->Lookup($frisbee_osid);
my $frisbee_name = (defined($osinfo) ?
$osinfo->osame() : $frisbee_osid);
my $msg =
("Attempted to load multiple images on $node using an old Frisbee MFS.\n".
"To make this work please update the $frisbee_name MFS image.\n");
......@@ -1417,10 +1420,12 @@ sub handleCommand($$;$$) {
sub checkGenISUP($) {
my ($node) = @_;
debug("$node: Checking ISUP Generation\n");
my $r = DBQueryWarn("select FIND_IN_SET('isup',osfeatures) as isup,".
" FIND_IN_SET('ping',osfeatures) as ping ".
my $r = DBQueryWarn("select FIND_IN_SET('isup',v.osfeatures) as isup,".
" FIND_IN_SET('ping',v.osfeatures) as ping ".
"from nodes as n ".
"left join os_info as o on o.osid=n.osid ".
"left join os_info_versions as v on ".
" v.osid=o.osid and v.vers=o.version ".
"where node_id='$node' and osfeatures is not null");
if ($r->num_rows() > 0) {
my ($isup,$ping) = $r->fetchrow();
......@@ -1711,25 +1716,6 @@ sub ClearNodeTrigger( $$$ ; @ ) {
return 0;
}
sub os_opmode() {
my $osid = shift || "";
if ($osid eq $TB_OSID_MBKERNEL) {
return "MINIMAL";
}
my $cmd = "select op_mode from os_info where osid='$osid';";
my $q = DBQueryFatal($cmd);
if ($q->numrows() < 1) {
return "";
}
my @r = $q->fetchrow_array();
my $opmode=$r[0];
debug("OpMode for '$osid' is '$opmode'\n");
if (defined($opmode) && $opmode ne "") {
return $opmode;
}
return "";
}
#
# Functions for controlling output/logging, and signal handling
#
......
This directory contains scripts/directions included in the "generic image"
tarball. It does not currently contain any instructions for Emulab-types
on how to create the actual images or the tarball. Talk to Mike about that.
META-README This file, not included in the tarball
README Directions for using the tarball
setup-images.sql SQL snippets for populating the DB with the images.
setup-mfsosids.sql
setup-o2i.sql
setup-osids.sql
This diff is collapsed.
-- MySQL dump 8.23
--
-- Host: localhost Database: tbdb
---------------------------------------------------------
-- Server version 3.23.58-log
--
-- Table structure for table `images`
--
DROP TABLE IF EXISTS `images`;
CREATE TABLE `images` (
`imagename` varchar(30) NOT NULL default '',
`pid_idx` mediumint(8) unsigned NOT NULL default '0',
`gid_idx` mediumint(8) unsigned NOT NULL default '0',
`pid` varchar(12) NOT NULL default '',
`gid` varchar(12) NOT NULL default '',
`imageid` varchar(45) NOT NULL default '',
`creator` varchar(8) default NULL,
`creator_idx` mediumint(8) unsigned NOT NULL default '0',
`created` datetime default NULL,
`description` tinytext NOT NULL,
`loadpart` tinyint(4) NOT NULL default '0',
`loadlength` tinyint(4) NOT NULL default '0',
`part1_osid` varchar(35) default NULL,
`part2_osid` varchar(35) default NULL,
`part3_osid` varchar(35) default NULL,
`part4_osid` varchar(35) default NULL,
`default_osid` varchar(35) NOT NULL default '',
`path` tinytext,
`magic` tinytext,
`load_address` text,
`frisbee_pid` int(11) default '0',
`load_busy` tinyint(4) NOT NULL default '0',
`ezid` tinyint(4) NOT NULL default '0',
`shared` tinyint(4) NOT NULL default '0',
`global` tinyint(4) NOT NULL default '0',
`updated` datetime default NULL,
PRIMARY KEY (`imageid`),
UNIQUE KEY `pid` (`pid`,`imagename`),
KEY `gid` (`gid`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
--
-- Dumping data for table `images`
--
-- WHERE: imagename like '%-STD%'
INSERT INTO images VALUES ('FBSD410+RHL90-STD',1,1,'emulab-ops','emulab-ops','emulab-ops-FBSD410+RHL90-STD','hibler','2004-11-09 00:00:00','Latest full disk image with FreeBSD 4.10 and RedHat 9.0',0,4,'emulab-ops-FBSD410-STD','emulab-ops-RHL90-STD',NULL,NULL,'emulab-ops-FBSD410-STD','/usr/testbed/images/FBSD410+RHL90-STD.ndz',NULL,'',0,1,0,0,1,NULL);
INSERT INTO images VALUES ('FBSD410-STD',1,1,'emulab-ops','emulab-ops','emulab-ops-FBSD410-STD','hibler','2004-11-09 00:00:00','Testbed version of FreeBSD 4.10',1,1,'emulab-ops-FBSD410-STD',NULL,NULL,NULL,'emulab-ops-FBSD410-STD','/usr/testbed/images/FBSD410-STD.ndz',NULL,'',