#48818 In docker, setup-ds.pl hangs indefinetly
Closed: wontfix None Opened 4 years ago by firstyear.

Docker starts the first process as pid 1. But pid 1 is special. It's meant to clean up zombies (defunct) processes.

However, our perl code in setup-ds.pl, when we called $startcmd, the start-dirsrv process was being left defucnt.

Issue is, that because it's defunct, the pid exists, as do the fds. Perl never returns. Our tests all fail, and setup-ds.pl hangs.

To fix this, we need to implement the process reaping capability of pid 1 into part of our perl code.


First, I thought it might be nicer to keep this debug message in the else of "if ($code)" clause.

debug(1, "Started the server: code $code\n");

But anyway we have no way to print the debug messages for now? (I could not find it... Do you happen to know how to?) So, I guess we don't have to worry about losing the message or sacrificing output collection? ;)

I tried really really hard to get message output to work, but it causes issues. Because the fd isn't closed, anything that reads from the output blocks and hangs, so waitpid never is called. This means the child stays defunct, and everything still hangs. :(

commit a16da9c
Total 7 (delta 5), reused 0 (delta 0)
To ssh://git.fedorahosted.org/git/389/ds.git
83d57ee..a16da9c master -> master

Thanks for getting this fixed! Ack

commit cbb8bf4
Total 19 (delta 14), reused 0 (delta 0)
To ssh://git.fedorahosted.org/git/389/ds.git
0e4b061..cbb8bf4 master -> master

Metadata Update from @firstyear:
- Issue assigned to firstyear
- Issue set to the milestone: 1.3.5 eval

3 years ago

389-ds-base is moving from Pagure to Github. This means that new issues and pull requests
will be accepted only in 389-ds-base's github repository.

This issue has been cloned to Github and is available here:
- https://github.com/389ds/389-ds-base/issues/1878

If you want to receive further updates on the issue, please navigate to the github issue
and click on subscribe button.

Thank you for understanding. We apologize for all inconvenience.

Metadata Update from @spichugi:
- Issue close_status updated to: wontfix (was: Fixed)

3 months ago

Login to comment on this ticket.

Metadata