April 12, 2018 Spurious error: Process does not exist or is not a child process. | ||||
---|---|---|---|---|
| ||||
Hi, I compiled a linux application on my pc (Windows subsystem for Linux) and copied it to AWS EMR (linux) system. The application should execute the console application "aws". Most of the time the exception "Process does not exist or is not a child process." is raised. If I execute the application a second later, the error is not thrown. The command hardcoded: auto aws = executeShell(`aws sqs get-queue-url --cli-input-json "file:///tmp/awsd2159b505cfc4c0ab1a80a53b7d9999d.json" --no-paginate --output json --cli-read-timeout 10 --cli-connect-timeout 10 --region eu-central-1`); ??:? @trusted int std.process.Pid.performWait(bool) [0x737247] ??:? @safe int std.process.wait(std.process.Pid) [0x780b71] ??:? std.typecons.Tuple!(int, "status", immutable(char)[], "output").Tuple std.process.executeImpl!(std.process.pipeShell(const(char[]), std.process.Redirect, const(immutable(char)[][immutable(char)[]]), std.process.Config, const(char[]), immutable(char)[]), const(char)[], immutable(char)[]).executeImpl(const(char)[], const(immutable(char)[][immutable(char)[]]), std.process.Config, ulong, const(char[]), immutable(char)[]) [0x737de5] ??:? @trusted std.typecons.Tuple!(int, "status", immutable(char)[], "output").Tuple std.process.executeShell(const(char[]), const(immutable(char)[][immutable(char)[]]), std.process.Config, ulong, const(char[]), immutable(char)[]) [0x737356] dependencies/aws-sdk-0.0.5/core/aws/sdk/core/client.d:126 immutable(char)[] aws.sdk.core.client.AwsClient.executeRaw(immutable(char)[]) [0x63ee58] Can you think of any reason why the executeShell function sometimes works and sometimes not? Kind regards André |
April 12, 2018 Re: Spurious error: Process does not exist or is not a child process. | ||||
---|---|---|---|---|
| ||||
Posted in reply to Andre Pany | On Thursday, 12 April 2018 at 06:45:36 UTC, Andre Pany wrote:
> Hi,
>
> I compiled a linux application on my pc (Windows subsystem for Linux) and copied it to AWS EMR (linux) system.
>
I found the issue. In addition to the AWS client I also start other applications which might
become zombie processes. For these processes I added this coding:
signal(SIGCHLD, &handleSigChld);
extern (C) void handleSigChld(int sig) nothrow @nogc @system
{
import core.sys.posix.sys.wait : waitpid, WNOHANG;
int status;
waitpid(-1, &status, WNOHANG);
}
But this coding has a bad influence on the AWS client causing spurious exceptions.
Kind regards
André
|
Copyright © 1999-2021 by the D Language Foundation