From: <st...@us...> - 2010-09-09 11:54:23
|
Revision: 398 http://ggnfs.svn.sourceforge.net/ggnfs/?rev=398&view=rev Author: sten_ Date: 2010-09-09 11:54:17 +0000 (Thu, 09 Sep 2010) Log Message: ----------- * $lasieve variable now holds siever executable file name (to easily change gnfs-lasieve4Ie14 to gnfs-lasieve4Ie16 e.t.c.). * BUG: .lastjob is not properly saved when handling TODO lists (thanks to Solo and Dmit for bug report and for the fix). * By default use gnfs-lasieve4Ie16 siever. Modified Paths: -------------- trunk/contrib/scripts/nfs_agent.pl Modified: trunk/contrib/scripts/nfs_agent.pl =================================================================== --- trunk/contrib/scripts/nfs_agent.pl 2010-07-25 08:56:44 UTC (rev 397) +++ trunk/contrib/scripts/nfs_agent.pl 2010-09-09 11:54:17 UTC (rev 398) @@ -24,9 +24,9 @@ # # How to use: # -# 1) Change $nick script parameter and optionally set $output_dir to some shared folder (*.spairs output files will be moved there). +# 1) Change $nick script parameter and optionally set $output_dir to some shared folder (*.spairs output files will be moved there). # 2) Place these files into the same directory: -# - gnfs-lasieve4I14e.exe +# - gnfs-lasieve4I16e.exe (file name can be changed via $lasieve variable). # - nfs_agent.pl # 3) Run the script. # 4) Ensure it works and forget it for several weeks. :) @@ -45,6 +45,7 @@ $script = 'sieve/getblock.php'; # ex. '2p643m3/getblock.php'; $task = 'TaskName.1'; # Task name $blocksize = 'small'; +$lasieve = 'gnfs-lasieve4I16e'; # siever file name. $output_dir = undef; # ex. for Windows: "\\\\myserver\\spairs"; Output files will be automatically moved to \\myserver\spairs. # -------------------------- @@ -82,6 +83,7 @@ ExecJob($jobFileName); } + while (1) { # @@ -216,13 +218,6 @@ print JOBFILE $response; close (JOBFILE); - # - # Save .lastjob file - # - open(LASTJOBFILE, ">.lastjob") || return 0; - print LASTJOBFILE "$jobFileName"; - close (LASTJOBFILE); - return "$jobFileName"; } @@ -236,6 +231,13 @@ open(JOBFILE, $jobFileName) || die "Can't open job file ($jobFileName).\n"; + # + # Save .lastjob file + # + open(LASTJOBFILE, ">.lastjob") || return 0; + print LASTJOBFILE "$jobFileName"; + close (LASTJOBFILE); + @JobData = <JOBFILE>; close (JOBFILE); @@ -259,8 +261,8 @@ $spqFileName = ".last_spq1234"; unlink "$workFileName", "$spqFileName"; - system ("gnfs-lasieve4I14e -k -o $workFileName -v -a $jobFileName -n1234") == 0 - || die "Error: Unable to execute gnfs-lasieve4I14e.\n"; + system ("$lasieve -k -o $workFileName -v -a $jobFileName -n1234") == 0 + || die "Error: Unable to execute $lasieve.\n"; rename ($workFileName, $spairsFileName); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |