Running jobs in parallel on Ubuntu - I/O contention differences between Perl and Java

view full story

http://unix.stackexchange.com – Apologies if this is off topic - it concerns the relative efficiencies of running I/O-heavy Perl/Java scripts in parallel on a Ubuntu system. I have written two simple versions of a file copy script (Perl and Java) - see below. When I run the scripts on a 15GB file, each takes a similar amount of time on a 48-core machine running Ubuntu Server 12.04 (perl 2m10s, java 2m27s). However, when I run six instances in parallel, each operating on a different 15GB input file, I observe very different processing times: Perl: one instance completes in 2m6s, all others take 27m26s - 28m10s. Java: all (HowTos)