From ad45f701f862e4e825cc7802b53f8dcb04730eb8 Mon Sep 17 00:00:00 2001 From: wanghuaz Date: Tue, 5 Jan 2010 04:27:31 +0000 Subject: [PATCH] look up hosts table before name resolution in rspconfig command git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@4887 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd --- perl-xCAT/xCAT/PPCfsp.pm | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/perl-xCAT/xCAT/PPCfsp.pm b/perl-xCAT/xCAT/PPCfsp.pm index 5161e107d..447bd33e5 100644 --- a/perl-xCAT/xCAT/PPCfsp.pm +++ b/perl-xCAT/xCAT/PPCfsp.pm @@ -130,6 +130,13 @@ sub connect { ################################## # Set options ################################## + my $hosttab = xCAT::Table->new( 'hosts' ); + if ( $hosttab) { + my $hostshash = $hosttab->getNodeAttribs( $server, [qw(ip)]); + if ( $hostshash ) { + $server = $hostshash->{ip}; + } + } # my $serverip = inet_ntoa(inet_aton($server)); my $url = "https://$server/cgi-bin/cgi?form=2"; $ua->cookie_jar( $cookie );