1.你可以将两个 Python 文件的执行命令组合在一起,然后使用 nohup 命令来在后台运行它们。
nohup python -u BSNER.py >> nohup.out 2>&1 & nohup python -u REMARKS_NER.py >> nohup.out 2>&1 &
注:第一个python文件是BSNER.py ;
第二个python文件是REMARKS_NER.py
2.单个python文件在后台运行
nohup python -u my.py >> nohup.out 2>&1 &
查看进程状态信息,运行结果:R代表运行,S代表休眠
ps aux | grep 进程号