parallel: Implemented $PARALLEL_SEQ and $PARALLEL_PID.

-v now only show the command to be run. Use -vv to see the surrounding ssh wrapping.
--workdir implemented. Spelling mistakes.
This commit is contained in:
Ole Tange 2010-10-27 01:50:58 +02:00
parent 87747a44b4
commit f085a37a40
22 changed files with 811 additions and 363 deletions

View file

@ -1,7 +1,27 @@
== Bug == parallel: Implemented $PARALLEL_SEQ and $PARALLEL_PID.
-v now only show the command to be run. Use -vv to see the surrounding ssh wrapping.
--workdir implemented. Spelling mistakes.
== Compare ==
http://code.google.com/p/spawntool/
http://code.google.com/p/push/
== Bug? ==
.parallel/config with --long-options
time find . -type f | parallel -j+0 --eta -S..,: --progress --trc {}.gz gzip {}
== Bug --eta ==
Only negative.
== Workdir ==
Bug: {2} in --return
parallel -N2 --workdir ... --cleanup --transfer --return {2}.2 -S .. -v echo {} ">{2}.2" ::: ./tmp/foo ./tmp/bar
(echo ; echo abc ; echo abc; echo ; echo bbc) | parallel --colsep b -v echo {1}{2}
(echo ; echo abc ; echo abc; echo ; echo bbc) | parallel --colsep d -v echo {1}{2}
== SQL == == SQL ==

View file

@ -117,7 +117,9 @@ cc:Peter Simons <simons@cryp.to>, Sandro Cazzaniga <kharec@mandriva.org>,
Markus Ammer <mkmm@gmx-topmail.de>, Pavel Nuzhdin <pnzhdin@gmail.com>, Markus Ammer <mkmm@gmx-topmail.de>, Pavel Nuzhdin <pnzhdin@gmail.com>,
Phil Sung <psung@alum.mit.edu>, Michael Shigorin <mike@altlinux.org>, Phil Sung <psung@alum.mit.edu>, Michael Shigorin <mike@altlinux.org>,
Andrew McFague <amcfague@wgen.net>, Steven M. Christensen <sunfreeware@gmail.com>, Andrew McFague <amcfague@wgen.net>, Steven M. Christensen <sunfreeware@gmail.com>,
Chris Howey <howeyc@gmail.com> Chris Howey <howeyc@gmail.com>, Fethican Coşkuner <fethicanc@gmail.com>,
Rogério Brito <rbrito@ime.usp.br>, Jonathan Palardy <jonathan.palardy@gmail.com>,
Koen Vervloesem <koen@vervloesem.eu>,
Subject: GNU Parallel 2010XXXX released Subject: GNU Parallel 2010XXXX released
@ -126,11 +128,46 @@ download at: http://ftp.gnu.org/gnu/parallel/
New in this release: New in this release:
* Using -j myfile the number of jobs can be changed while GNU Parallel
is running simply by changing the content of myfile.
* Slow spawning error is now only a warning.
* If stdin is a tty and input is read from stdin you now get a
warning.
* GNU sql: \n and \x0a in arguments is replaced with newline.
* Patch for Debian package and spelling mistakes. Thanks to Rogério
Brito <rbrito at ime dot usp dot br>
* Mac OS X Homebrew package. Thanks to Jonathan Palardy <jonathan dot
palardy at gmail dot com>
* FreeBSD port. Thanks to Chris Howey <howeyc at gmail dot com> * FreeBSD port. Thanks to Chris Howey <howeyc at gmail dot com>
* First review on print: * Pardus package. Thanks to Fethican Coşkuner
<fethicanc at gmail dot com>
* First review in Chinese. Thanks to 曾義峰:
http://antbsd.twbbs.org/~ant/wordpress/?p=2876
* First review in print:
http://www.linux-magazine.com/Issues/2010 Nov 2010 http://www.linux-magazine.com/Issues/2010 Nov 2010
* First review in Spanish:
http://www.muylinux.com/2010/10/18/gnu-parallel-computacion-paralela-a-golpe-de-comando
* First review in Dutch thanks to Koen Vervloesem <koen at vervloesem
dot eu>:
http://techworld.nl/technologie/33493/gebruik-al-je-processorkernen-met-gnu-parallel.html
* 3500 views of the intro video:
http://www.youtube.com/watch?v=OpaiGYxkSuQ
* As usual a bunch of bugfixes and more usage examples in the man
page.
Old in this release: Old in this release:
* See GNU Parallel live at FSCONS 2010-11-07: * See GNU Parallel live at FSCONS 2010-11-07:

View file

@ -18,7 +18,7 @@ B<#!/usr/bin/parallel> --shebang [options] [I<command> [arguments]]
=head1 DESCRIPTION =head1 DESCRIPTION
GNU B<parallel> is a shell tool for executing jobs in parallel locally GNU B<parallel> is a shell tool for executing jobs concurrently locally
or using remote computers. A job is typically a single command or a or using remote computers. A job is typically a single command or a
small script that has to be run for each of the lines in the small script that has to be run for each of the lines in the
input. The typical input is a list of files, a list of hosts, a list input. The typical input is a list of files, a list of hosts, a list
@ -28,7 +28,7 @@ If you use B<xargs> today you will find GNU B<parallel> very easy to
use as GNU B<parallel> is written to have the same options as use as GNU B<parallel> is written to have the same options as
B<xargs>. If you write loops in shell, you will find GNU B<parallel> B<xargs>. If you write loops in shell, you will find GNU B<parallel>
may be able to replace most of the loops and make them run faster by may be able to replace most of the loops and make them run faster by
running several jobs in parallel. If you use B<ppss> or B<pexec> you running several jobs simultaneously. If you use B<ppss> or B<pexec> you
will find GNU B<parallel> will often make the command easier to read. will find GNU B<parallel> will often make the command easier to read.
GNU B<parallel> makes sure output from the commands is the same output GNU B<parallel> makes sure output from the commands is the same output
@ -383,7 +383,7 @@ If B<--semaphore> is set default is 1 thus making a mutex.
Add N to the number of CPU cores. Run this many jobs in parallel. For Add N to the number of CPU cores. Run this many jobs in parallel. For
compute intensive jobs B<-j> +0 is useful as it will run compute intensive jobs B<-j> +0 is useful as it will run
number-of-cpu-cores jobs in parallel. See also number-of-cpu-cores jobs simultaneously. See also
B<--use-cpus-instead-of-cores>. B<--use-cpus-instead-of-cores>.
@ -831,7 +831,7 @@ Use the replacement string I<replace-str> instead of {.} for input line without
=item B<--use-cpus-instead-of-cores> =item B<--use-cpus-instead-of-cores>
Count the number of physical CPUs instead of CPU cores. When computing Count the number of physical CPUs instead of CPU cores. When computing
how many jobs to run in parallel relative to the number of CPU cores how many jobs to run simultaneously relative to the number of CPU cores
you can ask GNU B<parallel> to instead look at the number of physical you can ask GNU B<parallel> to instead look at the number of physical
CPUs. This will make sense for computers that have hyperthreading as CPUs. This will make sense for computers that have hyperthreading as
two jobs running on one CPU with hyperthreading will run slower than two jobs running on one CPU with hyperthreading will run slower than
@ -852,14 +852,15 @@ B<--silent>. See also B<-t>.
Print the version GNU B<parallel> and exit. Print the version GNU B<parallel> and exit.
=item B<--workdir> I<dir> (unimplemented)
=item B<-W> I<dir> (unimplemented) =item B<--workdir> I<mydir> (beta testing)
=item B<-W> I<mydir> (beta testing)
Files transferred using B<--transfer> and B<--return> will be relative Files transferred using B<--transfer> and B<--return> will be relative
to workdir on remote machines, and the command will be executed in to I<mydir> on remote machines, and the command will be executed in
that dir. The special workdir B<...> will create a workdir i that dir. The special workdir B<...> will create a workdir in
B<~/.parallel/workdirs/> on the remote machines and will be removed if B<~/.parallel/tmp/> on the remote machines and will be removed if
using B<--cleanup>. using B<--cleanup>.
@ -1130,7 +1131,7 @@ B<cat list | parallel "do_something {} scale {.}.jpg ; do_step2 <{} {.}" | proce
=head1 EXAMPLE: Group output lines =head1 EXAMPLE: Group output lines
When runnning jobs that output data, you often do not want the output When running jobs that output data, you often do not want the output
of multiple jobs to run together. GNU B<parallel> defaults to grouping the of multiple jobs to run together. GNU B<parallel> defaults to grouping the
output of each job, so the output is printed when the job finishes. If output of each job, so the output is printed when the job finishes. If
you want the output to be printed while the job is running you can use you want the output to be printed while the job is running you can use
@ -1346,12 +1347,12 @@ Note: The default for GNU B<parallel> is to remove the spaces around the columns
B<parallel -a table_file.tsv --trim n --colsep '\t' cmd -o {2} -i {1}> B<parallel -a table_file.tsv --trim n --colsep '\t' cmd -o {2} -i {1}>
=head1 EXAMPLE: Working as cat | sh. Ressource inexpensive jobs and evaluation =head1 EXAMPLE: Working as cat | sh. Resource inexpensive jobs and evaluation
GNU B<parallel> can work similar to B<cat | sh>. GNU B<parallel> can work similar to B<cat | sh>.
A ressource inexpensive job is a job that takes very little CPU, disk A resource inexpensive job is a job that takes very little CPU, disk
I/O and network I/O. Ping is an example of a ressource inexpensive I/O and network I/O. Ping is an example of a resource inexpensive
job. wget is too - if the webpages are small. job. wget is too - if the webpages are small.
The content of the file jobs_to_run: The content of the file jobs_to_run:
@ -1382,7 +1383,7 @@ background, GNU B<sem> will wait for one of these to complete before
starting another command. B<sem --wait> will wait for all jobs to starting another command. B<sem --wait> will wait for all jobs to
complete. complete.
Run 10 jobs in parallel in the background: Run 10 jobs concurrently in the background:
for i in `ls *.log` ; do for i in `ls *.log` ; do
echo $i echo $i
@ -1531,17 +1532,31 @@ the currently running jobs are finished before exiting.
=over 9 =over 9
=item $PARALLEL_PID - unimplemented =item $PARALLEL_PID
The environment variable $PARALLEL_PID is set by GNU B<parallel> and The environment variable $PARALLEL_PID is set by GNU B<parallel> and
is visible to the jobs started from GNU B<parallel>. This makes it is visible to the jobs started from GNU B<parallel>. This makes it
possible for the jobs to communicate directly to GNU B<parallel>. possible for the jobs to communicate directly to GNU B<parallel>.
Remember to quote the $, so it gets evaluated by the correct
shell.
B<Example:> If each of the jobs tests a solution and one of jobs finds B<Example:> If each of the jobs tests a solution and one of jobs finds
the solution the job can tell GNU B<parallel> not to start more jobs the solution the job can tell GNU B<parallel> not to start more jobs
by: B<kill -TERM $PARALLEL_PID>. This only works on the local by: B<kill -TERM $PARALLEL_PID>. This only works on the local
computer. computer.
=item $PARALLEL_SEQ
$PARALLEL_SEQ will be set to the sequence number of the job
running. Remember to quote the $, so it gets evaluated by the correct
shell.
B<Example:>
B<seq 1 10 | parallel -N2 echo seq:'$'PARALLEL_SEQ arg1:{1} arg2:{2}>
=item $PARALLEL =item $PARALLEL
The environment variable $PARALLEL will be used as default options for The environment variable $PARALLEL will be used as default options for
@ -1786,7 +1801,16 @@ B<xargs> has no support for grouping the output, therefore output may
run together, e.g. the first half of a line is from one process and run together, e.g. the first half of a line is from one process and
the last half of the line is from another process. The example the last half of the line is from another process. The example
B<Parallel grep> cannot be done reliably with B<xargs> because of B<Parallel grep> cannot be done reliably with B<xargs> because of
this. this. To see this in action try:
parallel perl -e '\$a=\"1{}\"x10000000\;print\ \$a,\"\\n\"' '>' {} ::: a b c d e f
ls -l a b c d e f
parallel -kP4 -n1 grep 1 > out.par ::: a b c d e f
echo a b c d e f | xargs -P4 -n1 grep 1 > out.xargs-unbuf
echo a b c d e f | xargs -P4 -n1 grep --line-buffered 1 > out.xargs-linebuf
echo a b c d e f | xargs -n1 grep --line-buffered 1 > out.xargs-serial
ls -l out*
md5sum out*
B<xargs> has no support for keeping the order of the output, therefore B<xargs> has no support for keeping the order of the output, therefore
if running jobs in parallel using B<xargs> the output of the second if running jobs in parallel using B<xargs> the output of the second
@ -2461,7 +2485,7 @@ sub parse_options {
GetOptions("debug|D" => \$::opt_D, GetOptions("debug|D" => \$::opt_D,
"xargs|m" => \$::opt_m, "xargs|m" => \$::opt_m,
"X" => \$::opt_X, "X" => \$::opt_X,
"v" => \$::opt_v, "v" => \@::opt_v,
"silent" => \$::opt_silent, "silent" => \$::opt_silent,
"keep-order|keeporder|k" => \$::opt_k, "keep-order|keeporder|k" => \$::opt_k,
"group|g" => \$::opt_g, "group|g" => \$::opt_g,
@ -2524,10 +2548,10 @@ sub parse_options {
"Y|shebang|hashbang" => \$::opt_shebang, "Y|shebang|hashbang" => \$::opt_shebang,
"skip-first-line" => \$::opt_skip_first_line, "skip-first-line" => \$::opt_skip_first_line,
) || die_usage(); ) || die_usage();
if(defined @::opt_v) { $Global::verbose = $#::opt_v+1; } # Convert -v -v to v=2
$Global::debug = (defined $::opt_D); $Global::debug = (defined $::opt_D);
if(defined $::opt_m) { $Global::xargs = 1; } if(defined $::opt_m) { $Global::xargs = 1; }
if(defined $::opt_X) { $Global::Xargs = 1; } if(defined $::opt_X) { $Global::Xargs = 1; }
if(defined $::opt_v) { $Global::verbose = 1; }
if(defined $::opt_silent) { $Global::verbose = 0; } if(defined $::opt_silent) { $Global::verbose = 0; }
if(defined $::opt_k) { $Global::keeporder = 1; } if(defined $::opt_k) { $Global::keeporder = 1; }
if(defined $::opt_g) { $Global::grouped = 1; } if(defined $::opt_g) { $Global::grouped = 1; }
@ -3179,7 +3203,7 @@ sub compute_number_of_processes_for_sshlogins {
} }
sub compute_number_of_processes { sub compute_number_of_processes {
# Number of processes wanted and limited by system ressources # Number of processes wanted and limited by system resources
# Returns: # Returns:
# Number of processes # Number of processes
my $opt_P = shift; my $opt_P = shift;
@ -3622,6 +3646,15 @@ sub undef_as_zero {
return $a ? $a : 0; return $a ? $a : 0;
} }
sub hostname {
if(not $Private::hostname) {
my $hostname = `hostname`;
chomp($hostname);
$Private::hostname = $hostname || "nohostname";
}
return $Private::hostname;
}
sub __RUNNING_AND_PRINTING_THE_JOBS__ {} sub __RUNNING_AND_PRINTING_THE_JOBS__ {}
# Variable structure: # Variable structure:
@ -3994,8 +4027,13 @@ sub start_job {
} }
} }
if($Global::verbose and not $Global::grouped) { if($Global::verbose and not $Global::grouped) {
if($Global::verbose == 1) {
print STDOUT $clean_command,"\n";
} else {
# Verbose level > 1: Print the rsync and stuff
print STDOUT $command,"\n"; print STDOUT $command,"\n";
} }
}
$Global::total_running++; $Global::total_running++;
$Global::total_started++; $Global::total_started++;
#print STDERR "LEN".length($command)."\n"; #print STDERR "LEN".length($command)."\n";
@ -4008,6 +4046,8 @@ sub start_job {
$Private::job_start_sequence++; $Private::job_start_sequence++;
$job_start_sequence = $Private::job_start_sequence; $job_start_sequence = $Private::job_start_sequence;
} }
$ENV{'PARALLEL_SEQ'} = $job_start_sequence;
$ENV{'PARALLEL_PID'} = $$;
debug("$Global::total_running processes. Starting ($job_start_sequence): $command\n"); debug("$Global::total_running processes. Starting ($job_start_sequence): $command\n");
if(@::opt_a and $job_start_sequence == 1) { if(@::opt_a and $job_start_sequence == 1) {
# Give STDIN to the first job if using -a # Give STDIN to the first job if using -a
@ -4062,11 +4102,17 @@ sub print_job {
my $out = $fhs->{out}; my $out = $fhs->{out};
my $err = $fhs->{err}; my $err = $fhs->{err};
my $command = $fhs->{command}; my $command = $fhs->{command};
my $clean_command = $fhs->{clean_command};
debug(">>joboutput $command\n"); debug(">>joboutput $command\n");
if($Global::verbose and $Global::grouped) { if($Global::verbose and $Global::grouped) {
if($Global::verbose == 1) {
print STDOUT $clean_command,"\n";
} else {
# Verbose level > 1: Print the rsync and stuff
print STDOUT $command,"\n"; print STDOUT $command,"\n";
# If STDOUT and STDERR is merged, we want the command to be printed first }
# If STDOUT and STDERR are merged, we want the command to be printed first
# so flush to avoid STDOUT being buffered # so flush to avoid STDOUT being buffered
flush STDOUT; flush STDOUT;
} }
@ -4120,6 +4166,7 @@ sub get_command_line_with_sshlogin {
my ($sshcmd,$serverlogin) = sshcommand_of_sshlogin($sshlogin); my ($sshcmd,$serverlogin) = sshcommand_of_sshlogin($sshlogin);
my ($pre,$post)=("",""); my ($pre,$post)=("","");
if($next_command_line and $serverlogin ne ":") { if($next_command_line and $serverlogin ne ":") {
$Global::transfer_seq++;
for my $file (@$args_ref) { for my $file (@$args_ref) {
if($::opt_transfer) { if($::opt_transfer) {
# --transfer # --transfer
@ -4138,13 +4185,39 @@ sub get_command_line_with_sshlogin {
# We need to save the exit status of the job # We need to save the exit status of the job
$post = '_EXIT_status=$?; '.$post.' exit $_EXIT_status;'; $post = '_EXIT_status=$?; '.$post.' exit $_EXIT_status;';
} }
return ($pre . "$sshcmd $serverlogin " my $parallel_env = 'PARALLEL_SEQ=$PARALLEL_SEQ\;export PARALLEL_SEQ\;'.
'PARALLEL_PID=$PARALLEL_PID\;export PARALLEL_PID\;';
if($::opt_workdir) {
return ($pre . "$sshcmd $serverlogin $parallel_env ".shell_quote("cd ".workdir()." && ")
.shell_quote($next_command_line).";".$post,$clean_command); .shell_quote($next_command_line).";".$post,$clean_command);
} else {
return ($pre . "$sshcmd $serverlogin $parallel_env "
.shell_quote($next_command_line).";".$post,$clean_command);
}
} else { } else {
return ($next_command_line,$clean_command); return ($next_command_line,$clean_command);
} }
} }
sub workdir {
# Returns:
# the workdir on a remote machine
my $workdir;
if(defined $::opt_workdir) {
if($::opt_workdir ne "...") {
$workdir = $::opt_workdir;
$workdir =~ s:/\./:/:g; # Rsync treats /./ special. We dont want that
$workdir =~ s:/+$::; # Remove ending / if any
$workdir =~ s:^\./::g; # Remove starting ./ if any
} else {
$workdir = ".parallel/tmp/".hostname()."-".$$."-".$Global::transfer_seq;
}
} else {
$workdir = ".";
}
return $workdir;
}
sub get_command_line { sub get_command_line {
# Returns: # Returns:
# next command line # next command line
@ -4424,7 +4497,9 @@ sub control_path_dir {
# Returns: # Returns:
# path to directory # path to directory
if(not $Private::control_path_dir) { if(not $Private::control_path_dir) {
$Private::control_path_dir = tempdir("/tmp/parallel-ssh-XXXX", CLEANUP => 1 ); $Private::control_path_dir =
tempdir($ENV{'HOME'}."/.parallel/tmp/control_path_dir-XXXX",
CLEANUP => 1);
} }
return $Private::control_path_dir; return $Private::control_path_dir;
} }
@ -4450,7 +4525,29 @@ sub sshcleanup {
# ssh command needed to remove file from sshlogin # ssh command needed to remove file from sshlogin
my ($sshlogin,$file) = (@_); my ($sshlogin,$file) = (@_);
my ($sshcmd,$serverlogin) = sshcommand_of_sshlogin($sshlogin); my ($sshcmd,$serverlogin) = sshcommand_of_sshlogin($sshlogin);
return "$sshcmd $serverlogin rm -f ".shell_quote($file); my $workdir = workdir();
my $removeworkdir = "";
my @subworkdirs = parentdirs_of($file);
if(@subworkdirs) {
$removeworkdir = "; rmdir 2>/dev/null ".join(" ",map { $workdir."/".$_ } @subworkdirs);
}
my $relpath = ($file !~ m:^/:); # Is the path relative?
my $cleandir = ($relpath ? $workdir : "");
return "$sshcmd $serverlogin rm -f ".shell_quote($file.$removeworkdir)." ";
}
sub parentdirs_of {
# Return:
# all parentdirs except . of this dir or file sorted descending by length
my $d = shift;
my @parents = ();
while($d =~ s:/[^/]+$::) {
if($d ne ".") {
push @parents, $d;
}
}
return @parents;
} }
sub sshtransferreturn { sub sshtransferreturn {
@ -4463,32 +4560,39 @@ sub sshtransferreturn {
$file =~ s:^\./::g; # Remove ./ if any $file =~ s:^\./::g; # Remove ./ if any
my $relpath = ($file !~ m:^/:); # Is the path relative? my $relpath = ($file !~ m:^/:); # Is the path relative?
# Use different subdirs depending on abs or rel path # Use different subdirs depending on abs or rel path
my $rsync_destdir = ($relpath ? "./" : "/");
if($transfer) { if($transfer) {
# Abs path: rsync -rlDzRE /home/tange/dir/subdir/file.gz server:/ # Abs path: rsync -rlDzRE /home/tange/dir/subdir/file.gz server:/
# Rel path: rsync -rlDzRE ./subdir/file.gz server:./ # Rel path: rsync -rlDzRE ./subdir/file.gz server:.parallel/tmp/tempid/
# Rel path: rsync -rlDzRE ./subdir/file.gz server:$workdir/
my $remote_workdir = workdir($file);
my $rsync_destdir = ($relpath ? $remote_workdir : "/");
if($relpath) { if($relpath) {
$file = "./".$file; $file = "./".$file;
} }
if(-r shell_unquote($file)) { if(-r shell_unquote($file)) {
return "rsync $rsync_opt $file $serverlogin:$rsync_destdir"; my $mkremote_workdir =
$remote_workdir eq "." ? "true" : "ssh $serverlogin mkdir -p $rsync_destdir";
return "$mkremote_workdir; rsync $rsync_opt $file $serverlogin:$rsync_destdir";
} else { } else {
print STDERR "Warning: $file is not readable and will not be transferred\n"; print STDERR "Warning: $file is not readable and will not be transferred\n";
return "true"; # dummy command to run return "true"; # dummy command to run
} }
} else { } else {
# Return or cleanup
my $noext = no_extension($file); # Remove .ext before prepending ./ my $noext = no_extension($file); # Remove .ext before prepending ./
my @cmd = (); my @cmd = ();
my $rsync_destdir = ($relpath ? "./" : "/");
for my $ret_file (@Global::ret_files) { for my $ret_file (@Global::ret_files) {
my $remove = $removesource ? "--remove-source-files" : ""; my $remove = $removesource ? "--remove-source-files" : "";
# If relative path: prepend ./ (to avoid problems with ':') # If relative path: prepend workdir/./ to avoid problems if the dir contains ':'
my $replaced = ($relpath ? "./" : "") . # and to get the right relative return path
my $replaced = ($relpath ? workdir()."/./" : "") .
context_replace($ret_file,[$file],[$noext]); context_replace($ret_file,[$file],[$noext]);
# --return # --return
# Abs path: rsync -rlDzRE server:/home/tange/dir/subdir/file.gz / # Abs path: rsync -rlDzRE server:/home/tange/dir/subdir/file.gz /
# Rel path: rsync -rlDzRE server:./subsir/file.gz ./ # Rel path: rsync -rlDzRE server:./subsir/file.gz ./
push(@cmd, "rsync $rsync_opt $remove $serverlogin:" push(@cmd, "rsync $rsync_opt $remove $serverlogin:".
.shell_quote($replaced)." ".$rsync_destdir); shell_quote($replaced) . " ".$rsync_destdir);
} }
return join(";",@cmd); return join(";",@cmd);
} }
@ -4747,7 +4851,6 @@ sub my_memory_usage {
use strict; use strict;
use FileHandle; use FileHandle;
my $pid = $$; my $pid = $$;
if(-e "/proc/$pid/stat") { if(-e "/proc/$pid/stat") {
my $fh = FileHandle->new("</proc/$pid/stat"); my $fh = FileHandle->new("</proc/$pid/stat");

View file

@ -122,7 +122,7 @@ retry the command. Default is I<--retries 1>.
=item B<-s> I<string> =item B<-s> I<string>
Field separator. Use I<string> as seperator between columns. Field separator. Use I<string> as separator between columns.
=item B<--skip-first-line> =item B<--skip-first-line>

View file

@ -0,0 +1 @@
efg

View file

@ -0,0 +1 @@
efg

View file

@ -0,0 +1 @@
efg

View file

@ -0,0 +1 @@
efg

View file

@ -1,28 +1,26 @@
#!/bin/bash #!/bin/bash
PAR=parallel
rsync -Ha --delete input-files/testdir/ tmp/ rsync -Ha --delete input-files/testdir/ tmp/
cd tmp cd tmp
echo echo test of cat pipe sh | $PAR -j 50 2>&1 echo echo test of cat pipe sh | parallel -j 50 2>&1
find . -name '*.jpg' | $PAR -j +0 convert -geometry 120 {} {}_thumb.jpg find . -name '*.jpg' | parallel -j +0 convert -geometry 120 {} {}_thumb.jpg
find . -name '*_thumb.jpg' | ren 's:/([^/]+)_thumb.jpg$:/thumb_$1:' find . -name '*_thumb.jpg' | ren 's:/([^/]+)_thumb.jpg$:/thumb_$1:'
ls | $PAR ls | sort ls | parallel ls | sort
ls | $PAR echo ls | sort ls | parallel echo ls | sort
ls | $PAR -j 1 echo ls | sort ls | parallel -j 1 echo ls | sort
find -type f | $PAR diff {} a/foo ">"{}.diff | sort find -type f | parallel diff {} a/foo ">"{}.diff | sort
ls | $PAR -vg "ls {}|wc;echo {}" | sort ls | parallel -vg "ls {}|wc;echo {}" | sort
echo '### Check that we can have more input than max procs (-j 0)' echo '### Check that we can have more input than max procs (-j 0)'
perl -e 'print map {"more_than_5000-$_\n" } (4000..9999)' | $PAR -vj 0 touch | sort | tail perl -e 'print map {"more_than_5000-$_\n" } (4000..9999)' | parallel -vj 0 touch | sort | tail
perl -e 'print map {"more_than_5000-$_\n" } (4000..9900)' | $PAR -j 0 rm | sort perl -e 'print map {"more_than_5000-$_\n" } (4000..9900)' | parallel -j 0 rm | sort
ls | $PAR -j500 'sleep 1; ls {} | perl -ne "END{print $..\" {}\n\"}"' | sort ls | parallel -j500 'sleep 1; find {} -type f | perl -ne "END{print $..\" {}\n\"}"' | sort
ls | $PAR -gj500 'sleep 1; ls {} | perl -ne "END{print $..\" {}\n\"}"' | sort ls | parallel -gj500 'sleep 1; find {} -type f | perl -ne "END{print $..\" {}\n\"}"' | sort
ls | $PAR -g "perl -ne '/^\\S+\\s+\\S+$/ and print \$ARGV,\"\\n\"'" | sort find . -type f | parallel -g "perl -ne '/^\\S+\\s+\\S+$/ and print \$ARGV,\"\\n\"'" | sort
ls | $PAR -vg "perl -ne '/^\\S+\\s+\\S+$/ and print \$ARGV,\"\\n\"'" | sort find . -type f | parallel -vg "perl -ne '/^\\S+\\s+\\S+$/ and print \$ARGV,\"\\n\"'" | sort
ls | $PAR -qg perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' | sort find . -type f | parallel -qg perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' | sort
ls | $PAR -qvg perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' | sort find . -type f | parallel -qvg perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' | sort
cd .. cd ..
rm -rf tmp rm -rf tmp

View file

@ -3,7 +3,7 @@
echo '### Test -k' echo '### Test -k'
ulimit -n 50 ulimit -n 50
(echo "sleep 3; echo begin"; seq 1 30 | parallel -kq echo "sleep 1; echo {}"; echo "echo end") \ (echo "sleep 3; echo begin"; seq 1 30 | parallel -kq echo "sleep 1; echo {}"; echo "echo end") \
| parallel -k -j0 | stdout parallel -k -j0
echo '### Test --keep-order' echo '### Test --keep-order'
(seq 0 2) | parallel --keep-order -j100% -S 1/:,2/parallel@server2 -q perl -e 'sleep 1;print "job{}\n";exit({})' (seq 0 2) | parallel --keep-order -j100% -S 1/:,2/parallel@server2 -q perl -e 'sleep 1;print "job{}\n";exit({})'
@ -12,4 +12,4 @@ echo '### Test --keeporder'
(seq 0 2) | parallel --keeporder -j100% -S 1/:,2/parallel@server2 -q perl -e 'sleep 1;print "job{}\n";exit({})' (seq 0 2) | parallel --keeporder -j100% -S 1/:,2/parallel@server2 -q perl -e 'sleep 1;print "job{}\n";exit({})'
echo '### Test SIGTERM' echo '### Test SIGTERM'
(sleep 5; killall parallel -TERM) & seq 1 100 | parallel -k sleep 3';' echo (sleep 5; killall parallel -TERM) & seq 1 100 | stdout parallel -k sleep 3';' echo | sort

View file

@ -19,8 +19,8 @@ cat /tmp/test17 | parallel -k /bin/echo /tmp/parallel.file{}.file >/tmp/test17ab
cat /tmp/test17 | parallel -k /bin/echo tmp/parallel.file{}.file >/tmp/test17rel cat /tmp/test17 | parallel -k /bin/echo tmp/parallel.file{}.file >/tmp/test17rel
echo '### --transfer - abspath' echo '### --transfer - abspath'
stdout ssh $SERVER1 'rm -rf tmp/parallel.file*' stdout ssh $SERVER1 'rm -rf /tmp/parallel.file*'
stdout ssh parallel@$SERVER2 'rm -rf tmp/parallel.file*' stdout ssh parallel@$SERVER2 'rm -rf /tmp/parallel.file*'
cat /tmp/test17abs | parallel -k --transfer --sshlogin $SERVER1,parallel@$SERVER2 cat {}";"rm {} cat /tmp/test17abs | parallel -k --transfer --sshlogin $SERVER1,parallel@$SERVER2 cat {}";"rm {}
# One of these should give the empty dir /tmp/parallel.file # One of these should give the empty dir /tmp/parallel.file
echo good if no file echo good if no file
@ -62,7 +62,7 @@ ls /tmp/parallel.file*out /tmp/parallel.file/*out
echo '### --return - relpath' echo '### --return - relpath'
rm -rf /tmp/parallel.file*out rm -rf /tmp/parallel.file*out
cat /tmp/test17rel | parallel -k --return {.}.out --sshlogin $SERVER1,parallel@$SERVER2 mkdir -p tmp ';'echo {} ">"{.}.out cat /tmp/test17rel | parallel -k --return {.}.out --sshlogin $SERVER1,parallel@$SERVER2 mkdir -p tmp/parallel.file ';'echo {} ">"{.}.out
ls tmp/parallel.file*out tmp/parallel.file/*out ls tmp/parallel.file*out tmp/parallel.file/*out
echo '### --return - multiple files' echo '### --return - multiple files'
@ -74,7 +74,7 @@ ls tmp/parallel.file*out tmp/parallel.file/*out tmp/parallel.file*done tmp/paral
echo '### --return --cleanup - abspath' echo '### --return --cleanup - abspath'
rm -rf /tmp/parallel.file*out /tmp/parallel.file/*out /tmp/parallel.file*done /tmp/parallel.file/*done rm -rf /tmp/parallel.file*out /tmp/parallel.file/*out /tmp/parallel.file*done /tmp/parallel.file/*done
cat /tmp/test17abs | parallel -k --return {.}.out --return {}.done --cleanup \ cat /tmp/test17abs | parallel -k --return {.}.out --return {}.done --cleanup \
--sshlogin $SERVER1,parallel@$SERVER2 mkdir -p tmp ';'echo {} ">"{.}.out';'echo {} ">"{}.done';' --sshlogin $SERVER1,parallel@$SERVER2 mkdir -p tmp/parallel.file ';'echo {} ">"{.}.out';'echo {} ">"{}.done';'
ls /tmp/parallel.file*out /tmp/parallel.file/*out /tmp/parallel.file*done /tmp/parallel.file/*done ls /tmp/parallel.file*out /tmp/parallel.file/*out /tmp/parallel.file*done /tmp/parallel.file/*done
echo good if no file echo good if no file
stdout ssh $SERVER1 ls '/tmp/parallel.file*' || echo OK stdout ssh $SERVER1 ls '/tmp/parallel.file*' || echo OK
@ -84,7 +84,7 @@ stdout ssh parallel@$SERVER2 ls '/tmp/parallel.file*' || echo OK
echo '### --return --cleanup - relpath' echo '### --return --cleanup - relpath'
rm -rf tmp/parallel.file*out tmp/parallel.file/*out tmp/parallel.file*done tmp/parallel.file/*done rm -rf tmp/parallel.file*out tmp/parallel.file/*out tmp/parallel.file*done tmp/parallel.file/*done
cat /tmp/test17rel | parallel -k --return {.}.out --return {}.done --cleanup \ cat /tmp/test17rel | parallel -k --return {.}.out --return {}.done --cleanup \
--sshlogin $SERVER1,parallel@$SERVER2 mkdir -p tmp ';'echo {} ">"{.}.out';'echo {} ">"{}.done';' --sshlogin $SERVER1,parallel@$SERVER2 mkdir -p tmp/parallel.file ';'echo {} ">"{.}.out';'echo {} ">"{}.done';'
ls tmp/parallel.file*out tmp/parallel.file/*out tmp/parallel.file*done tmp/parallel.file/*done ls tmp/parallel.file*out tmp/parallel.file/*out tmp/parallel.file*done tmp/parallel.file/*done
echo good if no file echo good if no file
stdout ssh $SERVER1 ls 'tmp/parallel.file*' || echo OK stdout ssh $SERVER1 ls 'tmp/parallel.file*' || echo OK
@ -94,7 +94,7 @@ stdout ssh parallel@$SERVER2 ls 'tmp/parallel.file*' || echo OK
echo '### --return --cleanup - multiple returns' echo '### --return --cleanup - multiple returns'
rm -rf tmp/parallel.file*out tmp/parallel.file/*out tmp/parallel.file*done tmp/parallel.file/*done rm -rf tmp/parallel.file*out tmp/parallel.file/*out tmp/parallel.file*done tmp/parallel.file/*done
cat /tmp/test17rel | parallel -k --return {.}.out --return {}.done --cleanup \ cat /tmp/test17rel | parallel -k --return {.}.out --return {}.done --cleanup \
--sshlogin $SERVER1,parallel@$SERVER2 mkdir -p tmp ';'echo {} ">"{.}.out';'echo {} ">"{}.done';' --sshlogin $SERVER1,parallel@$SERVER2 mkdir -p tmp/parallel.file ';'echo {} ">"{.}.out';'echo {} ">"{}.done';'
ls /tmp/parallel.file*out /tmp/parallel.file/*out /tmp/parallel.file*done /tmp/parallel.file/*done ls /tmp/parallel.file*out /tmp/parallel.file/*out /tmp/parallel.file*done /tmp/parallel.file/*done
echo good if no file echo good if no file
stdout ssh $SERVER1 ls 'tmp/parallel.file*' || echo OK stdout ssh $SERVER1 ls 'tmp/parallel.file*' || echo OK
@ -104,7 +104,7 @@ stdout ssh parallel@$SERVER2 ls 'tmp/parallel.file*' || echo OK
echo '### --transfer --return --cleanup - abspath' echo '### --transfer --return --cleanup - abspath'
rm -rf /tmp/parallel.file*out /tmp/parallel.file/*out /tmp/parallel.file*done /tmp/parallel.file/*done rm -rf /tmp/parallel.file*out /tmp/parallel.file/*out /tmp/parallel.file*done /tmp/parallel.file/*done
cat /tmp/test17abs | parallel -k --transfer --return {.}.out --return {}.done --cleanup \ cat /tmp/test17abs | parallel -k --transfer --return {.}.out --return {}.done --cleanup \
--sshlogin $SERVER1,parallel@$SERVER2 mkdir -p tmp ';'cat {} ">"{.}.out';'cat {} ">"{}.done';' --sshlogin $SERVER1,parallel@$SERVER2 cat {} ">"{.}.out';'cat {} ">"{}.done';'
ls /tmp/parallel.file*out /tmp/parallel.file/*out /tmp/parallel.file*done /tmp/parallel.file/*done ls /tmp/parallel.file*out /tmp/parallel.file/*out /tmp/parallel.file*done /tmp/parallel.file/*done
echo good if no file echo good if no file
stdout ssh $SERVER1 ls '/tmp/parallel.file*' || echo OK stdout ssh $SERVER1 ls '/tmp/parallel.file*' || echo OK

View file

@ -2,8 +2,6 @@
# TODO return multiple # TODO return multiple
PAR=parallel
SERVER1=parallel-server3 SERVER1=parallel-server3
SERVER2=parallel-server2 SERVER2=parallel-server2
@ -19,7 +17,7 @@ echo newline > '/tmp/parallel.file.
newline1' newline1'
echo newline > '/tmp/parallel.file. echo newline > '/tmp/parallel.file.
newline2' newline2'
find tmp/parallel*newline* -print0 | $PAR -0 -k --transfer --sshlogin $SERVER1,parallel@$SERVER2 cat {}";"rm {} find tmp/parallel*newline* -print0 | parallel -0 -k --transfer --sshlogin $SERVER1,parallel@$SERVER2 cat {}";"rm {}
# Should give: No such file or directory # Should give: No such file or directory
echo good if no file echo good if no file
stdout ssh $SERVER1 ls 'tmp/parallel.file*' stdout ssh $SERVER1 ls 'tmp/parallel.file*'
@ -31,7 +29,7 @@ echo newline > '/tmp/parallel.file.
newline1' newline1'
echo newline > '/tmp/parallel.file. echo newline > '/tmp/parallel.file.
newline2' newline2'
find tmp/parallel*newline* -print0 | $PAR -0 -k --transfer --cleanup --sshlogin $SERVER1,parallel@$SERVER2 cat {} find tmp/parallel*newline* -print0 | parallel -0 -k --transfer --cleanup --sshlogin $SERVER1,parallel@$SERVER2 cat {}
# Should give: No such file or directory # Should give: No such file or directory
echo good if no file echo good if no file
stdout ssh $SERVER1 ls 'tmp/parallel.file*' stdout ssh $SERVER1 ls 'tmp/parallel.file*'
@ -39,11 +37,12 @@ stdout ssh $SERVER1 ls 'tmp/parallel.file*'
stdout ssh parallel@$SERVER2 ls 'tmp/parallel.file*' stdout ssh parallel@$SERVER2 ls 'tmp/parallel.file*'
echo '### --return - file with newline' echo '### --return - file with newline'
rm -rf /tmp/parallel.file.*newline*
echo newline > '/tmp/parallel.file. echo newline > '/tmp/parallel.file.
newline1' newline1'
echo newline > '/tmp/parallel.file. echo newline > '/tmp/parallel.file.
newline2' newline2'
find tmp/parallel*newline* -print0 | $PAR -0 -k --return {}.out --sshlogin $SERVER1,parallel@$SERVER2 echo remote '>' {}.out find tmp/parallel*newline* -print0 | parallel -0 -k --return {}.out --sshlogin $SERVER1,parallel@$SERVER2 mkdir -p tmp\;echo remote '>' {}.out
ls tmp/parallel*newline*out ls tmp/parallel*newline*out
rm tmp/parallel*newline*out rm tmp/parallel*newline*out
# Cleanup remote # Cleanup remote
@ -55,7 +54,7 @@ echo newline > '/tmp/parallel.file.
newline1' newline1'
echo newline > '/tmp/parallel.file. echo newline > '/tmp/parallel.file.
newline2' newline2'
find tmp/parallel*newline* -print0 | $PAR -0 -k --return {}.out --cleanup --sshlogin $SERVER1,parallel@$SERVER2 echo remote '>' {}.out find tmp/parallel*newline* -print0 | parallel -0 -k --return {}.out --cleanup --sshlogin $SERVER1,parallel@$SERVER2 echo remote '>' {}.out
ls tmp/parallel*newline*out ls tmp/parallel*newline*out
rm tmp/parallel*newline*out rm tmp/parallel*newline*out
echo good if no file echo good if no file
@ -68,7 +67,7 @@ echo newline > '/tmp/parallel.file.
newline1' newline1'
echo newline > '/tmp/parallel.file. echo newline > '/tmp/parallel.file.
newline2' newline2'
find tmp/parallel*newline* -print0 | $PAR -0 -k --transfer --return {}.out --cleanup --sshlogin $SERVER1,parallel@$SERVER2 cat {} '>' {}.out find tmp/parallel*newline* -print0 | parallel -0 -k --transfer --return {}.out --cleanup --sshlogin $SERVER1,parallel@$SERVER2 cat {} '>' {}.out
ls tmp/parallel*newline*out ls tmp/parallel*newline*out
rm tmp/parallel*newline*out rm tmp/parallel*newline*out
echo good if no file echo good if no file
@ -81,7 +80,7 @@ echo newline > '/tmp/parallel.file.
newline1' newline1'
echo newline > '/tmp/parallel.file. echo newline > '/tmp/parallel.file.
newline2' newline2'
find tmp/parallel*newline* -print0 | $PAR -0 -k --trc {}.out --sshlogin $SERVER1,parallel@$SERVER2 cat {} '>' {}.out find tmp/parallel*newline* -print0 | parallel -0 -k --trc {}.out --sshlogin $SERVER1,parallel@$SERVER2 cat {} '>' {}.out
ls tmp/parallel*newline*out ls tmp/parallel*newline*out
rm tmp/parallel*newline*out rm tmp/parallel*newline*out
echo good if no file echo good if no file
@ -94,7 +93,7 @@ echo newline > '/tmp/parallel.file.
newline1' newline1'
echo newline > '/tmp/parallel.file. echo newline > '/tmp/parallel.file.
newline2' newline2'
find tmp/parallel*newline* -print0 | $PAR -0 -k --trc {}.out --trc {}.out2 --sshlogin $SERVER1,parallel@$SERVER2 cat {} '>' {}.out';'cat {} '>' {}.out2 find tmp/parallel*newline* -print0 | parallel -0 -k --trc {}.out --trc {}.out2 --sshlogin $SERVER1,parallel@$SERVER2 cat {} '>' {}.out';'cat {} '>' {}.out2
ls tmp/parallel*newline*out* ls tmp/parallel*newline*out*
rm tmp/parallel*newline*out* rm tmp/parallel*newline*out*
echo good if no file echo good if no file
@ -111,7 +110,7 @@ echo newline > '/tmp/parallel.file.
newline1' newline1'
echo newline > '/tmp/parallel.file. echo newline > '/tmp/parallel.file.
newline2' newline2'
find tmp/parallel*newline* -print0 | $PAR -0 -k -j1 --trc {}.out --trc {}.out2 \ find tmp/parallel*newline* -print0 | parallel -0 -k -j1 --trc {}.out --trc {}.out2 \
--sshlogin "/tmp/myssh1 $SERVER1, /tmp/myssh2 parallel@$SERVER2" \ --sshlogin "/tmp/myssh1 $SERVER1, /tmp/myssh2 parallel@$SERVER2" \
cat {} '>' {}.out';'cat {} '>' {}.out2 cat {} '>' {}.out';'cat {} '>' {}.out2
ls tmp/parallel*newline*out* ls tmp/parallel*newline*out*
@ -120,13 +119,13 @@ echo good if no file
stdout ssh $SERVER1 ls 'tmp/parallel.file*' || echo OK stdout ssh $SERVER1 ls 'tmp/parallel.file*' || echo OK
# Should give: No such file or directory # Should give: No such file or directory
stdout ssh parallel@$SERVER2 ls 'tmp/parallel.file*' || echo OK stdout ssh parallel@$SERVER2 ls 'tmp/parallel.file*' || echo OK
echo Input for ssh echo 'Input for ssh'
cat /tmp/myssh1-run /tmp/myssh2-run cat /tmp/myssh1-run /tmp/myssh2-run | perl -pe 's/PID=\d+/PID=00000/g'
rm /tmp/myssh1-run /tmp/myssh2-run rm /tmp/myssh1-run /tmp/myssh2-run
echo '### Test use special ssh with > 9 simultaneous' echo '### Test use special ssh with > 9 simultaneous'
echo 'ssh "$@"; echo "$@" >>/tmp/myssh1-run' >/tmp/myssh1 echo 'ssh "$@"; echo "$@" >>/tmp/myssh1-run' >/tmp/myssh1
echo 'ssh "$@"; echo "$@" >>/tmp/myssh2-run' >/tmp/myssh2 echo 'ssh "$@"; echo "$@" >>/tmp/myssh2-run' >/tmp/myssh2
chmod 755 /tmp/myssh1 /tmp/myssh2 chmod 755 /tmp/myssh1 /tmp/myssh2
seq 1 100 | $PAR --sshlogin "/tmp/myssh1 $SERVER1, /tmp/myssh2 parallel@$SERVER2" \ seq 1 100 | parallel --sshlogin "/tmp/myssh1 $SERVER1, /tmp/myssh2 parallel@$SERVER2" \
-j10000% -k echo -j10000% -k echo

View file

@ -7,11 +7,11 @@ echo '### Test $PARALLEL'
echo | PARALLEL=--number-of-cpus parallel echo | PARALLEL=--number-of-cpus parallel
seq 1 2 | PARALLEL="-S$SERVER1 seq 1 2 | PARALLEL="-S$SERVER1
-Sssh -l parallel $SERVER2 -Sssh -l parallel $SERVER2
-j1" parallel -kv echo -j1" parallel -kvv echo
echo '### Test ~/.parallel/config' echo '### Test ~/.parallel/config'
echo "-S$SERVER1 echo "-S$SERVER1
-Sssh -l parallel $SERVER2 -Sssh -l parallel $SERVER2
-j1" > ~/.parallel/config -j1" > ~/.parallel/config
seq 1 2 | parallel -kv echo seq 1 2 | parallel -kvv echo
rm ~/.parallel/config rm ~/.parallel/config

View file

@ -0,0 +1,45 @@
#!/bin/bash
rsync -Ha --delete input-files/testdir/ tmp/
cd tmp
SERVER2=parallel@parallel-server2
echo $SERVER2 >~/.parallel/sshloginfile
echo '### Test -W newtempdir/newdir/tmp/ with space dirs'
ssh $SERVER2 rm -rf newtempdir
stdout parallel -k -W newtempdir/newdir/tmp/ --basefile 1-col.txt --trc {}.6 -S .. -v echo ">"{}.6 ::: './ ab/c"d/ef g' ' ab/c"d/efg' ./b/bar ./b/foo "./ ab /c' d/ ef\"g" ./2-col.txt './a b/cd / ef/efg'
# A few rmdir errors are OK as we have multiple files in the same dirs
find . -name '*.6'
echo '### Test -W /tmp/newtempdir/newdir/tmp/ with space dirs'
ssh $SERVER2 rm -rf /tmp/newtempdir
stdout parallel -k -W /tmp/newtempdir/newdir/tmp/ --basefile 1-col.txt --trc {}.7 -S .. -v echo ">"{}.7 ::: './ ab/c"d/ef g' ' ab/c"d/efg' ./b/bar ./b/foo "./ ab /c' d/ ef\"g" ./2-col.txt './a b/cd / ef/efg'
# A few rmdir errors are OK as we have multiple files in the same dirs
find . -name '*.7'
echo '### Test --workdir ...'
parallel -k --workdir ... --basefile 1-col.txt --trc {}.1 -S .. echo ">"{}.1 ::: 2-col.txt
find . -name '*.1'
echo '### Test -W ...'
parallel -k -W ... --basefile 1-col.txt --trc {}.2 -S .. -v echo ">"{}.2 ::: 2-col.txt
find . -name '*.2'
echo '### Test -W ... with space dirs'
stdout parallel -k -W ... --basefile 1-col.txt --trc {}.3 -S .. -v echo ">"{}.3 ::: './ ab/c"d/ef g' ' ab/c"d/efg' ./b/bar ./b/foo "./ ab /c' d/ ef\"g" ./2-col.txt './a b/cd / ef/efg'
# A few rmdir errors are OK as we have multiple files in the same dirs
find . -name '*.3'
echo '### Test -W tmpdir'
parallel -k -W tmpdir --basefile 1-col.txt --trc {}.4 -S .. -v echo ">"{}.4 ::: 2-col.txt
find . -name '*.4'
echo '### Test -W /tmp/ with space dirs'
stdout parallel -k -W /tmp/ --basefile 1-col.txt --trc {}.5 -S .. -v echo ">"{}.5 ::: './ ab/c"d/ef g' ' ab/c"d/efg' ./b/bar ./b/foo "./ ab /c' d/ ef\"g" ./2-col.txt './a b/cd / ef/efg'
# A few rmdir errors are OK as we have multiple files in the same dirs
find . -name '*.5'
cd ..
rm -rf tmp

View file

@ -0,0 +1,16 @@
#!/bin/bash
SERVER1=parallel-server3
SERVER2=parallel-server2
echo '### Test $PARALLEL_SEQ - local'
seq 1 20 | parallel -kN2 echo arg1:{1} seq:'$'PARALLEL_SEQ arg2:{2}
echo '### Test $PARALLEL_SEQ - remote'
seq 1 20 | parallel -kN2 -S $SERVER1,parallel@$SERVER2 echo arg1:{1} seq:'$'PARALLEL_SEQ arg2:{2}
echo '### Test $PARALLEL_PID - local'
seq 1 20 | parallel -kN2 echo arg1:{1} seq:'$'PARALLEL_PID arg2:{2} | perl -pe 's/\d/0/g'
echo '### Test $PARALLEL_PID - remote'
seq 1 20 | parallel -kN2 -S $SERVER1,parallel@$SERVER2 echo arg1:{1} seq:'$'PARALLEL_PID arg2:{2} | perl -pe 's/\d/0/g'

View file

@ -3,33 +3,51 @@ test of cat pipe sh
2-col.txt 2-col.txt
bar bar
bar bar
c"d
c' d
cd
foo foo
foo foo
foo2 foo2
ls ab
ls ab
ls 1-col.txt ls 1-col.txt
ls 2-col.txt ls 2-col.txt
ls a ls a
ls a b
ls b ls b
ls ab
ls ab
ls 1-col.txt ls 1-col.txt
ls 2-col.txt ls 2-col.txt
ls a ls a
ls a b
ls b ls b
1 1 4
1 1 4
1 1 10 1 1 10
1 1 10 1 1 10
1 1 15 1 1 15
1 1 15 1 1 15
1 2 5
4 4 26 4 4 26
6 6 41 6 6 41
ab
ab
1-col.txt 1-col.txt
1-col.txt.diff 1-col.txt.diff
2-col.txt 2-col.txt
2-col.txt.diff 2-col.txt.diff
a a
a b
b b
ls 1-col.txt.diff|wc;echo 1-col.txt.diff ls 1-col.txt.diff|wc;echo 1-col.txt.diff
ls 1-col.txt|wc;echo 1-col.txt ls 1-col.txt|wc;echo 1-col.txt
ls 2-col.txt.diff|wc;echo 2-col.txt.diff ls 2-col.txt.diff|wc;echo 2-col.txt.diff
ls 2-col.txt|wc;echo 2-col.txt ls 2-col.txt|wc;echo 2-col.txt
ls \ ab\ |wc;echo \ ab\
ls \ ab|wc;echo \ ab
ls a\ b|wc;echo a\ b
ls a|wc;echo a ls a|wc;echo a
ls b|wc;echo b ls b|wc;echo b
### Check that we can have more input than max procs (-j 0) ### Check that we can have more input than max procs (-j 0)
@ -146,6 +164,9 @@ touch more_than_5000-9999
1 more_than_5000-9997 1 more_than_5000-9997
1 more_than_5000-9998 1 more_than_5000-9998
1 more_than_5000-9999 1 more_than_5000-9999
2 ab
2 a b
4 ab
4 b 4 b
6 a 6 a
1 1-col.txt 1 1-col.txt
@ -251,239 +272,322 @@ touch more_than_5000-9999
1 more_than_5000-9997 1 more_than_5000-9997
1 more_than_5000-9998 1 more_than_5000-9998
1 more_than_5000-9999 1 more_than_5000-9999
2 ab
2 a b
4 ab
4 b 4 b
6 a 6 a
1-col.txt.diff ./ ab /c' d/ ef"g.diff
1-col.txt.diff ./ ab /c' d/ ef"g.diff
2-col.txt ./ ab/c"d/ef g.diff
2-col.txt ./ ab/c"d/ef g.diff
2-col.txt.diff ./ ab/c"d/efg.diff
2-col.txt.diff ./ ab/c"d/efg.diff
1-col.txt.diff ./1-col.txt.diff
1-col.txt.diff ./1-col.txt.diff
2-col.txt ./2-col.txt
2-col.txt ./2-col.txt
2-col.txt.diff ./2-col.txt.diff
2-col.txt.diff ./2-col.txt.diff
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' 1-col.txt ./a b/cd / ef/efg.diff
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' 1-col.txt.diff ./a b/cd / ef/efg.diff
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' 2-col.txt ./a/bar.diff
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' 2-col.txt.diff ./a/bar.diff
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' a ./b/bar.diff
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' b ./b/bar.diff
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9901 ./ ab /c' d/ ef"g.diff
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9902 ./ ab /c' d/ ef"g.diff
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9903 ./ ab/c"d/ef g.diff
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9904 ./ ab/c"d/ef g.diff
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9905 ./ ab/c"d/efg.diff
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9906 ./ ab/c"d/efg.diff
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9907 ./1-col.txt.diff
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9908 ./1-col.txt.diff
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9909 ./2-col.txt
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9910 ./2-col.txt
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9911 ./2-col.txt.diff
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9912 ./2-col.txt.diff
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9913 ./a b/cd / ef/efg.diff
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9914 ./a b/cd / ef/efg.diff
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9915 ./a/bar.diff
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9916 ./a/bar.diff
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9917 ./b/bar.diff
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9918 ./b/bar.diff
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9919 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./1-col.txt
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9920 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./1-col.txt.diff
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9921 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./2-col.txt
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9922 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./2-col.txt.diff
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9923 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./\ ab/c\"d/ef\ g
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9924 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./\ ab/c\"d/ef\ g.diff
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9925 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./\ ab/c\"d/efg
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9926 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./\ ab/c\"d/efg.diff
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9927 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./\ ab\ /c\'\ d/\ ef\"g
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9928 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./\ ab\ /c\'\ d/\ ef\"g.diff
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9929 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./a/bar
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9930 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./a/bar.diff
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9931 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./a/foo
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9932 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./a/foo.diff
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9933 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./a/foo2
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9934 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./a/foo2.diff
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9935 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./a\ b/cd\ /\ ef/efg
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9936 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./a\ b/cd\ /\ ef/efg.diff
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9937 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./b/bar
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9938 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./b/bar.diff
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9939 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./b/foo
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9940 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./b/foo.diff
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9941 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9901
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9942 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9902
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9943 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9903
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9944 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9904
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9945 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9905
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9946 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9906
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9947 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9907
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9948 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9908
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9949 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9909
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9950 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9910
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9951 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9911
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9952 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9912
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9953 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9913
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9954 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9914
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9955 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9915
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9956 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9916
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9957 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9917
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9958 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9918
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9959 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9919
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9960 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9920
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9961 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9921
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9962 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9922
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9963 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9923
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9964 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9924
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9965 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9925
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9966 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9926
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9967 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9927
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9968 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9928
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9969 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9929
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9970 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9930
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9971 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9931
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9972 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9932
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9973 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9933
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9974 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9934
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9975 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9935
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9976 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9936
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9977 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9937
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9978 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9938
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9979 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9939
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9980 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9940
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9981 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9941
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9982 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9942
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9983 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9943
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9984 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9944
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9985 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9945
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9986 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9946
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9987 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9947
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9988 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9948
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9989 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9949
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9990 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9950
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9991 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9951
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9992 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9952
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9993 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9953
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9994 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9954
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9995 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9955
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9996 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9956
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9997 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9957
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9998 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9958
perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' more_than_5000-9999 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9959
1-col.txt.diff perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9960
1-col.txt.diff perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9961
2-col.txt perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9962
2-col.txt perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9963
2-col.txt.diff perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9964
2-col.txt.diff perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9965
1-col.txt.diff perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9966
1-col.txt.diff perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9967
2-col.txt perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9968
2-col.txt perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9969
2-col.txt.diff perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9970
2-col.txt.diff perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9971
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" 1-col.txt perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9972
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" 1-col.txt.diff perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9973
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" 2-col.txt perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9974
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" 2-col.txt.diff perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9975
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" a perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9976
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" b perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9977
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9901 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9978
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9902 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9979
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9903 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9980
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9904 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9981
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9905 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9982
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9906 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9983
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9907 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9984
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9908 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9985
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9909 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9986
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9910 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9987
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9911 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9988
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9912 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9989
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9913 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9990
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9914 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9991
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9915 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9992
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9916 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9993
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9917 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9994
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9918 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9995
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9919 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9996
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9920 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9997
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9921 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9998
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9922 perl -ne '/^\S+\s+\S+$/ and print $ARGV,"\n"' ./more_than_5000-9999
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9923 ./ ab /c' d/ ef"g.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9924 ./ ab /c' d/ ef"g.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9925 ./ ab/c"d/ef g.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9926 ./ ab/c"d/ef g.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9927 ./ ab/c"d/efg.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9928 ./ ab/c"d/efg.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9929 ./1-col.txt.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9930 ./1-col.txt.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9931 ./2-col.txt
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9932 ./2-col.txt
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9933 ./2-col.txt.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9934 ./2-col.txt.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9935 ./a b/cd / ef/efg.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9936 ./a b/cd / ef/efg.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9937 ./a/bar.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9938 ./a/bar.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9939 ./b/bar.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9940 ./b/bar.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9941 ./ ab /c' d/ ef"g.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9942 ./ ab /c' d/ ef"g.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9943 ./ ab/c"d/ef g.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9944 ./ ab/c"d/ef g.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9945 ./ ab/c"d/efg.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9946 ./ ab/c"d/efg.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9947 ./1-col.txt.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9948 ./1-col.txt.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9949 ./2-col.txt
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9950 ./2-col.txt
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9951 ./2-col.txt.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9952 ./2-col.txt.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9953 ./a b/cd / ef/efg.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9954 ./a b/cd / ef/efg.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9955 ./a/bar.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9956 ./a/bar.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9957 ./b/bar.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9958 ./b/bar.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9959 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./1-col.txt
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9960 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./1-col.txt.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9961 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./2-col.txt
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9962 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./2-col.txt.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9963 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./\ ab/c\"d/ef\ g
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9964 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./\ ab/c\"d/ef\ g.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9965 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./\ ab/c\"d/efg
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9966 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./\ ab/c\"d/efg.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9967 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./\ ab\ /c\'\ d/\ ef\"g
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9968 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./\ ab\ /c\'\ d/\ ef\"g.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9969 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./a/bar
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9970 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./a/bar.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9971 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./a/foo
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9972 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./a/foo.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9973 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./a/foo2
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9974 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./a/foo2.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9975 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./a\ b/cd\ /\ ef/efg
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9976 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./a\ b/cd\ /\ ef/efg.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9977 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./b/bar
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9978 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./b/bar.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9979 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./b/foo
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9980 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./b/foo.diff
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9981 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9901
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9982 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9902
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9983 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9903
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9984 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9904
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9985 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9905
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9986 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9906
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9987 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9907
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9988 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9908
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9989 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9909
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9990 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9910
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9991 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9911
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9992 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9912
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9993 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9913
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9994 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9914
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9995 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9915
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9996 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9916
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9997 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9917
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9998 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9918
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" more_than_5000-9999 perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9919
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9920
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9921
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9922
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9923
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9924
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9925
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9926
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9927
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9928
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9929
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9930
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9931
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9932
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9933
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9934
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9935
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9936
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9937
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9938
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9939
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9940
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9941
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9942
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9943
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9944
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9945
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9946
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9947
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9948
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9949
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9950
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9951
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9952
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9953
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9954
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9955
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9956
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9957
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9958
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9959
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9960
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9961
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9962
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9963
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9964
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9965
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9966
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9967
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9968
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9969
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9970
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9971
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9972
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9973
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9974
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9975
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9976
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9977
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9978
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9979
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9980
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9981
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9982
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9983
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9984
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9985
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9986
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9987
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9988
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9989
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9990
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9991
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9992
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9993
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9994
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9995
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9996
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9997
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9998
perl -ne /^\\S+\\s+\\S+\$/\ and\ print\ \$ARGV,\"\\n\" ./more_than_5000-9999

View file

@ -1,4 +1,5 @@
### Test -k ### Test -k
Warning: Only enough filehandles to run 20 jobs in parallel. Raising ulimit -n may help
begin begin
1 1
2 2
@ -41,14 +42,6 @@ job1
job2 job2
### Test SIGTERM ### Test SIGTERM
1 1
2
3
4
5
6
7
8
9
10 10
11 11
12 12
@ -58,3 +51,22 @@ job2
16 16
17 17
18 18
2
3
4
5
6
7
8
9
parallel: SIGTERM received. No new jobs will be started.
parallel: Waiting for these 9 jobs to finish. Send SIGTERM again to stop now.
parallel: sleep 3; echo 10
parallel: sleep 3; echo 11
parallel: sleep 3; echo 12
parallel: sleep 3; echo 13
parallel: sleep 3; echo 14
parallel: sleep 3; echo 15
parallel: sleep 3; echo 16
parallel: sleep 3; echo 17
parallel: sleep 3; echo 18

View file

@ -93,6 +93,8 @@ file20
good if no file good if no file
ls: cannot access tmp/parallel.file*: No such file or directory ls: cannot access tmp/parallel.file*: No such file or directory
OK OK
ls: cannot access tmp/parallel.file*: No such file or directory
OK
### --return - abspath ### --return - abspath
/tmp/parallel.file : & ) \n*.jpg.out /tmp/parallel.file : & ) \n*.jpg.out
/tmp/parallel.file/sub dir.out /tmp/parallel.file/sub dir.out
@ -262,8 +264,6 @@ tmp/parallel.file9.out
tmp/parallel.file>fire.file.done tmp/parallel.file>fire.file.done
tmp/parallel.file>fire.out tmp/parallel.file>fire.out
good if no file good if no file
ls: cannot access tmp/parallel.file*: No such file or directory
OK
### --return --cleanup - multiple returns ### --return --cleanup - multiple returns
/tmp/parallel.file : & ) \n*.jpg.file.done /tmp/parallel.file : & ) \n*.jpg.file.done
/tmp/parallel.file : & ) \n*.jpg.out /tmp/parallel.file : & ) \n*.jpg.out
@ -306,8 +306,6 @@ OK
/tmp/parallel.file>fire.file.done /tmp/parallel.file>fire.file.done
/tmp/parallel.file>fire.out /tmp/parallel.file>fire.out
good if no file good if no file
ls: cannot access tmp/parallel.file*: No such file or directory
OK
### --transfer --return --cleanup - abspath ### --transfer --return --cleanup - abspath
/tmp/parallel.file : & ) \n*.jpg.file.done /tmp/parallel.file : & ) \n*.jpg.file.done
/tmp/parallel.file : & ) \n*.jpg.out /tmp/parallel.file : & ) \n*.jpg.out
@ -572,63 +570,63 @@ good if no file
ls: cannot access /tmp/parallel.file*: No such file or directory ls: cannot access /tmp/parallel.file*: No such file or directory
OK OK
### --transfer --cleanup - multiple argument files ### --transfer --cleanup - multiple argument files
rsync -rlDzRE -essh ./tmp/parallel.file1.file parallel@parallel-server2:./;rsync -rlDzRE -essh /tmp/parallel.file\>fire.file parallel@parallel-server2:/;ssh parallel@parallel-server2 cat\ /tmp/parallel.file\\\>fire.file\ tmp/parallel.file1.file;_EXIT_status=$?; ssh parallel@parallel-server2 rm -f tmp/parallel.file1.file;ssh parallel@parallel-server2 rm -f /tmp/parallel.file\\\>fire.file; exit $_EXIT_status; cat /tmp/parallel.file\>fire.file tmp/parallel.file1.file
file>fire file>fire
file1 file1
rsync -rlDzRE -essh ./tmp/parallel.file2.file parallel@parallel-server2:./;rsync -rlDzRE -essh /tmp/parallel.file9.file parallel@parallel-server2:/;ssh parallel@parallel-server2 cat\ /tmp/parallel.file9.file\ tmp/parallel.file2.file;_EXIT_status=$?; ssh parallel@parallel-server2 rm -f tmp/parallel.file2.file;ssh parallel@parallel-server2 rm -f /tmp/parallel.file9.file; exit $_EXIT_status; cat /tmp/parallel.file9.file tmp/parallel.file2.file
file9 file9
file2 file2
rsync -rlDzRE -essh ./tmp/parallel.file3.file parallel@parallel-server2:./;rsync -rlDzRE -essh /tmp/parallel.file8.file parallel@parallel-server2:/;ssh parallel@parallel-server2 cat\ /tmp/parallel.file8.file\ tmp/parallel.file3.file;_EXIT_status=$?; ssh parallel@parallel-server2 rm -f tmp/parallel.file3.file;ssh parallel@parallel-server2 rm -f /tmp/parallel.file8.file; exit $_EXIT_status; cat /tmp/parallel.file8.file tmp/parallel.file3.file
file8 file8
file3 file3
rsync -rlDzRE -essh ./tmp/parallel.file\>fire.file parallel@parallel-server2:./;rsync -rlDzRE -essh /tmp/parallel.file7.file parallel@parallel-server2:/;ssh parallel@parallel-server2 cat\ /tmp/parallel.file7.file\ tmp/parallel.file\\\>fire.file;_EXIT_status=$?; ssh parallel@parallel-server2 rm -f tmp/parallel.file\\\>fire.file;ssh parallel@parallel-server2 rm -f /tmp/parallel.file7.file; exit $_EXIT_status; cat /tmp/parallel.file7.file tmp/parallel.file\>fire.file
file7 file7
file>fire file>fire
rsync -rlDzRE -essh ./tmp/parallel.file5.file parallel@parallel-server2:./;rsync -rlDzRE -essh /tmp/parallel.file6.file parallel@parallel-server2:/;ssh parallel@parallel-server2 cat\ /tmp/parallel.file6.file\ tmp/parallel.file5.file;_EXIT_status=$?; ssh parallel@parallel-server2 rm -f tmp/parallel.file5.file;ssh parallel@parallel-server2 rm -f /tmp/parallel.file6.file; exit $_EXIT_status; cat /tmp/parallel.file6.file tmp/parallel.file5.file
file6 file6
file5 file5
rsync -rlDzRE -essh ./tmp/parallel.file6.file parallel@parallel-server2:./;rsync -rlDzRE -essh /tmp/parallel.file5.file parallel@parallel-server2:/;ssh parallel@parallel-server2 cat\ /tmp/parallel.file5.file\ tmp/parallel.file6.file;_EXIT_status=$?; ssh parallel@parallel-server2 rm -f tmp/parallel.file6.file;ssh parallel@parallel-server2 rm -f /tmp/parallel.file5.file; exit $_EXIT_status; cat /tmp/parallel.file5.file tmp/parallel.file6.file
file5 file5
file6 file6
rsync -rlDzRE -essh ./tmp/parallel.file7.file parallel@parallel-server2:./;rsync -rlDzRE -essh /tmp/parallel.file3.file parallel@parallel-server2:/;ssh parallel@parallel-server2 cat\ /tmp/parallel.file3.file\ tmp/parallel.file7.file;_EXIT_status=$?; ssh parallel@parallel-server2 rm -f tmp/parallel.file7.file;ssh parallel@parallel-server2 rm -f /tmp/parallel.file3.file; exit $_EXIT_status; cat /tmp/parallel.file3.file tmp/parallel.file7.file
file3 file3
file7 file7
rsync -rlDzRE -essh ./tmp/parallel.file8.file parallel@parallel-server2:./;rsync -rlDzRE -essh /tmp/parallel.file20.file parallel@parallel-server2:/;ssh parallel@parallel-server2 cat\ /tmp/parallel.file20.file\ tmp/parallel.file8.file;_EXIT_status=$?; ssh parallel@parallel-server2 rm -f tmp/parallel.file8.file;ssh parallel@parallel-server2 rm -f /tmp/parallel.file20.file; exit $_EXIT_status; cat /tmp/parallel.file20.file tmp/parallel.file8.file
file20 file20
file8 file8
rsync -rlDzRE -essh ./tmp/parallel.file9.file parallel@parallel-server2:./;rsync -rlDzRE -essh /tmp/parallel.file2.file parallel@parallel-server2:/;ssh parallel@parallel-server2 cat\ /tmp/parallel.file2.file\ tmp/parallel.file9.file;_EXIT_status=$?; ssh parallel@parallel-server2 rm -f tmp/parallel.file9.file;ssh parallel@parallel-server2 rm -f /tmp/parallel.file2.file; exit $_EXIT_status; cat /tmp/parallel.file2.file tmp/parallel.file9.file
file2 file2
file9 file9
rsync -rlDzRE -essh ./tmp/parallel.file10.file parallel@parallel-server2:./;rsync -rlDzRE -essh /tmp/parallel.file19.file parallel@parallel-server2:/;ssh parallel@parallel-server2 cat\ /tmp/parallel.file19.file\ tmp/parallel.file10.file;_EXIT_status=$?; ssh parallel@parallel-server2 rm -f tmp/parallel.file10.file;ssh parallel@parallel-server2 rm -f /tmp/parallel.file19.file; exit $_EXIT_status; cat /tmp/parallel.file19.file tmp/parallel.file10.file
file19 file19
file10 file10
rsync -rlDzRE -essh ./tmp/parallel.file\ :\ \&\ \)\ \\n\*.jpg.file parallel@parallel-server2:./;rsync -rlDzRE -essh /tmp/parallel.file18.file parallel@parallel-server2:/;ssh parallel@parallel-server2 cat\ /tmp/parallel.file18.file\ tmp/parallel.file\\\ :\\\ \\\&\\\ \\\)\\\ \\\\n\\\*.jpg.file;_EXIT_status=$?; ssh parallel@parallel-server2 rm -f tmp/parallel.file\\\ :\\\ \\\&\\\ \\\)\\\ \\\\n\\\*.jpg.file;ssh parallel@parallel-server2 rm -f /tmp/parallel.file18.file; exit $_EXIT_status; cat /tmp/parallel.file18.file tmp/parallel.file\ :\ \&\ \)\ \\n\*.jpg.file
file18 file18
file : & ) \n*.jpg file : & ) \n*.jpg
rsync -rlDzRE -essh ./tmp/parallel.file/sub\ dir.file parallel@parallel-server2:./;rsync -rlDzRE -essh /tmp/parallel.file17.file parallel@parallel-server2:/;ssh parallel@parallel-server2 cat\ /tmp/parallel.file17.file\ tmp/parallel.file/./sub\\\ dir.file;_EXIT_status=$?; ssh parallel@parallel-server2 rm -f tmp/parallel.file/./sub\\\ dir.file;ssh parallel@parallel-server2 rm -f /tmp/parallel.file17.file; exit $_EXIT_status; cat /tmp/parallel.file17.file tmp/parallel.file/./sub\ dir.file
file17 file17
file/./sub dir file/./sub dir
rsync -rlDzRE -essh ./tmp/parallel.file13.file parallel@parallel-server2:./;rsync -rlDzRE -essh /tmp/parallel.file16.file parallel@parallel-server2:/;ssh parallel@parallel-server2 cat\ /tmp/parallel.file16.file\ tmp/parallel.file13.file;_EXIT_status=$?; ssh parallel@parallel-server2 rm -f tmp/parallel.file13.file;ssh parallel@parallel-server2 rm -f /tmp/parallel.file16.file; exit $_EXIT_status; cat /tmp/parallel.file16.file tmp/parallel.file13.file
file16 file16
file13 file13
rsync -rlDzRE -essh ./tmp/parallel.file14.file parallel@parallel-server2:./;rsync -rlDzRE -essh /tmp/parallel.file15.file parallel@parallel-server2:/;ssh parallel@parallel-server2 cat\ /tmp/parallel.file15.file\ tmp/parallel.file14.file;_EXIT_status=$?; ssh parallel@parallel-server2 rm -f tmp/parallel.file14.file;ssh parallel@parallel-server2 rm -f /tmp/parallel.file15.file; exit $_EXIT_status; cat /tmp/parallel.file15.file tmp/parallel.file14.file
file15 file15
file14 file14
rsync -rlDzRE -essh ./tmp/parallel.file15.file parallel@parallel-server2:./;rsync -rlDzRE -essh /tmp/parallel.file14.file parallel@parallel-server2:/;ssh parallel@parallel-server2 cat\ /tmp/parallel.file14.file\ tmp/parallel.file15.file;_EXIT_status=$?; ssh parallel@parallel-server2 rm -f tmp/parallel.file15.file;ssh parallel@parallel-server2 rm -f /tmp/parallel.file14.file; exit $_EXIT_status; cat /tmp/parallel.file14.file tmp/parallel.file15.file
file14 file14
file15 file15
rsync -rlDzRE -essh ./tmp/parallel.file16.file parallel@parallel-server2:./;rsync -rlDzRE -essh /tmp/parallel.file13.file parallel@parallel-server2:/;ssh parallel@parallel-server2 cat\ /tmp/parallel.file13.file\ tmp/parallel.file16.file;_EXIT_status=$?; ssh parallel@parallel-server2 rm -f tmp/parallel.file16.file;ssh parallel@parallel-server2 rm -f /tmp/parallel.file13.file; exit $_EXIT_status; cat /tmp/parallel.file13.file tmp/parallel.file16.file
file13 file13
file16 file16
rsync -rlDzRE -essh ./tmp/parallel.file17.file parallel@parallel-server2:./;rsync -rlDzRE -essh /tmp/parallel.file10.file parallel@parallel-server2:/;ssh parallel@parallel-server2 cat\ /tmp/parallel.file10.file\ tmp/parallel.file17.file;_EXIT_status=$?; ssh parallel@parallel-server2 rm -f tmp/parallel.file17.file;ssh parallel@parallel-server2 rm -f /tmp/parallel.file10.file; exit $_EXIT_status; cat /tmp/parallel.file10.file tmp/parallel.file17.file
file10 file10
file17 file17
rsync -rlDzRE -essh ./tmp/parallel.file18.file parallel@parallel-server2:./;rsync -rlDzRE -essh /tmp/parallel.file1.file parallel@parallel-server2:/;ssh parallel@parallel-server2 cat\ /tmp/parallel.file1.file\ tmp/parallel.file18.file;_EXIT_status=$?; ssh parallel@parallel-server2 rm -f tmp/parallel.file18.file;ssh parallel@parallel-server2 rm -f /tmp/parallel.file1.file; exit $_EXIT_status; cat /tmp/parallel.file1.file tmp/parallel.file18.file
file1 file1
file18 file18
rsync -rlDzRE -essh ./tmp/parallel.file19.file parallel@parallel-server2:./;rsync -rlDzRE -essh /tmp/parallel.file/sub\ dir.file parallel@parallel-server2:/;ssh parallel@parallel-server2 cat\ /tmp/parallel.file/./sub\\\ dir.file\ tmp/parallel.file19.file;_EXIT_status=$?; ssh parallel@parallel-server2 rm -f tmp/parallel.file19.file;ssh parallel@parallel-server2 rm -f /tmp/parallel.file/./sub\\\ dir.file; exit $_EXIT_status; cat /tmp/parallel.file/./sub\ dir.file tmp/parallel.file19.file
file/./sub dir file/./sub dir
file19 file19
rsync -rlDzRE -essh ./tmp/parallel.file20.file parallel@parallel-server2:./;rsync -rlDzRE -essh /tmp/parallel.file\ :\ \&\ \)\ \\n\*.jpg.file parallel@parallel-server2:/;ssh parallel@parallel-server2 cat\ /tmp/parallel.file\\\ :\\\ \\\&\\\ \\\)\\\ \\\\n\\\*.jpg.file\ tmp/parallel.file20.file;_EXIT_status=$?; ssh parallel@parallel-server2 rm -f tmp/parallel.file20.file;ssh parallel@parallel-server2 rm -f /tmp/parallel.file\\\ :\\\ \\\&\\\ \\\)\\\ \\\\n\\\*.jpg.file; exit $_EXIT_status; cat /tmp/parallel.file\ :\ \&\ \)\ \\n\*.jpg.file tmp/parallel.file20.file
file : & ) \n*.jpg file : & ) \n*.jpg
file20 file20

View file

@ -75,30 +75,30 @@ OK
ls: cannot access tmp/parallel.file*: No such file or directory ls: cannot access tmp/parallel.file*: No such file or directory
OK OK
Input for ssh Input for ssh
parallel-server3 rsync --server -lDErRze.iLsf . ./ parallel-server3 rsync --server -lDErRze.iLsf . .
parallel-server3 cat tmp/parallel.file.' parallel-server3 PARALLEL_SEQ=2;export PARALLEL_SEQ;PARALLEL_PID=00000;export PARALLEL_PID; cat tmp/parallel.file.'
'newline2 > tmp/parallel.file.' 'newline2 > tmp/parallel.file.'
'newline2.out;cat tmp/parallel.file.' 'newline2.out;cat tmp/parallel.file.'
'newline2 > tmp/parallel.file.' 'newline2 > tmp/parallel.file.'
'newline2.out2 'newline2.out2
parallel-server3 rsync --server --sender -lDrRze.iLsf --remove-source-files . ./tmp/parallel.file.' parallel-server3 rsync --server --sender -lDrRze.iLsf --remove-source-files . ././tmp/parallel.file.'
'newline2.out 'newline2.out
parallel-server3 rsync --server --sender -lDrRze.iLsf --remove-source-files . ./tmp/parallel.file.' parallel-server3 rsync --server --sender -lDrRze.iLsf --remove-source-files . ././tmp/parallel.file.'
'newline2.out2 'newline2.out2
parallel-server3 rm -f tmp/parallel.file.' parallel-server3 rm -f tmp/parallel.file.'
'newline2 'newline2; rmdir 2>/dev/null ./tmp
-l parallel parallel-server2 rsync --server -lDErRze.iLsf . ./ -l parallel parallel-server2 rsync --server -lDErRze.iLsf . .
parallel@parallel-server2 cat tmp/parallel.file.' parallel@parallel-server2 PARALLEL_SEQ=1;export PARALLEL_SEQ;PARALLEL_PID=00000;export PARALLEL_PID; cat tmp/parallel.file.'
'newline1 > tmp/parallel.file.' 'newline1 > tmp/parallel.file.'
'newline1.out;cat tmp/parallel.file.' 'newline1.out;cat tmp/parallel.file.'
'newline1 > tmp/parallel.file.' 'newline1 > tmp/parallel.file.'
'newline1.out2 'newline1.out2
-l parallel parallel-server2 rsync --server --sender -lDrRze.iLsf --remove-source-files . ./tmp/parallel.file.' -l parallel parallel-server2 rsync --server --sender -lDrRze.iLsf --remove-source-files . ././tmp/parallel.file.'
'newline1.out 'newline1.out
-l parallel parallel-server2 rsync --server --sender -lDrRze.iLsf --remove-source-files . ./tmp/parallel.file.' -l parallel parallel-server2 rsync --server --sender -lDrRze.iLsf --remove-source-files . ././tmp/parallel.file.'
'newline1.out2 'newline1.out2
parallel@parallel-server2 rm -f tmp/parallel.file.' parallel@parallel-server2 rm -f tmp/parallel.file.'
'newline1 'newline1; rmdir 2>/dev/null ./tmp
### Test use special ssh with > 9 simultaneous ### Test use special ssh with > 9 simultaneous
1 1
2 2

View file

@ -1,11 +1,11 @@
### Test $PARALLEL ### Test $PARALLEL
1 1
ssh -l parallel parallel-server2 echo\ 1; ssh -l parallel parallel-server2 PARALLEL_SEQ=$PARALLEL_SEQ\;export PARALLEL_SEQ\;PARALLEL_PID=$PARALLEL_PID\;export PARALLEL_PID\; echo\ 1;
1 1
ssh parallel-server3 echo\ 2; ssh parallel-server3 PARALLEL_SEQ=$PARALLEL_SEQ\;export PARALLEL_SEQ\;PARALLEL_PID=$PARALLEL_PID\;export PARALLEL_PID\; echo\ 2;
2 2
### Test ~/.parallel/config ### Test ~/.parallel/config
ssh -l parallel parallel-server2 echo\ 1; ssh -l parallel parallel-server2 PARALLEL_SEQ=$PARALLEL_SEQ\;export PARALLEL_SEQ\;PARALLEL_PID=$PARALLEL_PID\;export PARALLEL_PID\; echo\ 1;
1 1
ssh parallel-server3 echo\ 2; ssh parallel-server3 PARALLEL_SEQ=$PARALLEL_SEQ\;export PARALLEL_SEQ\;PARALLEL_PID=$PARALLEL_PID\;export PARALLEL_PID\; echo\ 2;
2 2

View file

@ -0,0 +1,68 @@
### Test -W newtempdir/newdir/tmp/ with space dirs
echo >./\ ab/c\"d/ef\ g.6
echo >\ ab/c\"d/efg.6
echo >./b/bar.6
echo >./b/foo.6
echo >./\ ab\ /c\'\ d/\ ef\"g.6
echo >./2-col.txt.6
echo >./a\ b/cd\ /\ ef/efg.6
./ ab/c"d/ef g.6
./ ab/c"d/efg.6
./b/foo.6
./b/bar.6
./ ab /c' d/ ef"g.6
./a b/cd / ef/efg.6
./2-col.txt.6
### Test -W /tmp/newtempdir/newdir/tmp/ with space dirs
echo >./\ ab/c\"d/ef\ g.7
echo >\ ab/c\"d/efg.7
echo >./b/bar.7
echo >./b/foo.7
echo >./\ ab\ /c\'\ d/\ ef\"g.7
echo >./2-col.txt.7
echo >./a\ b/cd\ /\ ef/efg.7
./ ab/c"d/efg.7
./ ab/c"d/ef g.7
./2-col.txt.7
./b/bar.7
./b/foo.7
./ ab /c' d/ ef"g.7
./a b/cd / ef/efg.7
### Test --workdir ...
./2-col.txt.1
### Test -W ...
echo >2-col.txt.2
./2-col.txt.2
### Test -W ... with space dirs
echo >./\ ab/c\"d/ef\ g.3
echo >\ ab/c\"d/efg.3
echo >./b/bar.3
echo >./b/foo.3
echo >./\ ab\ /c\'\ d/\ ef\"g.3
echo >./2-col.txt.3
echo >./a\ b/cd\ /\ ef/efg.3
./ ab/c"d/ef g.3
./ ab/c"d/efg.3
./b/bar.3
./b/foo.3
./ ab /c' d/ ef"g.3
./2-col.txt.3
./a b/cd / ef/efg.3
### Test -W tmpdir
echo >2-col.txt.4
./2-col.txt.4
### Test -W /tmp/ with space dirs
echo >./\ ab/c\"d/ef\ g.5
echo >\ ab/c\"d/efg.5
echo >./b/bar.5
echo >./b/foo.5
echo >./\ ab\ /c\'\ d/\ ef\"g.5
echo >./2-col.txt.5
echo >./a\ b/cd\ /\ ef/efg.5
./2-col.txt.5
./ ab/c"d/ef g.5
./ ab/c"d/efg.5
./b/foo.5
./b/bar.5
./ ab /c' d/ ef"g.5
./a b/cd / ef/efg.5

View file

@ -0,0 +1,44 @@
### Test $PARALLEL_SEQ - local
arg1:1 seq:1 arg2:2
arg1:3 seq:2 arg2:4
arg1:5 seq:3 arg2:6
arg1:7 seq:4 arg2:8
arg1:9 seq:5 arg2:10
arg1:11 seq:6 arg2:12
arg1:13 seq:7 arg2:14
arg1:15 seq:8 arg2:16
arg1:17 seq:9 arg2:18
arg1:19 seq:10 arg2:20
### Test $PARALLEL_SEQ - remote
arg1:1 seq:1 arg2:2
arg1:3 seq:2 arg2:4
arg1:5 seq:3 arg2:6
arg1:7 seq:4 arg2:8
arg1:9 seq:5 arg2:10
arg1:11 seq:6 arg2:12
arg1:13 seq:7 arg2:14
arg1:15 seq:8 arg2:16
arg1:17 seq:9 arg2:18
arg1:19 seq:10 arg2:20
### Test $PARALLEL_PID - local
arg0:0 seq:00000 arg0:0
arg0:0 seq:00000 arg0:0
arg0:0 seq:00000 arg0:0
arg0:0 seq:00000 arg0:0
arg0:0 seq:00000 arg0:00
arg0:00 seq:00000 arg0:00
arg0:00 seq:00000 arg0:00
arg0:00 seq:00000 arg0:00
arg0:00 seq:00000 arg0:00
arg0:00 seq:00000 arg0:00
### Test $PARALLEL_PID - remote
arg0:0 seq:00000 arg0:0
arg0:0 seq:00000 arg0:0
arg0:0 seq:00000 arg0:0
arg0:0 seq:00000 arg0:0
arg0:0 seq:00000 arg0:00
arg0:00 seq:00000 arg0:00
arg0:00 seq:00000 arg0:00
arg0:00 seq:00000 arg0:00
arg0:00 seq:00000 arg0:00
arg0:00 seq:00000 arg0:00