From a35981c74df9a52a2dbd50c629a0689aa67b002f Mon Sep 17 00:00:00 2001 From: ligc Date: Mon, 10 May 2010 06:36:43 +0000 Subject: [PATCH] For ipv6, replace inet_* and gethostby* calls with NetworkUtils subroutines git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@6034 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd --- xCAT-server/lib/xcat/plugins/anaconda.pm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/xCAT-server/lib/xcat/plugins/anaconda.pm b/xCAT-server/lib/xcat/plugins/anaconda.pm index 215f4b62c..c45a3909f 100644 --- a/xCAT-server/lib/xcat/plugins/anaconda.pm +++ b/xCAT-server/lib/xcat/plugins/anaconda.pm @@ -11,6 +11,7 @@ use Thread qw(yield); use POSIX qw(WNOHANG nice); use xCAT::Table; use xCAT::Utils; +use xCAT::NetworkUtils; use xCAT::MsgUtils; use xCAT::SvrUtils; #use Data::Dumper; @@ -467,7 +468,7 @@ sub mknetboot # BEGIN service node my $isSV = xCAT::Utils->isServiceNode(); my $res = xCAT::Utils->runcmd("hostname", 0); - my $sip = inet_ntoa(inet_aton($res)); # this is the IP of service node + my $sip = xCAT::NetworkUtils->getipaddr($res); # this is the IP of service node if($isSV and (($xcatmaster eq $sip) or ($xcatmaster eq $res))) { # if the NFS directory in litetree is on the service node, # and it is not exported, then it will be mounted automatically