Linux后台进程停止
Posted
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了Linux后台进程停止相关的知识,希望对你有一定的参考价值。
我有一个linux服务,它做了一些工作,然后启动一个ngrok进程。我一直试图在后台开始这个过程,但它停止了。我尝试过以下方法:
./ngrok --config =“./ ngrok-config”-proto = tcp -subdomain =“test”22&
./ngrok --config =“./ ngrok-config”-proto = tcp -subdomain =“test”22&> / dev / null
./ngrok --config =“./ ngrok-config”-proto = tcp -subdomain =“test”22&> /ngrok/ngrok.log
nohup ./ngrok --config =“./ ngrok-config”-proto = tcp -subdomain =“test”22&> /ngrok/ngrok.log
nohup ./ngrok --config =“./ ngrok-config”-proto = tcp -subdomain =“test”22&2> / dev / null
在每个命令之后,我无法连接到隧道,并且检查作业将进程显示为已停止。
运行:./ ngrok --config =“./ ngrok-config”-proto = tcp -subdomain =“test”22
按预期工作并启动隧道,允许我连接。
有任何想法吗??
事实证明我失踪了:-log = stdout。由于没有这个,我假设该过程试图访问资源,这反过来终止了该过程。
现在可以使用:./ ngrok --config =“./ ngrok-config”-log = stdout -proto = tcp -subdomain =“test”22&> / dev / null
以上是关于Linux后台进程停止的主要内容,如果未能解决你的问题,请参考以下文章