Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Shelling out to kill is fragile and should be avoided #3128

Open
knarz opened this issue Aug 7, 2019 · 3 comments

Comments

@knarz
Copy link

commented Aug 7, 2019

The crash message:


  Please:
    Open an issue:
      https://github.com/CodaProtocol/coda/issues/new

    Briefly describe what you were doing, and include the last 20 lines from .coda-config/coda.log.
    And then paste the following:

    (monitor.ml.Error
  (Unix.Unix_error "No such file or directory" Core.Unix.create_process
    "((prog kill) (args (124)) (env (Extend ())))")
  ("Raised at file \"src/error.ml\" (inlined), line 9, characters 14-30"
    "Called from file \"src/or_error.ml\", line 72, characters 17-32"
    "Called from file \"src/deferred1.ml\", line 17, characters 40-45"
    "Called from file \"src/job_queue.ml\" (inlined), line 131, characters 2-5"
    "Called from file \"src/job_queue.ml\", line 170, characters 6-47"
    "Caught by monitor coda"))

coda.log content:

{"timestamp":"2019-08-07 20:29:26.184840Z","level":"Trace","source":{"module":"Gossip_net","location":"File \"lib/gossip_net/gossip_net.ml\", line 473, characters 71-78"},"message":"broadcasting message","metadata":{"pid":7}}
{"timestamp":"2019-08-07 20:29:26.221708Z","level":"Debug","source":{"module":"Trust_system__Peer_trust","location":"File \"lib/trust_system/peer_trust.ml\", line 120, characters 56-63"},"message":"Decreasing trust for peer $peer due to action Trust_system.Actions.Sent_old_gossip. New trust is 0.000006.","metadata":{"peer":"52.53.238.133","pid":7}}
{"timestamp":"2019-08-07 20:29:26.221940Z","level":"Debug","source":{"module":"Network_pool__Network_pool_base","location":"File \"lib/network_pool/network_pool_base.ml\", line 32, characters 60-67"},"message":"Pool diff apply feedback: no useful transactions","metadata":{"pid":7}}
{"timestamp":"2019-08-07 20:29:26.235287Z","level":"Debug","source":{"module":"Trust_system__Peer_trust","location":"File \"lib/trust_system/peer_trust.ml\", line 120, characters 56-63"},"message":"Decreasing trust for peer $peer due to action Trust_system.Actions.Sent_old_gossip. New trust is 0.000021.","metadata":{"peer":"52.33.52.99","pid":7}}
{"timestamp":"2019-08-07 20:29:26.235602Z","level":"Debug","source":{"module":"Network_pool__Network_pool_base","location":"File \"lib/network_pool/network_pool_base.ml\", line 32, characters 60-67"},"message":"Pool diff apply feedback: no useful transactions","metadata":{"pid":7}}
{"timestamp":"2019-08-07 20:29:26.249760Z","level":"Debug","source":{"module":"Trust_system__Peer_trust","location":"File \"lib/trust_system/peer_trust.ml\", line 120, characters 56-63"},"message":"Decreasing trust for peer $peer due to action Trust_system.Actions.Sent_old_gossip. New trust is 0.000033.","metadata":{"peer":"54.188.108.191","pid":7}}
{"timestamp":"2019-08-07 20:29:26.249930Z","level":"Debug","source":{"module":"Network_pool__Network_pool_base","location":"File \"lib/network_pool/network_pool_base.ml\", line 32, characters 60-67"},"message":"Pool diff apply feedback: no useful transactions","metadata":{"pid":7}}
{"timestamp":"2019-08-07 20:29:26.268336Z","level":"Debug","source":{"module":"Trust_system__Peer_trust","location":"File \"lib/trust_system/peer_trust.ml\", line 120, characters 56-63"},"message":"Decreasing trust for peer $peer due to action Trust_system.Actions.Sent_old_gossip. New trust is 0.000008.","metadata":{"peer":"54.184.87.39","pid":7}}
{"timestamp":"2019-08-07 20:29:26.268503Z","level":"Debug","source":{"module":"Network_pool__Network_pool_base","location":"File \"lib/network_pool/network_pool_base.ml\", line 32, characters 60-67"},"message":"Pool diff apply feedback: no useful transactions","metadata":{"pid":7}}
{"timestamp":"2019-08-07 20:29:26.285923Z","level":"Debug","source":{"module":"Trust_system__Peer_trust","location":"File \"lib/trust_system/peer_trust.ml\", line 120, characters 56-63"},"message":"Decreasing trust for peer $peer due to action Trust_system.Actions.Sent_old_gossip. New trust is 0.000049.","metadata":{"peer":"54.149.124.61","pid":7}}
{"timestamp":"2019-08-07 20:29:26.286231Z","level":"Debug","source":{"module":"Network_pool__Network_pool_base","location":"File \"lib/network_pool/network_pool_base.ml\", line 32, characters 60-67"},"message":"Pool diff apply feedback: no useful transactions","metadata":{"pid":7}}
{"timestamp":"2019-08-07 20:29:26.385732Z","level":"Debug","source":{"module":"Trust_system__Peer_trust","location":"File \"lib/trust_system/peer_trust.ml\", line 120, characters 56-63"},"message":"Decreasing trust for peer $peer due to action Trust_system.Actions.Sent_old_gossip. New trust is 0.000019.","metadata":{"peer":"54.193.108.137","pid":7}}
{"timestamp":"2019-08-07 20:29:26.385865Z","level":"Debug","source":{"module":"Network_pool__Network_pool_base","location":"File \"lib/network_pool/network_pool_base.ml\", line 32, characters 60-67"},"message":"Pool diff apply feedback: no useful transactions","metadata":{"pid":7}}
{"timestamp":"2019-08-07 20:29:27.895808Z","level":"Debug","source":{"module":"Trust_system__Peer_trust","location":"File \"lib/trust_system/peer_trust.ml\", line 120, characters 56-63"},"message":"Decreasing trust for peer $peer due to action Trust_system.Actions.Connected. New trust is 0.000008.","metadata":{"peer":"54.184.87.39","pid":7}}
{"timestamp":"2019-08-07 20:29:27.963310Z","level":"Debug","source":{"module":"Trust_system__Peer_trust","location":"File \"lib/trust_system/peer_trust.ml\", line 120, characters 56-63"},"message":"Decreasing trust for peer $peer due to action Trust_system.Actions.Connected. New trust is 0.000032.","metadata":{"peer":"54.188.108.191","pid":7}}
{"timestamp":"2019-08-07 20:29:27.973336Z","level":"Debug","source":{"module":"Trust_system__Peer_trust","location":"File \"lib/trust_system/peer_trust.ml\", line 120, characters 56-63"},"message":"Decreasing trust for peer $peer due to action Trust_system.Actions.Connected. New trust is 0.000006.","metadata":{"peer":"52.53.238.133","pid":7}}
{"timestamp":"2019-08-07 20:29:28.242982Z","level":"Debug","source":{"module":"Trust_system__Peer_trust","location":"File \"lib/trust_system/peer_trust.ml\", line 120, characters 56-63"},"message":"Increasing trust for peer $peer due to action Trust_system.Actions.Sent_useful_gossip ($cmd). New trust is 0.000012.","metadata":{"cmd":{"payload":{"common":{"fee":5,"nonce":"3","memo":"2pmu64f2x97tNiDXMycnLwBSECDKbX77MTXVWVsG8hcRFsedhXDWWq"},"body":["Payment",{"receiver":"CfJpEumzrhtqsLBw2hJeE8sc9Tpeii5xAynrtvYeuYNqeU7waThkFnijJa5v5kWf1w7KS7FNkXA1hyPXRZQCnUe7Xuk8hH54esMDXhyEiGHuxEWvbgLnXJTnJkM7xg5PbyQXso9xk6TyJ","amount":20}]},"sender":"JzXj6kK5m3HYvtvecLFt26mkMqFxSvvt9uJMwVjPVmZ76aVo6Qh3W1ELw8Eid63pYGiVU2yEc18LCe6r9akvRx72pqAVFzU2fLPHRDnSw1R7ysexL7BfRxk9rLQkhdAkQPFvhAdq3Sc3wrryQEU9JZ9gLrAtAgGwXVCdM7xb7cgpCFQoAP4BCYtjAC2fNUQf5n3eYkuVmfQsFPVur7Ani3j4KTADdrcz135kYWMTtsEE5sRw5mhepmLuF9kRJHktDTMNwaPvVarnZaGE","signature":"EXQ8XhSnNt542kR7jvDgWbs3veW2stnTZqUMPNVoiqoiztGrR6km6bz2tiMDpiHLMcnQVQmmToghAXH4fads1eZ1UScftDs6LFrj4onLK5ezxdhi2Xqtruc7udbYzR7TFi3iYVqo6DUfR7FFkLxFQ4UwaZBXfjppRSWfDVPiSiV7uJVr6MEkvsiztLDhPT8udeDtp1L2m29JyhHZRaVmRSwfZTcJQ9X6BxBUKTnMTb2JLAaPzupoAoggXUVt2ZXw7wpZaicDtQZfeH12"},"peer":"54.184.87.39","pid":7}}
{"timestamp":"2019-08-07 20:29:28.243174Z","level":"Trace","source":{"module":"Network_pool__Network_pool_base","location":"File \"lib/network_pool/network_pool_base.ml\", line 27, characters 60-67"},"message":"Broadcasting Transaction diff of length 1","metadata":{"pid":7}}
{"timestamp":"2019-08-07 20:29:28.247674Z","level":"Trace","source":{"module":"Coda_networking","location":"File \"lib/coda_networking/coda_networking.ml\", line 649, characters 56-63"},"message":"Broadcasting transaction pool diff over gossip net","metadata":{"message":["Transaction_pool_diff",[{"payload":{"common":{"fee":5,"nonce":"3","memo":"2pmu64f2x97tNiDXMycnLwBSECDKbX77MTXVWVsG8hcRFsedhXDWWq"},"body":["Payment",{"receiver":"CfJpEumzrhtqsLBw2hJeE8sc9Tpeii5xAynrtvYeuYNqeU7waThkFnijJa5v5kWf1w7KS7FNkXA1hyPXRZQCnUe7Xuk8hH54esMDXhyEiGHuxEWvbgLnXJTnJkM7xg5PbyQXso9xk6TyJ","amount":20}]},"sender":"JzXj6kK5m3HYvtvecLFt26mkMqFxSvvt9uJMwVjPVmZ76aVo6Qh3W1ELw8Eid63pYGiVU2yEc18LCe6r9akvRx72pqAVFzU2fLPHRDnSw1R7ysexL7BfRxk9rLQkhdAkQPFvhAdq3Sc3wrryQEU9JZ9gLrAtAgGwXVCdM7xb7cgpCFQoAP4BCYtjAC2fNUQf5n3eYkuVmfQsFPVur7Ani3j4KTADdrcz135kYWMTtsEE5sRw5mhepmLuF9kRJHktDTMNwaPvVarnZaGE","signature":"EXQ8XhSnNt542kR7jvDgWbs3veW2stnTZqUMPNVoiqoiztGrR6km6bz2tiMDpiHLMcnQVQmmToghAXH4fads1eZ1UScftDs6LFrj4onLK5ezxdhi2Xqtruc7udbYzR7TFi3iYVqo6DUfR7FFkLxFQ4UwaZBXfjppRSWfDVPiSiV7uJVr6MEkvsiztLDhPT8udeDtp1L2m29JyhHZRaVmRSwfZTcJQ9X6BxBUKTnMTb2JLAaPzupoAoggXUVt2ZXw7wpZaicDtQZfeH12"}]],"pid":7}}
{"timestamp":"2019-08-07 20:29:28.247776Z","level":"Trace","source":{"module":"Gossip_net","location":"File \"lib/gossip_net/gossip_net.ml\", line 473, characters 71-78"},"message":"broadcasting message","metadata":{"pid":7}}
{"timestamp":"2019-08-07 20:29:28.288623Z","level":"Debug","source":{"module":"Trust_system__Peer_trust","location":"File \"lib/trust_system/peer_trust.ml\", line 120, characters 56-63"},"message":"Decreasing trust for peer $peer due to action Trust_system.Actions.Sent_old_gossip. New trust is 0.000006.","metadata":{"peer":"52.53.238.133","pid":7}}
{"timestamp":"2019-08-07 20:29:28.288759Z","level":"Debug","source":{"module":"Network_pool__Network_pool_base","location":"File \"lib/network_pool/network_pool_base.ml\", line 32, characters 60-67"},"message":"Pool diff apply feedback: no useful transactions","metadata":{"pid":7}}
{"timestamp":"2019-08-07 20:29:28.317957Z","level":"Debug","source":{"module":"Trust_system__Peer_trust","location":"File \"lib/trust_system/peer_trust.ml\", line 120, characters 56-63"},"message":"Decreasing trust for peer $peer due to action Trust_system.Actions.Sent_old_gossip. New trust is 0.000032.","metadata":{"peer":"54.188.108.191","pid":7}}
{"timestamp":"2019-08-07 20:29:28.318153Z","level":"Debug","source":{"module":"Network_pool__Network_pool_base","location":"File \"lib/network_pool/network_pool_base.ml\", line 32, characters 60-67"},"message":"Pool diff apply feedback: no useful transactions","metadata":{"pid":7}}
{"timestamp":"2019-08-07 20:29:28.518308Z","level":"Debug","source":{"module":"Trust_system__Peer_trust","location":"File \"lib/trust_system/peer_trust.ml\", line 120, characters 56-63"},"message":"Decreasing trust for peer $peer due to action Trust_system.Actions.Connected. New trust is 0.000004.","metadata":{"peer":"91.192.62.143","pid":7}}
{"timestamp":"2019-08-07 20:29:28.648721Z","level":"Debug","source":{"module":"Trust_system__Peer_trust","location":"File \"lib/trust_system/peer_trust.ml\", line 120, characters 56-63"},"message":"Decreasing trust for peer $peer due to action Trust_system.Actions.Sent_old_gossip. New trust is 0.000004.","metadata":{"peer":"91.192.62.143","pid":7}}
{"timestamp":"2019-08-07 20:29:28.648898Z","level":"Debug","source":{"module":"Network_pool__Network_pool_base","location":"File \"lib/network_pool/network_pool_base.ml\", line 32, characters 60-67"},"message":"Pool diff apply feedback: no useful transactions","metadata":{"pid":7}}
{"timestamp":"2019-08-07 20:29:30.315905Z","level":"Debug","source":{"module":"Trust_system__Peer_trust","location":"File \"lib/trust_system/peer_trust.ml\", line 120, characters 56-63"},"message":"Decreasing trust for peer $peer due to action Trust_system.Actions.Connected. New trust is -0.000020.","metadata":{"peer":"185.159.129.189","pid":7}}
{"timestamp":"2019-08-07 20:29:30.558054Z","level":"Debug","source":{"module":"Network_pool__Network_pool_base","location":"File \"lib/network_pool/network_pool_base.ml\", line 32, characters 60-67"},"message":"Pool diff apply feedback: Worse fee or already in pool","metadata":{"pid":7}}
{"timestamp":"2019-08-07 20:29:30.573332Z","level":"Info","source":{"module":"Gossip_net","location":"File \"lib/gossip_net/gossip_net.ml\", line 281, characters 65-72"},"message":"On RPC call, reconnected to a disconnected peer: ((host 185.159.129.189) (discovery_port 8303) (communication_port 8302))","metadata":{"pid":7}}
{"timestamp":"2019-08-07 20:29:30.573598Z","level":"Info","source":{"module":"Gossip_net","location":"File \"lib/gossip_net/gossip_net.ml\", line 210, characters 55-62"},"message":"Clearing disconnected peer set : (((host 185.159.129.189) (discovery_port 8303) (communication_port 8302)))","metadata":{"pid":7}}
{"timestamp":"2019-08-07 20:29:30.573830Z","level":"Info","source":{"module":"Gossip_net","location":"File \"lib/gossip_net/gossip_net.ml\", line 219, characters 55-62"},"message":"Restarting Kademlia","metadata":{"pid":7}}
{"timestamp":"2019-08-07 20:29:30.577315Z","level":"Debug","source":{"module":"Coda_run","location":"File \"app/cli/src/coda_run.ml\", line 70, characters 52-59"},"message":"Successfully wrote the visualization of the registered masks at location: /root/.coda-config/registered_masks.dot.","metadata":{"coda_run":"Logging state before program ends","pid":7}}
{"timestamp":"2019-08-07 20:29:30.693629Z","level":"Debug","source":{"module":"Coda_run","location":"File \"app/cli/src/coda_run.ml\", line 80, characters 58-65"},"message":"Successfully wrote the visualization of the transition frontier at location: /root/.coda-config/frontier.dot.","metadata":{"coda_run":"Logging state before program ends","pid":7}}
@cmr

This comment has been minimized.

Copy link
Contributor

commented Aug 7, 2019

@knarz are you running inside a container lacking kill? Or maybe the PATH for the daemon doesn't contain it?

@cmr cmr changed the title Unix create process crash Shelling out to kill is fragile and should be avoided Aug 7, 2019

@cmr

This comment has been minimized.

Copy link
Contributor

commented Aug 7, 2019

Updated the issue title. We shouldn't be shelling out to kill anyway, that was just some easy laziness.

@cmr cmr added this to the Testnet Beta milestone Aug 7, 2019

@cmr cmr added this to Discuss in Work Prioritization - Protocol via automation Aug 7, 2019

@knarz

This comment has been minimized.

Copy link
Author

commented Aug 7, 2019

The coda daemon is running inside a docker container. I'm actually not sure how docker handles kill.

@imeckler imeckler moved this from Discuss to Backlog in Work Prioritization - Protocol Aug 9, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
2 participants
You can’t perform that action at this time.