Linux中的nohup

nohup输出到指定文件

输出到默认文件nohup.out

1
nohup python train.py&

输出到指定文件

1
nohup python train.py&> train.out&

实时监控输出内容

1
tail -f nohup.out

查看程序进程

ps显示当前进程状态,及其启动时的命令行参数

1
ps -ef | grep cmd