Re: Changes to job handling cause hangs in wait

2020-12-06 Thread Herbert Xu
On Thu, Dec 03, 2020 at 01:27:51PM +0100, Michael Biebl wrote: > > Hm, so I applied this change and switched backed to dash, but now I get > > autopkgtest systemd --test-name=timedated -s -- lxc -s autopkgtest-sid > ... > disable NTP > enable NTP > Terminated > autopkgtest [13:21:42]: test timedat

Re: Changes to job handling cause hangs in wait

2020-12-03 Thread Michael Biebl
Am 01.12.20 um 07:56 schrieb Herbert Xu: On Tue, Dec 01, 2020 at 05:06:18PM +1100, Herbert Xu wrote: For some reason this is causing the final two tee's to be created as children of debian/tests/timedated rather than the bash shell. An alternative to changing the parent is of course to do

Re: Changes to job handling cause hangs in wait

2020-12-03 Thread Michael Biebl
Am 02.12.20 um 00:26 schrieb Herbert Xu: On Wed, Dec 02, 2020 at 12:21:52AM +0100, Michael Biebl wrote: I'll update the timedated test accordingly. Incidentally we already have https://salsa.debian.org/systemd-team/systemd/-/merge_requests/110 Thanks. Hm, so I applied this change and switch

Re: Changes to job handling cause hangs in wait

2020-12-01 Thread Herbert Xu
On Wed, Dec 02, 2020 at 12:21:52AM +0100, Michael Biebl wrote: > > I'll update the timedated test accordingly. > Incidentally we already have > https://salsa.debian.org/systemd-team/systemd/-/merge_requests/110 Thanks. I will make dash not wait for existing children as this is indeed a change in

Re: Changes to job handling cause hangs in wait

2020-12-01 Thread Michael Biebl
Am 01.12.20 um 07:56 schrieb Herbert Xu: On Tue, Dec 01, 2020 at 05:06:18PM +1100, Herbert Xu wrote: For some reason this is causing the final two tee's to be created as children of debian/tests/timedated rather than the bash shell. An alternative to changing the parent is of course to do

Re: Changes to job handling cause hangs in wait

2020-12-01 Thread Michael Biebl
Am 01.12.20 um 11:53 schrieb Herbert Xu: On Tue, Dec 01, 2020 at 10:50:19AM +, Harald van Dijk wrote: This used to exit immediately, leaving the sleep process running in the background without waiting for it. On the dash that's currently provided by Ubuntu, based on 0.5.10.2, it still behav

Re: Changes to job handling cause hangs in wait

2020-12-01 Thread Herbert Xu
On Tue, Dec 01, 2020 at 10:59:20AM +, Harald van Dijk wrote: > > I do not appreciate your false accusation that I did not read your follow-up > email. You suggested that as an alternative, without retracting your claim > that this is a problem in bash. Well I'm not accusing you of anything, I

Re: Changes to job handling cause hangs in wait

2020-12-01 Thread Harald van Dijk
On 01/12/2020 10:56, Herbert Xu wrote: On Tue, Dec 01, 2020 at 10:55:06AM +, Harald van Dijk wrote: You wrote: "So the problem is really in the parent of this shell, which appears to be bash:" You should read my follow-up email too that suggested changing the systemd script. I do not ap

Re: Changes to job handling cause hangs in wait

2020-12-01 Thread Herbert Xu
On Tue, Dec 01, 2020 at 10:55:06AM +, Harald van Dijk wrote: > > You wrote: "So the problem is really in the parent of this shell, which > appears to be bash:" You should read my follow-up email too that suggested changing the systemd script. Cheers, -- Email: Herbert Xu Home Page: http://

Re: Changes to job handling cause hangs in wait

2020-12-01 Thread Harald van Dijk
On 01/12/2020 10:53, Herbert Xu wrote: On Tue, Dec 01, 2020 at 10:50:19AM +, Harald van Dijk wrote: This used to exit immediately, leaving the sleep process running in the background without waiting for it. On the dash that's currently provided by Ubuntu, based on 0.5.10.2, it still behaves

Re: Changes to job handling cause hangs in wait

2020-12-01 Thread Herbert Xu
On Tue, Dec 01, 2020 at 10:50:19AM +, Harald van Dijk wrote: > > This used to exit immediately, leaving the sleep process running in the > background without waiting for it. On the dash that's currently provided by > Ubuntu, based on 0.5.10.2, it still behaves that way. With current dash from

Re: Changes to job handling cause hangs in wait

2020-12-01 Thread Harald van Dijk
On 01/12/2020 10:34, Herbert Xu wrote: On Tue, Dec 01, 2020 at 10:14:04AM +, Harald van Dijk wrote: POSIX says: "If the wait utility is invoked with no operands, it shall wait until all process IDs known to the invoking shell have terminated and exit with a zero exit status." I would

Re: Changes to job handling cause hangs in wait

2020-12-01 Thread Herbert Xu
On Tue, Dec 01, 2020 at 10:14:04AM +, Harald van Dijk wrote: > > POSIX says: > > "If the wait utility is invoked with no operands, it shall wait until > all process IDs known to the invoking shell have terminated and exit with a > zero exit status." > > I would say that child processes t

Re: Changes to job handling cause hangs in wait

2020-12-01 Thread Harald van Dijk
On 01/12/2020 06:06, Herbert Xu wrote: On Tue, Dec 01, 2020 at 04:42:03PM +1100, Herbert Xu wrote: Nevermind, I see that the script has been modified to use bash. I can reproduce the problem now so it's all good. OK the problem is this: sh -c 'sleep 1d& exec $MYSHELL -c "sleep 1& wa

Re: Changes to job handling cause hangs in wait

2020-11-30 Thread Herbert Xu
On Tue, Dec 01, 2020 at 05:06:18PM +1100, Herbert Xu wrote: > > For some reason this is causing the final two tee's to be created > as children of debian/tests/timedated rather than the bash shell. An alternative to changing the parent is of course to do wait $MONPID instead of

Re: Changes to job handling cause hangs in wait

2020-11-30 Thread Herbert Xu
On Tue, Dec 01, 2020 at 04:42:03PM +1100, Herbert Xu wrote: > > Nevermind, I see that the script has been modified to use bash. > > I can reproduce the problem now so it's all good. OK the problem is this: sh -c 'sleep 1d& exec $MYSHELL -c "sleep 1& wait"' You can replace MYSHELL with w

Re: Changes to job handling cause hangs in wait

2020-11-30 Thread Herbert Xu
On Tue, Dec 01, 2020 at 04:38:37PM +1100, Herbert Xu wrote: > > FWIW I'm unable to reproduce it with autopkgtest. This is what > I get: > > root@test0:~# autopkgtest --test-name=timedated systemd-246.6/ -B -- lxc -s > autopkgtest-sid > autopkgtest [16:32:45]: starting date: 2020-12-01 > autopkg

Re: Changes to job handling cause hangs in wait

2020-11-30 Thread Herbert Xu
On Mon, Nov 16, 2020 at 10:29:16AM +, Andrej Shadura wrote: > > I’d like to forward a bug report I received. Michael, who reported it, > was able to bisect it to 6c691b3, which was the first of the series of > commits changing job handling. > > I must note that I had troubles debugging it: I

Re: Changes to job handling cause hangs in wait

2020-11-16 Thread Herbert Xu
On Mon, Nov 16, 2020 at 10:29:16AM +, Andrej Shadura wrote: > > I must note that I had troubles debugging it: I was only able to > reproduce the issue in an autopkgtest virtual machine, but not on my > normal system nor in a fresh Debian unstable Docker container. Since you can reproduce it, c

Changes to job handling cause hangs in wait

2020-11-16 Thread Andrej Shadura
Hi, I’d like to forward a bug report I received. Michael, who reported it, was able to bisect it to 6c691b3, which was the first of the series of commits changing job handling. I must note that I had troubles debugging it: I was only able to reproduce the issue in an autopkgtest virtual machine,