Fix yum repo location in rhel, check in a fix for leaking filehandles on Table object management (closing bug 1831291 on sourceforge)

git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@45 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd
This commit is contained in:
jbjohnso 2007-11-13 21:38:32 +00:00
parent af0a807551
commit 65bcb4e19e
2 changed files with 10 additions and 3 deletions

View File

@ -12,6 +12,7 @@ use DBI;
#use strict;
use Data::Dumper;
use Scalar::Util qw/weaken/;
use xCAT::Schema;
use xCAT::NodeRange;
use Text::Balanced qw(extract_bracketed);
@ -246,7 +247,7 @@ sub new
updateschema($self);
if ($self->{tabname} eq 'nodelist')
{
$self->{nodelist} = $self;
weaken($self->{nodelist} = $self);
}
else
{
@ -1407,6 +1408,12 @@ sub close
{
my $self = shift;
if ($self->{dbh}) { $self->{dbh}->disconnect(); }
undef $self->{dbh};
if ($self->{tabname} eq 'nodelist') {
undef $self->{nodelist};
} else {
$self->{nodelist}->close();
}
}
#--------------------------------------------------------------------------

View File

@ -117,9 +117,9 @@ sub makenetboot {
$callback->({error=>["No installdir defined in site table"],errorcode=>[1]});
return;
}
my $srcdir = "/$installroot/$osver/$arch";
my $srcdir = "/$installroot/$osver/$arch/Server";
unless ( -d $srcdir."/repodata" ) {
$callback->({error=>["copycds has not been run for $osver/$arch"],errorcode=>[1]});
$callback->({error=>["copycds has not been run for $osver/$arch (/$installroot/$osver/$arch/Server/repodata not found"],errorcode=>[1]});
return;
}
my $yumconf;