Why is Airflow crashing with INFO - “Task exited with return code -9”?

六眼飞鱼酱① 提交于 2021-01-28 21:09:44

问题


I have a big DAG running, however it's stopping with just that message, I couldn't figure out what is the error on the Airflow docs.

If that makes difference: My Airflow is running in a Rancher with a Helm chart.


回答1:


This is usually out of memory exception I think.




回答2:


I thought about a way to reduce the size of all the memory possibilities. And the first try was load some number of lines instead of all the lines:

serverCursor = conn.cursor("serverCursor")
serverCursor.execute(f'''select * from {ORIGIN_SCHEMA}.{table};''')

df = []
while True:
  records = serverCursor.fetchmany(size=50000)
  df = df + records
  if not records:
    break
serverCursor.close()

That solved the issue.



来源:https://stackoverflow.com/questions/57365204/why-is-airflow-crashing-with-info-task-exited-with-return-code-9

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!