From c15ba7d10844d6be8c404bf382d79ba9c048951f Mon Sep 17 00:00:00 2001 From: jbjohnso Date: Mon, 25 Feb 2008 23:48:15 +0000 Subject: [PATCH] Fix nodestat for install monitoring git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@572 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd --- xCAT-server-2.0/lib/xcat/plugins/nodestat.pm | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/xCAT-server-2.0/lib/xcat/plugins/nodestat.pm b/xCAT-server-2.0/lib/xcat/plugins/nodestat.pm index 39aefd5b5..667626bd3 100644 --- a/xCAT-server-2.0/lib/xcat/plugins/nodestat.pm +++ b/xCAT-server-2.0/lib/xcat/plugins/nodestat.pm @@ -1,7 +1,7 @@ package xCAT_plugin::nodestat; use Socket; -use Data::Dumper; +use IO::Handle; sub handled_commands { return { @@ -41,14 +41,11 @@ sub installer_query { my $addr = gethostbyname($node); my $sin = sockaddr_in($destport,$addr); connect($socket,$sin) || return 0; - print $socket "stat \r"; - print "stat \r"; - print "here we go\n"; + print $socket "stat \n"; + $socket->flush; while (<$socket>) { - print $_."\n"; $text.=$_; } - print "here we go\n"; return $text; close($socket); } @@ -61,7 +58,6 @@ sub process_request { my $request = shift; my $callback = shift; my @nodes = @{$request->{node}}; - $callback->({data=>Dumper(\@nodes)}); my $node; foreach $node (@nodes) { my %rsp;