From 1e09d79d7f25e042f97b8879c8b19e03384b2746 Mon Sep 17 00:00:00 2001 From: yinle Date: Fri, 24 Aug 2012 02:12:53 +0000 Subject: [PATCH] Add some sleep to avoid http failure. Modify some trace information. git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/branches/2.7@13602 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd --- perl-xCAT/xCAT/PPCfsp.pm | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/perl-xCAT/xCAT/PPCfsp.pm b/perl-xCAT/xCAT/PPCfsp.pm index 0342daa71..0a2b8fd85 100644 --- a/perl-xCAT/xCAT/PPCfsp.pm +++ b/perl-xCAT/xCAT/PPCfsp.pm @@ -1787,7 +1787,7 @@ sub get_netcfg # Return error ################################## if ( !defined( $$form )) { - return( [RC_ERROR,"'Network Configuration' form not found"] ); + return( [RC_ERROR,"'Network Configuration' form not found at parse"] ); } ################################## @@ -1807,14 +1807,15 @@ sub get_netcfg $res = $ua->request( $data); $$form = HTML::Form->parse( $res->content, $res->base ); if ( !defined( $$form )) { - return( [RC_ERROR,"'Network Configuration' form not found"] ); + return( [RC_ERROR,"'Network Configuration' form not found at submit"] ); } } elsif ( $$form->find_input('submit', 'submit', 1) ) { my $data = $$form->click('submit'); + sleep 5; $res = $ua->request( $data); $$form = HTML::Form->parse( $res->content, $res->base ); if ( !defined( $$form )) { - return( [RC_ERROR,"'Network Configuration' form not found' form not found"] ); + return( [RC_ERROR,"'Network Configuration' form not found at submit2"] ); } if ( $$form->find_input('ip', 'radio', 1)) { @@ -1830,7 +1831,7 @@ sub get_netcfg $res = $ua->request( $data); $$form = HTML::Form->parse( $res->content, $res->base ); if ( !defined( $$form )) { - return( [RC_ERROR,"'Network Configuration' form not found"] ); + return( [RC_ERROR,"'Network Configuration' form not found at submit3"] ); } } } @@ -1991,6 +1992,7 @@ sub set_netcfg } #Click "Continue" button + sleep 2; my $data = $form->click('save'); my $res = $ua->request( $data); if (!$res->is_success())