> help disown
disown: disown [-h] [-ar] [jobspec ...]
By default, removes each JOBSPEC argument from the table of active jobs.
If the -h option is given, the job is not removed from the table, but is
marked so that SIGHUP is not sent to the job if the shell receives a
SIGHUP. The -a option, when JOBSPEC is not supplied, means to remove all
jobs from the job table; the -r option means to remove only running jobs.
当会话关闭时,进程接收到它显然没有捕捉到的SIGHUP信号。启动进程时可以使用
nohup
命令,启动进程后可以使用bash内置命令disown -h
,以防止发生这种情况:我建议使用GNU Screen。它允许您在所有进程继续运行时断开与服务器的连接。在我知道它存在之前,我不知道没有它我是怎么生活的。
查看“nohup”程序。
相关问题 更多 >
编程相关推荐