parallel: Maybe fixed bug #41038: loadavg_file-r

This commit is contained in:
Ole Tange 2013-12-31 16:28:30 +01:00
parent 045f534475
commit b73488d761
5 changed files with 18 additions and 13 deletions

2
NEWS
View file

@ -8,7 +8,7 @@
* --keep-order --(n)onall will sort according to the sshlogin.
* Detection number of CPUs on DEC Tru64.
* Detect the number of CPUs on DEC Tru64.
* GNU sql: --list-tables for sqlite3.

View file

@ -204,9 +204,9 @@ cc:Sandro Cazzaniga <kharec@mandriva.org>,
Ryoichiro Suzuki <ryoichiro.suzuki@gmail.com>,
Jesse Alama <jesse.alama@gmail.com>
Subject: GNU Parallel 20131222 (玉兔 Mandela) released
Subject: GNU Parallel 20131222 ('玉兔 Mandela') released
GNU Parallel 20131222 (玉兔 Mandela) has been released. It is
GNU Parallel 20131222 ('玉兔 Mandela') has been released. It is
available for download at: http://ftp.gnu.org/gnu/parallel/
New in this release:

View file

@ -1,6 +1,6 @@
#!/usr/bin/env perl
# Copyright (C) 2007,2008,2009,2010,2011,2012,2013 Ole Tange and Free Software
# Copyright (C) 2007,2008,2009,2010,2011,2012,2013,2014 Ole Tange and Free Software
# Foundation, Inc.
#
# This program is free software; you can redistribute it and/or modify
@ -625,7 +625,7 @@ sub get_options_from_array {
sub parse_options {
# Returns: N/A
# Defaults:
$Global::version = 20131222;
$Global::version = 20140102;
$Global::progname = 'parallel';
$Global::infinity = 2**31;
$Global::debug = 0;
@ -2332,7 +2332,7 @@ sub usage {
"",
"See 'man $Global::progname' for details",
"",
"When using GNU Parallel for a publication please cite:",
"When using programs that use GNU Parallel to process data for publication please cite:",
"",
"O. Tange (2011): GNU Parallel - The Command-Line Power Tool,",
";login: The USENIX Magazine, February 2011:42-47.",
@ -2406,13 +2406,13 @@ sub version {
}
print join("\n",
"GNU $Global::progname $Global::version",
"Copyright (C) 2007,2008,2009,2010,2011,2012,2013 Ole Tange and Free Software Foundation, Inc.",
"Copyright (C) 2007,2008,2009,2010,2011,2012,2013,2014 Ole Tange and Free Software Foundation, Inc.",
"License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>",
"This is free software: you are free to change and redistribute it.",
"GNU $Global::progname comes with no warranty.",
"",
"Web site: http://www.gnu.org/software/${Global::progname}\n",
"When using GNU Parallel for a publication please cite:\n",
"When using programs that use GNU Parallel to process data for publication please cite:\n",
"O. Tange (2011): GNU Parallel - The Command-Line Power Tool, ",
";login: The USENIX Magazine, February 2011:42-47.\n",
);
@ -2905,9 +2905,7 @@ sub loadavg {
my $self = shift;
# Should we update the loadavg file?
my $update_loadavg_file = 0;
if(-r $self->{'loadavg_file'}) {
open(my $load_fh, "<", $self->{'loadavg_file'}) ||
::die_bug("loadavg_file-r: ".$self->{'loadavg_file'});
if(open(my $load_fh, "<", $self->{'loadavg_file'})) {
local $/ = undef;
my $load_out = <$load_fh>;
close $load_fh;

View file

@ -2,9 +2,9 @@
P_ALL="vax freebsd solaris openbsd netbsd debian alpha aix redhat hpux ultrix qnx irix tru64 openindiana suse openstep mandriva ubuntu scosysv unixware dragonfly centos miros hurd raspberrypi"
P_NOTWORKING="vax alpha openstep"
P_NOTWORKING_YET="ultrix tru64 irix minix raspberrypi"
P_NOTWORKING_YET="ultrix irix minix"
P_WORKING="freebsd solaris openbsd netbsd debian aix redhat hpux qnx openindiana suse mandriva ubuntu scosysv unixware dragonfly centos miros hurd"
P_WORKING="freebsd solaris openbsd netbsd debian aix redhat hpux qnx tru64 openindiana suse mandriva ubuntu scosysv unixware dragonfly centos miros hurd raspberrypi"
P="$P_WORKING"
POLAR=`parallel -k echo {}.polarhome.com ::: $P`

View file

@ -28,6 +28,9 @@ copy_and_test qnx.polarhome.com
qnx.polarhome.com ### Run the test on qnx.polarhome.com
qnx.polarhome.com Works on qnx.polarhome.com
qnx.polarhome.com parallel: Warning: Cannot figure out number of CPU cores. Using 1.
copy_and_test tru64.polarhome.com
tru64.polarhome.com ### Run the test on tru64.polarhome.com
tru64.polarhome.com Works on tru64.polarhome.com
copy_and_test openindiana.polarhome.com
openindiana.polarhome.com ### Run the test on openindiana.polarhome.com
openindiana.polarhome.com Works on openindiana.polarhome.com
@ -59,3 +62,7 @@ miros.polarhome.com Works on miros.polarhome.com
copy_and_test hurd.polarhome.com
hurd.polarhome.com ### Run the test on hurd.polarhome.com
hurd.polarhome.com Works on hurd.polarhome.com
copy_and_test raspberrypi.polarhome.com
raspberrypi.polarhome.com ### Run the test on raspberrypi.polarhome.com
raspberrypi.polarhome.com Works on raspberrypi.polarhome.com
raspberrypi.polarhome.com parallel: Warning: Cannot figure out number of CPU cores. Using 1.