[pve-devel] applied: [PATCH common] daemon: fix send termination to all workers on exit
Wolfgang Bumiller
w.bumiller at proxmox.com
Mon Nov 20 14:23:51 CET 2017
applied
On Fri, Nov 17, 2017 at 02:05:48PM +0100, Thomas Lamprecht wrote:
> The hash slice did not work as intented here, it only return the keys
> from the last elemend defined in the slice, thus not all workers got
> a TERM.
>
> Signed-off-by: Thomas Lamprecht <t.lamprecht at proxmox.com>
> ---
> src/PVE/Daemon.pm | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/src/PVE/Daemon.pm b/src/PVE/Daemon.pm
> index 9e03c80..dcc4d34 100644
> --- a/src/PVE/Daemon.pm
> +++ b/src/PVE/Daemon.pm
> @@ -201,7 +201,7 @@ my $terminate_server = sub {
> return if $allow_open_children && $self->{leave_children_open_on_reload};
>
> # else send TERM to all (old and current) child workers
> - kill 15, keys %{$self->@{'workers','old_workers'}};
> + kill 15, (keys %{$self->{workers}}, keys %{$self->{old_workers}});
>
> # nicely shutdown childs (give them max 10 seconds to shut down)
> my $previous_alarm = alarm(10);
> --
> 2.11.0
More information about the pve-devel
mailing list