我是 airflow 的新手,不小心在守护进程模式下启动了 airflow scheduler。现在,我想终止调度程序并可能重新启动它。我试过做
sudo kill -9 <list of pids>
pkill <name>
什么都没有发生。当我运行时
ps aux | grep 'airflow scheduler'
我看到了这些条目:
user1 2907 6.0 1.0 329788 62996 ? Sl 17:37 1:26 /users/user1/anaconda2/bin/python /users/user1/anaconda2/bin/airflow scheduler -D
user1 2909 0.0 0.9 327576 58948 ? Sl 17:37 0:00 /users/user1/anaconda2/bin/python /users/user1/anaconda2/bin/airflow scheduler -D
user1 2910 0.0 0.9 327576 58944 ? Sl 17:37 0:00 /users/user1/anaconda2/bin/python /users/user1/anaconda2/bin/airflow scheduler -D
user1 2911 0.0 0.9 327576 58944 ? Sl 17:37 0:00 /users/user1/anaconda2/bin/python /users/user1/anaconda2/bin/airflow scheduler -D
...等等 35 行不同的 pid。
关于如何在不重启我的机器的情况下停止/终止 Airflow 调度程序的任何建议。我还检查了调度程序的 pid 文件并尝试杀死该 pid 但没有效果。
感谢任何帮助。谢谢!
最佳答案
不幸的是
kill $(ps -ef | grep "airflow scheduler" | awk '{print $2}')
我找不到干净的解决方案。
同时查看代码
https://github.com/apache/incubator-airflow/blob/master/airflow/bin/cli.py
关于linux - 如何停止/杀死以守护进程模式启动的 Airflow 调度程序,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/44710056/