You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@trafficcontrol.apache.org by zhilhuan <gi...@git.apache.org> on 2017/01/04 03:58:15 UTC

[GitHub] incubator-trafficcontrol pull request #155: [TC-83] make sure parent process...

GitHub user zhilhuan opened a pull request:

    https://github.com/apache/incubator-trafficcontrol/pull/155

    [TC-83] make sure parent process will wait child exit before fork

    In every 5 minutes, "GET /internal/api/1.2/cdns/dnsseckeys/refresh.json" will be triggered, and code in "sub dnssec_keys_refresh" will call "$self->daemonize();".
    
    Code in "daemonize()" will make "$SIG{CHLD} = 'IGNORE';", which causes child process automatically reaped. And "wait" in parent process will fail with return code -1.
    
    And traffic_ops have a group of child processes to process UI/API http requests. So after several hours almost all those child processes will set CHLD handler to "IGNORE". Issue TC-83 will be triggered then.

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/zhilhuan/incubator-trafficcontrol TC-83

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/incubator-trafficcontrol/pull/155.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #155
    
----
commit 5f7c2015de52754ad88851bead757aae48ef49f1
Author: Zhilin Huang <zh...@cisco.com>
Date:   2017-01-04T03:53:45Z

    make sure parent process will wait child exit before fork

----


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] incubator-trafficcontrol pull request #155: [TC-83] make sure parent process...

Posted by asfgit <gi...@git.apache.org>.
Github user asfgit closed the pull request at:

    https://github.com/apache/incubator-trafficcontrol/pull/155


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] incubator-trafficcontrol issue #155: [TC-83] make sure parent process will w...

Posted by zhilhuan <gi...@git.apache.org>.
Github user zhilhuan commented on the issue:

    https://github.com/apache/incubator-trafficcontrol/pull/155
  
    @dneuman64 We are running TC 1.7. And in "cdn.conf", we have "workers => 96,".
    
    BTW, from the latest code in master, using "git grep CHLD", I still could only find "$SIG{CHLD} = 'IGNORE';" in app/lib/MojoPlugins/Daemonize.pm.
    
    And if I am understanding this right, "GET /internal/api/1.2/cdns/dnsseckeys/refresh.json" regularly will cause a worker to set handler for signal CHLD to 'ignore'. So after a long time, every worker will ignore signal CHLD. This will cause "wait()" in a worker process fail if a forked child already reaped automatically.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] incubator-trafficcontrol issue #155: [TC-83] make sure parent process will w...

Posted by dneuman64 <gi...@git.apache.org>.
Github user dneuman64 commented on the issue:

    https://github.com/apache/incubator-trafficcontrol/pull/155
  
    What version of Traffic Ops are you running when you see this issue?  Also, how many "workers" do you have configured in traffic_ops/app/conf/cdn.conf?  I do not think we are currently seeing this issue, although we did see this issue in much older versions of TO.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---