summaryrefslogtreecommitdiffstats
path: root/urpm
diff options
context:
space:
mode:
Diffstat (limited to 'urpm')
-rw-r--r--urpm/parallel.pm3
-rw-r--r--urpm/parallel_ka_run.pm1
-rw-r--r--urpm/parallel_ssh.pm6
3 files changed, 8 insertions, 2 deletions
diff --git a/urpm/parallel.pm b/urpm/parallel.pm
index 32ff587a..4c44c55d 100644
--- a/urpm/parallel.pm
+++ b/urpm/parallel.pm
@@ -212,11 +212,12 @@ sub parallel_resolve_dependencies {
#- the following state should be cleaned for each iteration.
delete $state->{selected};
#- now try an iteration of urpmq.
- $parallel->urpm_popen($urpm, 'urpmq', "--synthesis $synthesis -fmc $line " . join(' ', keys %chosen), sub {
+ my @errors = $parallel->urpm_popen($urpm, 'urpmq', "--synthesis $synthesis -fmc $line " . join(' ', keys %chosen), sub {
my ($node, $s) = @_;
_parse_urpmq_output($urpm, $state, $node, $s, \$cont, \%chosen, %options);
undef;
});
+ @errors and $urpm->{fatal}(1, join("\n", @errors));
#- check for internal error of resolution.
$cont == 1 and die "internal distant urpmq error on choice not taken";
} while $cont;
diff --git a/urpm/parallel_ka_run.pm b/urpm/parallel_ka_run.pm
index c6dfd465..28102e38 100644
--- a/urpm/parallel_ka_run.pm
+++ b/urpm/parallel_ka_run.pm
@@ -56,6 +56,7 @@ sub urpm_popen {
$do->($node, $s_) and last;
}
close $fh or $urpm->{fatal}(1, N("rshp failed, maybe a node is unreacheable"));
+ ();
}
sub run_urpm_command {
diff --git a/urpm/parallel_ssh.pm b/urpm/parallel_ssh.pm
index d3b29570..23af44cc 100644
--- a/urpm/parallel_ssh.pm
+++ b/urpm/parallel_ssh.pm
@@ -73,6 +73,8 @@ sub _ssh_urpm_popen {
sub urpm_popen {
my ($parallel, $urpm, $cmd, $para, $do) = @_;
+ my @errors;
+
foreach my $node (keys %{$parallel->{nodes}}) {
my $fh = _ssh_urpm_popen($urpm, $node, $cmd, $para);
@@ -81,9 +83,11 @@ sub urpm_popen {
$urpm->{debug}("parallel_ssh: $node: received: $s") if $urpm->{debug};
$do->($node, $s) and last;
}
- close $fh or $urpm->{fatal}(1, N("host %s does not have a good version of urpmi (%d)", $node, $? >> 8));
+ close $fh or push @errors, N("%s failed on host %s (maybe it does not have a good version of urpmi?) (exit code: %d)", $cmd, $node, $? >> 8);
$urpm->{debug}("parallel_ssh: $node: $cmd finished") if $urpm->{debug};
}
+
+ @errors;
}
sub run_urpm_command {