原命令:
python test.py
修改命令:
nohup python test.py &
输出信息默认为out.file,固定输出文件
nohup python test.py > test.log 2>&1 &
未退出终端查看后台任务:
jobs
退出终端查看后台任务
ps -aux | grep "test.py"
终止任务(pid可以根据上条命令查到)
kill pid
原命令:
python test.py
修改命令:
nohup python test.py &
输出信息默认为out.file,固定输出文件
nohup python test.py > test.log 2>&1 &
未退出终端查看后台任务:
jobs
退出终端查看后台任务
ps -aux | grep "test.py"
终止任务(pid可以根据上条命令查到)
kill pid